Board Logo

 Username:    Password:    Stay logged in: Welcome Guest. Please Login or Register.  Aug 21st, 2017, 4:41pm


Board Hacks
Important News
Please read the notes posted with any codes carefully, as they will usually tell you where they need to go.
Welcome to the Conforums Hacks Board!

All codes here have been tested but we accept no responsibility if these codes do not work on your board, or have an adverse effect when used in combination with other codes.

This board is read only. Any queries or requests for codes should be made on the Coding Forum

Helpful sites
Google
Dynamic Drive

The Staff
Roger
Dave
GIzzy



« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: Resize board width  (Read 4682 times)
Dave
I've always wanted one of these wink
Conforums Administrator


member is offline

Avatar

Mr Fixit...


Homepage PM

Gender: Male
Posts: 17644
xx Resize board width
« Thread started on: Feb 5th, 2004, 3:47pm »

Code submitted by Me... grin


3 ways of doing this.. the first is by inserting the main page into a table, like this:-
  • At the bottom of your header
      <table width="XXXXXX" border="0" cellspacing="0" cellpadding="0" align="center"><tr><td valign="top">

  • Then at the top of the footer
      </td></tr></table>

    Set XXXXXX to width you require.


The second is by inserting some javascript into the footer, like this:-
    <script language="Javascript">
    <!--
    var Tab=document.getElementsByTagName('TABLE')
    for(tab=0; tab<Tab.length; tab++){
    if(Tab[tab].width=="92%")
    Tab[tab].width="XX%"
    }
    // -->
    </script>


Again set XX to width you require.

The third way is with a code like this is with pixels.

<script LANGUAGE="JavaScript">
<!--
tablew = document.getElementsByTagName('TABLE');
for(t=0;t<tablew.length;t++) {
if(tablew[t].width=="92%"){
tablew[t].width='XXX';
}
}
// -->
</script>

For example replace the XXX with a number like 700.


The first code will only alter the board/thread part of the page, whereas the second code will change the entire page, including the top table... The third code will work the same way as the second




Edit - Script Error fixed in second code.

If you'd like to see a preview of this code's effects click here
« Last Edit: Jul 6th, 2006, 3:30pm by Garet » User IP Logged

Have you read the FAQ or checked the Hacks board before posting?
No?
Then please do so...
Garet
Conforums Elite
Senior Member


member is offline

Avatar




Homepage PM

Gender: Male
Posts: 2073
xx Re: Resize board width
« Reply #1 on: Jul 6th, 2006, 8:55pm »

If you'd like to just resize the banner use this code

Main Header

Quote:
<script type="text/Javascript">
<!--
document.getElementById('toptable').style.width="XXX";
// -->
</script>


« Last Edit: Jul 6th, 2006, 8:58pm by Garet » User IP Logged

Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

Back To Top
Donate $6.99 for 50,000 Ad-Free Pageviews!

| |

This forum powered for FREE by Conforums ©
Sign up for your own Free Message Board today!
Terms of Service | Privacy Policy | Conforums Support | Parental Controls