Snitz™ Forums 2000
https://forum.snitz.com/forumTopic/Posts/65783?pagenum=1
05 November 2025, 01:40
Topic
balexandre
Fly to the top instead of jumping
21 October 2007, 07:01
I like to share this you you.
I implemented this to my Forum at www.ga-paneuropean.com (just go to the bottom of the page and click the "Go to Top" arrow...)
instead of jumping instantaneously to the top, the user will be scrolling the page... really nice effect (at least that's what I thought when I saw it)
if you added the 2 javascript files into js folder, if you added to the main folder where every file are, just erase the js/
hope it brings a little happinesses to someone<
Replies ...
Etymon
25 October 2007, 23:46
Hi Bruno,
Thank you for the code. It's a great idea!
Cheers,
Etymon <
balexandre
26 October 2007, 03:45
glad to help <
JJenson
26 October 2007, 10:23
I like that alot thanks balaexandre<
PPSSWeb
26 October 2007, 10:34
I like it. I will have to try it out. Thanks. <
MarcelG
28 October 2007, 10:50
Great script! Thanks! <
MarkJH
28 October 2007, 11:30
Very nice indeed. Thanks, Bruno. <
MarkJH
28 October 2007, 11:39
FWIW, this works great on IE7 and FF but not on Opera. Still jumps to the top, though.<
balexandre
28 October 2007, 14:26
I'm sorry, but there's something you have wrong then
try my Fórum in Opera, works great as well
it even works in Safari for Windows http://www.ga-paneuropean.com<
MarkJH
28 October 2007, 16:12
Hmm. My forum isheavily modified. Maybe there's some kind of conflict there that stops it from working correctly. Still, it's not a problem. <
Webbo
29 October 2007, 07:59
It does cause a conflict if you have the Photo Album mod installed
<
balexandre
29 October 2007, 13:32
really?
I do have Photo album and i don't get any error what so ever in any browser... check the error you are getting and post it here.<
Marcus Fenix
29 October 2007, 14:34
10x Man :)<
PPSSWeb
30 October 2007, 07:32
This script seems to conflict with Proeder's file attachement MOD. When installed, the attach buttons no longer function properly and the user is sent to the top of the page instead. Can anyone else confirm this issue, or did I install it wrong?<
balexandre
30 October 2007, 08:28
I don't have that MOD, so I'm not be able to help you on that
open in Firefox with Firebug installed and see if there's anything wrong.<
PPSSWeb
30 October 2007, 09:37
Originally posted by balexandre I don't have that MOD, so I'm not be able to help you on that
open in Firefox with Firebug installed and see if there's anything wrong.
I don't see anything "wrong", but I haven't had time to go through your code to know exactly what it is doing. It seems that the problem goes beyond that button for me. Upon closer inspection it seems to effect all links that use window.open to create a pop-up. This includes standtard events such as emailing, deleting, and locking a member as well as other features. Can anyone confirm this to be a problem with the standard features or shed some light as to why this would be happening for my setup.
If it helps, I am running a fully patched 3.4.05 version of the forums.
Thanks, Steve<
MarkJH
30 October 2007, 12:13
All pop up windows on my forum seem to work fine, Steve.<
PPSSWeb
31 October 2007, 08:34
Originally posted by MarkJH All pop up windows on my forum seem to work fine, Steve.
Thanks for confirming this as a non MOD related issue. If anyone has any ideas as to why this would be happening when this mod is added and not when it is removed, please let me know.
<
Etymon
31 October 2007, 11:20
Originally posted by MarkJH All pop up windows on my forum seem to work fine, Steve.
I viewed your site using FireFox and the MOD works as expected.<
PPSSWeb
01 November 2007, 09:52
I found the error I was having as detailed above. I originally did not notice that there was no close script tag on the line above.
I believe I have fixed the issue with this MOD and Proeder's File Attachment MOD.
Problem. The the links for the file upload just didn't do anything when this mod is installed.
Cause: This mod hunts down all href instances that contain an '#' assuming that they are all anchors. Unfortunately, the links to the upload function for Proeder's also contain this character.
Solution: The '#' character appears at end of the string for the Proeder's links and in the middle for normal anchors. Adding a check in the javascript to exclude instances where the '#' appears at the end of the string fixes the issue.
In smooth-src-comments.js change line 79 from:
Then modify the link in inc_header.asp to use this file instead.
This works for my setup, so hopefully it will help others to use this really cool script.<
balexandre
01 November 2007, 13:58
good catch, now everyone can have their users flying to the top <
Lon
21 December 2007, 12:01
I too use the Proeder's File Attachment MOD and I made this MOD corrections, however when the user clicks on the paperclip, the page scrolls.....
If I remove the line in inc_header.asp, the Proeder's File Attachment MOD works fine.
Just checking to see if anyone else has this issue or just me?<
PPSSWeb
24 December 2007, 09:30
Originally posted by Lon I too use the Proeder's File Attachment MOD and I made this MOD corrections, however when the user clicks on the paperclip, the page scrolls.....
If I remove the line in inc_header.asp, the Proeder's File Attachment MOD works fine.
Just checking to see if anyone else has this issue or just me?
Did you make both of the changes detailed in my posts above?<
Lon
24 December 2007, 10:32
Yes, I have made both the above changes. It is a cool MOD, however the ability to upload is more important.<
PPSSWeb
24 December 2007, 11:20
Originally posted by Lon Yes, I have made both the above changes. It is a cool MOD, however the ability to upload is more important.
I agree it is very cool. I got them both to work together with the changes above though. The first fixed the issue with the popup windows and the second with the paperclip button performing a scroll instead of opening the upload page.
If you changed the line in the file smooth-src-comments.js to the fixed one above and are pointing to that file in inc_header.asp instead of the original, than I am not sure what the problem could be off hand. If you want to send me those two files, I can look at them and compare to my own working versions.<
Lon
24 December 2007, 15:29
Ok, I think I understand now. My inc_header.asp still had "smooth.pack.js" in it. I thought that is what you were trying to say until I read this whole topic word-for-word again. I replaced that with "smooth-src-comments.js" and it seems to work now. WOW! Sometimes I can be hard-headed.
<
balexandre
05 March 2008, 09:35
<
leatherlips
22 March 2008, 12:24
My inc_header is very modified. Can someone tell me where I am supposed to add the line for this mod? What should it be before or after? My line 234 is not the same as an unmodified inc_header. Thanks.<
balexandre
22 March 2008, 14:46
it's easy...
download the forum and see the file but to make it simple, it's below all the javascript include files that you find, right before the <body> tag
<
leatherlips
22 March 2008, 15:07
Thanks. I actually did a different way. I added the site integration mod a long time ago. Instead of adding the code to the inc_header.asp file, I added it to the header file that came with that mod. It works well!<
leatherlips
22 March 2008, 19:38
I'd like to apply this to the rest of my site, not just the forum. How do I do that? I tried adding this to the head but it is not working:
Of course the path to the smooth.pack.js file needs to be altered for your own site if needed.
<
leatherlips
23 March 2008, 12:59
I'm still trying to use this in my main site. All works well except in Firefox. On my page where I am testing it, I have an anchor link in the middle of the page. With Firefox, it goes to one line past the link.
Here is the page I am talking about:
Click Here If you click on Liner Notes it will take you one line past the liner note header. In IE and Safari, it takes you right to the header as it should. Any ideas why this does not work in Firefox on my page?<
balexandre
23 March 2008, 14:01
how can you blame a script if you can't do proper code???
1st of all you dont even have a document type on the page!
2nd of all... do you validate your pages through standards? try this! and by the way... did you ever read about CSS? <
leatherlips
23 March 2008, 19:40
Originally posted by balexandre how can you blame a script if you can't do proper code???
1st of all you dont even have a document type on the page!
2nd of all... do you validate your pages through standards? try this! and by the way... did you ever read about CSS?
I don't doubt the code. I'm certain it is something I am doing wrong, but I just don't know exactly what it is. I'm an amateur at best.<
I just noticed that on the Snitz FAQ page, in Firefox, clicking the questions to go to the answers goes a little past the heading for that answer. In IE7 it works fine. Is there a way to fix that?<
balexandre
29 March 2008, 01:46
that's your browser/computer/whatever configuration then!
here, using : - Safari 3.0.4 (523.15) - Firefox 2.0.0.13 - IE 7.0.5730.11 - Opera 9.26 (build 8835)
All perform the same thing after clicking the question "Do I have to register?" on Snitz FAQ, as you can see by the image below! <
leatherlips
29 March 2008, 08:12
Temper, temper. Well for some reason when I go to your site and use Firefox and click on Register it goes past the heading. My Firefox is "straight out of the box". No big deal. Nothing to get mad over.<
Todd
13 August 2008, 21:53
Originally posted by Webbo It does cause a conflict if you have the Photo Album mod installed
I also have the Photo Album Mod installed. After installing this smooth scrolling mod I did update it with the code posted in this thread because I experienced issues with the Proeders File Upload mod. That did indeed fix the problem with Proeders.
I was just browsing the Photo Album Mod and find that when clicking on a photo it no longer pops up in an enlarged window. I haven't tried to upload into the photo album, so I don't know if that might be an issue also. (Just checked with the code in place, not an issue, I can upload into the album just fine, it's only affecting the enlarged photo pop up window).
When I comment out the call for the js file in the inc_header.asp file the popups for the photo album operate correctly again. The links in the photo album mod which produce the pop up window also end with a #, example below.
http://www.tycoforums.com/tyco/forum/photo_album_view.asp?cname=Main+Album&mid=831&cid=9#
Any ideas?<
Todd
13 August 2008, 22:58
Fixed.
Instead of replacing the line in the js file as described, I added the new line and commented out the old line. I must have had a space or something in there. I've since deleted the line I commented and actually replaced it. It was a formatting error on my part.<