Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

Return to top

Asked Modified Viewed 2,472 times
T
tonyokc
T
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 6 threads in the forums
  • Started this discussions
asked
Junior Member

The default operation on PHPFusion, at times, makes for LONG pages. And once at the bottom of the page, no real easy way to get back to the top for most users, where they can see the menu to do anything else.

I made a 'small' modification to my site, to get around this issue.

in subheader.php, where it says:

<body bgcolor='$body_bg' text='$body_text'>\n";


I changed to:

<body bgcolor='$body_bg' text='$body_text'>\n";
echo "<a name='Top' id='Top'></a>";


Then in the System Admin, Main Settings, Site Footer, I added:

<a href='#Top'><input type='button' value='Return To Top' class='button' /></a>


By using the input button, it auto gets the color of the site, regardless of theme you are using (simplier than making button images for every theme)

This can be put in a table, or whatever. I have it added there twice, on far right and far left, just for an even look

That <a href.. should be changed to just a onclick function, but I didnt want to spend the time researching the right format for that (hey, ok, I'm lazy! <grin>)

This could be added to footer.php if you wanted to make it a perminate fixture

Anyone interested in seeing this, its implimented on my site
0 replies

7 posts

B
Bad Boy
B
____________________
BadBoy aka GoogleDude
http://www.googlecityforums.com
  • Member, joined since
  • Contributed 155 posts on the community forums.
  • Started 1 thread in the forums
answered
Member

It's not working on your site for me. When I click "Return to Top" it does nothing.
0 replies
T
tonyokc
T
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 6 threads in the forums
  • Started this discussions
answered
Junior Member

yeah, and now I dont know why, works in firefox, does not work in IE (had another user tell me that
0 replies
B
Bad Boy
B
____________________
BadBoy aka GoogleDude
http://www.googlecityforums.com
  • Member, joined since
  • Contributed 155 posts on the community forums.
  • Started 1 thread in the forums
answered
Member

Could it be the missing onclick function?
0 replies
T
tonyokc
T
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 6 threads in the forums
  • Started this discussions
answered
Junior Member

the code I'm trying now, is:

I changed the name to #Top, thought IE might require the #

<a href='#Top' target='_self'><input type='button' value='Return To Top' class='button' /></a>


This works in FF, but not in IE
Edited by tonyokc on 25-07-2006 20:07,
0 replies
T
tonyokc
T
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 6 threads in the forums
  • Started this discussions
answered
Junior Member

it is deffinitly the input button, if I change it to:
<a href='#Top' target='_self'>Return to Top</a>


It works in both browsers, but dang, I want that button
0 replies
T
tonyokc
T
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 6 threads in the forums
  • Started this discussions
answered
Junior Member

I gave up on using the input to get a auto colored button, and just made a gif
0 replies
B
Bad Boy
B
____________________
BadBoy aka GoogleDude
http://www.googlecityforums.com
  • Member, joined since
  • Contributed 155 posts on the community forums.
  • Started 1 thread in the forums
answered
Member

Looks good!
0 replies

Category Forum

General Discussion

Labels

None yet

Statistics

  • Views 0 views
  • Posts 7 posts
  • Votes 0 votes
  • Topic users 2 members

2 participants

B
B
____________________
BadBoy aka GoogleDude
http://www.googlecityforums.com
  • Member, joined since
  • Contributed 155 posts on the community forums.
  • Started 1 thread in the forums
T
T
  • Junior Member, joined since
  • Contributed 33 posts on the community forums.
  • Started 6 threads in the forums
  • Started this discussions

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet