Reply
Visitor able to change width of page???
Old 05-08-2008, 12:49 PM Visitor able to change width of page???
coldturkey's Avatar
Extreme Talker

Posts: 176
Name: Rachel
Location: Spain
I recently saw a web site that had 3 little buttons that the top. One was to make the page full size, another made the page width about 900 px and the other page width was about 750px.
I think this is done using javascript…. Or at least when changing font size in this way javascript is used.
Can any one tell me a link of a tutorial for this, I have looked but havent had much luck.
The code has to be carried though each page so the visitor views each page in the size they selected and if it comes with cookies to save the selected viewed page with size, that would be great.
Hope some one can advise me on this.
Thanks
Rachel
__________________
coldturkey is offline
Reply With Quote
View Public Profile Visit coldturkey's homepage!
 
Sponsored Links (We share ad revenue):
 
Old 05-08-2008, 01:47 PM Re: Visitor able to change width of page???
JeremyMiller's Avatar
Full-Time TeraTasker

Posts: 630
Name: Jeremy Miller
Location: Reno, NV
It sounds like you've figured it out -- when they click on a size, adjust the main page content width and store the value in a cookie. Then, when a page loads, read the value of the cookie to set the initial content width.

An alternative, but more sophisticated, method is to store a user id as a cookie and then use Ajax to call the server with the user's settings. The information could then be stored server-side along with the user id and subsequently be used to set the initial page width.

The second method has some advantages:
1) You can set as many characteristics as you want since each characteristic won't require a separate cookies.

2) You can see what your visitors prefer by querying the table.

3) The settings cross multiple browsers (when the user is logged in and that code is set).
__________________
Jeremy Miller - TeraTask Technologies, LLC
Content Farmer - Automated Posting for Content & Blog Sites
JeremyMiller is offline
Reply With Quote
View Public Profile Visit JeremyMiller's homepage!
 
Old 05-08-2008, 02:54 PM Re: Visitor able to change width of page???
coldturkey's Avatar
Extreme Talker

Posts: 176
Name: Rachel
Location: Spain
lol.... you always come to my rescue Jeremy!!!

I looked a little more and finaly found this link... which I think will do the job...
www.beautyindesign.com/quick_clips_library/adjusting_a_site_layout_with_mootools.php

Thanks
Rachel
__________________
coldturkey is offline
Reply With Quote
View Public Profile Visit coldturkey's homepage!
 
Sponsored Links (We share ad revenue):
 
Reply     « Reply to Visitor able to change width of page???
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML


Page generated in 0.16783 seconds with 14 queries