Follow Us:


Tricked Out Mods: Forums


 Forum FAQForum FAQ   SearchSearch   UsergroupsUsergroups   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

RavenNuke 2.40.01 - Theme Fixed Width
 Goto page 1, 2  Next
 
Post new topic   Reply to topic   print    Tricked Out News Forum Index -> RavenNuke
View previous topic :: View next topic  
Author Message
Mike63740
I might as well work here
I might as well work here


Joined: Jan 07, 2010
Posts: 129


PostPosted: Fri Feb 24, 2012 6:31 pm 
Post subject: RavenNuke 2.40.01 - Theme Fixed Width
Reply with quote

When I installed phpBB 3.0.10, the theme width was 100%. I simply went into styles/prosilver/theme/common.css, and set the theme to a fixed width of my choose.

I notice Tricked Out News theme width was 100%, until recently changed to a fixed width.

How can I change RavenNuke 2.40.01 theme to a fixed width?

Thanks.
  
Back to top
View user's profile Send private message
bobby
Site Admin
Site Admin


Joined: Jan 20, 2009
Posts: 812


PostPosted: Fri Feb 24, 2012 6:37 pm 
Post subject:
Reply with quote

The easiest way is to add a container div with a set width just after the opening <body> tag and close it before the closing </body> tag. You would have to make sure there are no set widths in the body of the theme other than 100% or dealing with side blocks.
_________________
Tricked Out News
  
Back to top
View user's profile Send private message Visit poster's website
Mike63740
I might as well work here
I might as well work here


Joined: Jan 07, 2010
Posts: 129


PostPosted: Sat Feb 25, 2012 2:17 pm 
Post subject:
Reply with quote

Which file should I make these changes to?
  
Back to top
View user's profile Send private message
bobby
Site Admin
Site Admin


Joined: Jan 20, 2009
Posts: 812


PostPosted: Sat Feb 25, 2012 2:27 pm 
Post subject:
Reply with quote

The themes theme.php should be where you want to look. It really depends on how the theme was written. I will give you an example for the RavenIce theme. In theme.php in function themeheader() you will find
Code:


echo '<body>';


Change that to something like this
Code:
echo '<body><div style="width:970px; margin-left: auto; margin-right: auto;">';


That will give you a fixed width of 970 and center the content by using the margins set to auto. You will need to close that div in the function themefooter() after the last closing div.
_________________
Tricked Out News
  
Back to top
View user's profile Send private message Visit poster's website
Mike63740
I might as well work here
I might as well work here


Joined: Jan 07, 2010
Posts: 129


PostPosted: Sat Feb 25, 2012 9:38 pm 
Post subject:
Reply with quote

Bobby, could you re-wright this for me, if time allows.

The default theme for my site is: Fisubice

Line 72 reads: echo '<body bgcolor="#FFFFFF" text="#516A88" style="margin: 10px">';

Thanks.
  
Back to top
View user's profile Send private message
bobby
Site Admin
Site Admin


Joined: Jan 20, 2009
Posts: 812


PostPosted: Sat Feb 25, 2012 10:39 pm 
Post subject:
Reply with quote

Code:
echo '<body bgcolor="#FFFFFF" text="#516A88" style="margin: 10px"><div style="width:980px; margin-left: auto; margin-right: auto;">';


And on line 144 add an extra </div> like this
Code:
echo '</div></div></div>'."\n";

_________________
Tricked Out News
  
Back to top
View user's profile Send private message Visit poster's website
Mike63740
I might as well work here
I might as well work here


Joined: Jan 07, 2010
Posts: 129


PostPosted: Sat Feb 25, 2012 10:48 pm 
Post subject:
Reply with quote

I replaced line 72 with: echo '<body><div style="width:970px; margin-left: auto; margin-right: auto;">'; It all looks good. It's what I was looking for.

What about the old settings that was removed.

'<body bgcolor="#FFFFFF" text="#516A88"
and
"You will need to close that div in the function themefooter() after the last closing div."

Without the underlines above, everything appear just fine with just replacing line 72 with the code you provided. I only changed the width in your code.

Will I find problems later?
Why do the theme look the same, except the new fixed width?
Do I still need to close the div?
Is the div already closed by the chosen theme?

Thanks again.

P.S. I tried to post this reply before you replied, but kept getting this message:

ERROR: 403 - Forbidden
You do not have permission to access the requested file
Hint: The server understood the request, but is refusing to fulfill it
Authorization will not help and you SHOULD NOT repeat the request as you may be banned

Refered From : http://trickedoutnews.com/ftopict-220.html
Your IP : 68.55.190.53
Page Requested : /modules.php?name=Forums&file=posting
Agent : Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET4.0C)
Redirect Status : 403
  
Back to top
View user's profile Send private message
bobby
Site Admin
Site Admin


Joined: Jan 20, 2009
Posts: 812


PostPosted: Sat Feb 25, 2012 10:55 pm 
Post subject:
Reply with quote

I had a shortlinks bug in the quick reply. Should be fixed now. What I posted above should work fine for you. You have to close that open div or you will have display issues.
_________________
Tricked Out News
  
Back to top
View user's profile Send private message Visit poster's website
Mike63740
I might as well work here
I might as well work here


Joined: Jan 07, 2010
Posts: 129


PostPosted: Sat Feb 25, 2012 11:03 pm 
Post subject:
Reply with quote

Thank you.

It was with quick reply, and I will close the open div.
_________________
Open-source software has been changing lives since 1998.
  
Back to top
View user's profile Send private message
Mike63740
I might as well work here
I might as well work here


Joined: Jan 07, 2010
Posts: 129


PostPosted: Sat Feb 25, 2012 11:31 pm 
Post subject:
Reply with quote

Line 72 now reads: echo '<body bgcolor="#FFFFFF" text="#516A88" style="margin: 0px"><div style="width:984px; margin-left: auto; margin-right: auto;">';

Thank you.

I still need to close. It seems that my line 144 is not the same as your line 144.

Code:
126 function themefooter() {

127    global  $foot1, $foot2, $foot3, $copyright, $totaltime, $footer_message;
128    if (defined('INDEX_FILE') && INDEX_FILE===true) {
129        $tmpl_file = 'themes/fisubice/center_right.html';
130        $thefile = implode('', file($tmpl_file));
131        $thefile = addslashes($thefile);
132        $thefile = '$r_file="'."$thefile".'";';
133        eval($thefile);
134        print $r_file;
135        blocks('right');
136    }
137
138    echo '</td></tr></table><table width="100%"><tr><td>&nbsp;</td></tr></table>';
139    echo '<center>'."\n";
140    echo LGL_MENU_HTML; // Added by montego to "showcase" the use of the new Legal Module
141    echo '<div class="small">';
142    $footer_message = footmsg();
143    echo '</div>';
144    echo '</center>'."\n";

P.S. Received shortlinks bug again.
  

Last edited by Mike63740 on Wed Mar 07, 2012 2:38 pm; edited 1 time in total
Back to top
View user's profile Send private message
bobby
Site Admin
Site Admin


Joined: Jan 20, 2009
Posts: 812


PostPosted: Sat Feb 25, 2012 11:45 pm 
Post subject:
Reply with quote

Than put the closing div after the </center> tag
_________________
Tricked Out News
  
Back to top
View user's profile Send private message Visit poster's website
Mike63740
I might as well work here
I might as well work here


Joined: Jan 07, 2010
Posts: 129


PostPosted: Sun Feb 26, 2012 10:54 am 
Post subject:
Reply with quote

line 144 now reads: echo '</center></div>'."\n";

Is this correct?
  
Back to top
View user's profile Send private message
bobby
Site Admin
Site Admin


Joined: Jan 20, 2009
Posts: 812


PostPosted: Sun Feb 26, 2012 11:10 am 
Post subject:
Reply with quote

yes it is.
_________________
Tricked Out News
  
Back to top
View user's profile Send private message Visit poster's website
Mike63740
I might as well work here
I might as well work here


Joined: Jan 07, 2010
Posts: 129


PostPosted: Wed May 09, 2012 1:02 pm 
Post subject:
Reply with quote

These are original unchanged codes.
Theme Name: fisubice
File Name: theme.php

Code:
RavenNuke 2.50.00

73   echo '<body bgcolor="#FFFFFF" text="#516A88" style="margin: 10px">';

RavenNuke 2.40.01
72   echo '<body bgcolor="#FFFFFF" text="#516A88" style="margin: 10px">';

RavenNuke 2.50.00
139   echo '</td></tr></table><table width="100%"><tr><td>&nbsp;</td></tr></table>';
140   echo '<div class="text-center">'."\n";
141   echo LGL_MENU_HTML; // Added by montego to "showcase" the use of the new Legal Module
142   echo '<div class="small">';
143   $footer_message = footmsg();
144   echo '</div>';
145   echo '</div></div>'."\n";

RavenNuke 2.40.01
138    echo '</td></tr></table><table width="100%"><tr><td>&nbsp;</td></tr></table>';
139    echo '<center>'."\n";
140    echo LGL_MENU_HTML; // Added by montego to "showcase" the use of the new Legal Module
141    echo '<div class="small">';
142    $footer_message = footmsg();
143    echo '</div>';
144    echo '</center>'."\n";

Bobby, you posted above how to write the closing div for 2.40.01, but I am stumped because 2.50.00 is somewhat different. Most of the codes between the two are the same, but where the closing div goes is not.

Please re-write the entire line 145 with the closing div for RavevNuke 2.50.00.

Thank you.
_________________
Open-source software has been changing lives since 1998.
  
Back to top
View user's profile Send private message
bobby
Site Admin
Site Admin


Joined: Jan 20, 2009
Posts: 812


PostPosted: Wed May 09, 2012 1:24 pm 
Post subject:
Reply with quote

Look a few posts up mike. The code I posted if from 2.5. Look at the 6th post in this forum.
_________________
Tricked Out News
  
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:       
Post new topic   Reply to topic   print    Tricked Out News Forum Index -> RavenNuke All times are GMT - 5 Hours
 Goto page 1, 2  Next
 Page 1 of 2
 
 

Jump to:   
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum

Powered by phpBB © 2001-2008 phpBB Group
Forums ©