Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: aldo on July 03, 2008, 07:22:52 PM

Title: Registering problem
Post by: aldo on July 03, 2008, 07:22:52 PM
On my SMF 2.0 Beta 3.1 forum, when you go to the register page in Firefox 3 (http://mschat.net/forum/index.php?action=register (http://mschat.net/forum/index.php?action=register)) when you type in your name, and you hit the (http://mschat.net/forum/Themes/classic/images/icons/field_check.gif) icon, it clears all fields...

I tried on this forum in Firefox 3 and did not have a problem. But when I try in IE7, it works, but then redirects to the index of the forum.

Here is a list of mods I have installed:
Quote
1. Redirect_Moved_Topics 1.0 [ Uninstall ]
2. Pretty URLs - Base 0.8.4 [ Uninstall ]
3. Highlight Search Keywords 1.2 [ Uninstall ]
4. Internal_Links_Use_Same_Window 1.2 [ Uninstall ]
5. Auto Embed Video Clips 2.2 [ Uninstall ]
6. SMF 1.0.13 / 1.1.5 / 2.0 b3.1 Update 1.0 [ Uninstall ]
7. More Spiders 1.0 [ Uninstall ]
8. Top 10 Posters Today And This Week Stats 1.1 [ Uninstall ]
9. MessagePreviewOnHover 1.7 [ Uninstall ]
10. Enhance Recent Post 1.0 [ Uninstall ]
Thanks for your help
Title: Re: Registering problem
Post by: brianjw on July 03, 2008, 07:32:16 PM
Can you attach your Registration.template.php and Registration.php from /Themes/default/ and /Sources/?

Thank you. (NOTE: I said attach, not post. Please attach the file and not post the code of the file)
Title: Re: Registering problem
Post by: aldo on July 03, 2008, 07:35:21 PM
Okay, done
Title: Re: Registering problem
Post by: brianjw on July 03, 2008, 10:36:53 PM
Can't figure it out. Sorry. :(
Title: Re: Registering problem
Post by: metallica48423 on July 05, 2008, 04:38:04 AM
I can't get this to happen no matter what I do.  Any javascript errors popping up?
Title: Re: Registering problem
Post by: aldo on July 05, 2008, 02:31:21 PM
Error: syntax error
Source File: javascript:%20http://mschat.net/forum/index.php?action=register
Line: 1, Column: 49
Source Code:
http://mschat.net/forum/index.php?action=register

I get that, but I don't know how that is possible...
Title: Re: Registering problem
Post by: Oldiesmann on July 05, 2008, 04:13:06 PM
I see what's going on, but I don't know why it's happening.

The "href" value for that image is "#", which essentially keeps you from leaving the page. However, something is causing the # to get stripped out, so when the code is output, the href value becomes an empty string. Like most browsers, Firefox just appends the href to the end of the current URL since it doesn't have a protocol on the beginning of it (such as http://, ftp:, etc.). However, Firefox isn't ignoring the empty href, so clicking the image just reloads the page (because it's linking to the same page that you're currently on), which in turn causes all information entered in the form to be lost.

So basically we just need to figure out what's causing the "#" to be stripped. Firefox isn't generating any javascript errors though.
Title: Re: Registering problem
Post by: aldo on July 05, 2008, 04:48:56 PM
Thanks a bunch Oldies!

I fixed it by replacing the # on line 116 in Register.template.php with javascript:void(0); and it is all fixed...