Fedora 12, PHP 5.3.2, Drupal 6.17

Expected behavior:

1) Click link to log in
2) Screen disable, fancy_login DIV visible
3) Click link to "Create new account" or "request new password"
4) Be directed to "user/register" or "user/password"

Actual behavior:

4) "waiting" animated graphic visible, but no request for "user/register" or "user/password" is made of the server

No Javascript or other errors.

Behavior noted using WindowsXPSP3 Firefox 3.6, Internet Explorer 7, Chrome 5.0.375.70, Iron 0.2.152.0, Safari 4.0.4, Opera 10.10

Steps taken in fix attempt:

1) Reinstall Fancy_Plugin 6.x-1.3
2) Modify fancy_plugin.module:
- changed 'user/register' to '/user/register' (lost host name)

Logging in works fine, it's when one of the links for a new account or password reset are activated, no request is being made of the server.

Comments

Stupidscript’s picture

Oop ...

1) Reinstall Fancy_Login 6.x-1.3
2) Modify fancy_login.module:
- changed 'user/register' to '/user/register' (lost host name)

Stupidscript’s picture

Kludge workaround:

Added 'onclick' events to do the relocation (lines 165 & 169 of modules/fancy_login/scripts/fancy_login.js):

$items[] = l(t('Create new account'), 'user/register', array('attributes' => array('title' => t('Create a new user account.'), 'onclick' => 'top.location.href=this.href')));

Not sure why the straight links don't function, but ... they just don't.

David_Calculli’s picture

Just be aware that you need to add the onclick events to lines 165 & 169 of modules/fancy_login/fancy_login.module, not the scripts/fancy_login.js file.

Your lines should look like:

	$items = array();
	if (variable_get('user_register', 1))
	{
		$items[] = l(t('Create new account'), 'user/register', array('attributes' => array('title' => t('Create a new user account.'), 'onclick' => 'top.location.href=this.href')));
	}
	if(!module_exists('noreqnewpass') || !variable_get('noreqnewpass_disabled', FALSE))
	{
		$items[] = l(t('Request new password'), 'user/password', array('attributes' => array('title' => t('Request new password via e-mail.'), 'onclick' => 'top.location.href=this.href')));
	}
Stupidscript’s picture

D'oh!

Exactly right. I did make the change in the module file, and not in the Javascript file. Thanks for catching that.

Still curious as to why the normal links don't function ...

jaypan’s picture

Bug fixed in version 1.4.

David_Calculli’s picture

Status: Active » Fixed

Wow - that is awesome mate! Really positive surprise!

jaypan’s picture

It was a fairly serious problem! I hadn't realized it existed, but it actually meant that I had no direct link to the register page on my site, so it was something that needed to be fixed ASAP.

Stupidscript’s picture

Perfect! Thanks for the speedy fix. Nice module!

davidps’s picture

Great! Now it works perfect.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.