WordPress.org

Ready to get started?Download WordPress

Forums

Login With Ajax
[closed] Update from 3.0.4.1 to 3.1.2 (10 posts)

  1. Eek
    Member
    Posted 10 months ago #

    First of all:

    OMG! What a change! What a chaaange!

    I was using a modified version of login-with-ajax, with files based in my template. widget_out.php and widget.css and after the jquery update, a modified version of login-with-ajax.js that was using migration.

    I updated, and buf! Fatal Error :) Cause of the old widget_out.php.

    Also, I would like to be able to include only widget.css, to do that, I see that i also need login-with-ajax.js in my theme.

    Can you change the function

    public static function locate_template_url($template_path)

    from

    if( file_exists(get_stylesheet_directory().'/plugins/login-with-ajax/login-with-ajax.js') ){ //Child Theme (or just theme)
    	    	return trailingslashit(get_stylesheet_directory_uri())."plugins/login-with-ajax/$template_path";
    	    }else if( file_exists(get_template_directory().'/plugins/login-with-ajax/login-with-ajax.js') ){ //Parent Theme (if parent exists)
    	    	return trailingslashit(get_template_directory_uri())."plugins/login-with-ajax/$template_path";
    	    }

    to

    if( file_exists(get_stylesheet_directory().'/plugins/login-with-ajax/'.$template_path) ){ //Child Theme (or just theme)
    	    	return trailingslashit(get_stylesheet_directory_uri())."plugins/login-with-ajax/$template_path";
    	    }else if( file_exists(get_template_directory().'/plugins/login-with-ajax/login-with-ajax.js'.$template_path) ){ //Parent Theme (if parent exists)
    	    	return trailingslashit(get_template_directory_uri())."plugins/login-with-ajax/$template_path";
    	    }

    Thanks!

    http://wordpress.org/extend/plugins/login-with-ajax/

  2. angelo
    NetWebLogic Support
    Posted 10 months ago #

    hi, we will look into this.

  3. Marcus
    NetWebLogic Support
    Plugin Author

    Posted 10 months ago #

    sorry for all the template changes, was necessary so that we can include more than one widget on a page. hopefully big changes like this won't happen again!

    thanks for pointing that error out, will fix in next update (i think there's a mistake in the elseif() though, still checks the js file).

  4. Daedalon
    Member
    Posted 10 months ago #

    We are experiencing the same. Updating from 3.0 to 3.1.2 breaks the site. Only the "Log In" title for the Login with Ajax widget is displayed when user is not logged in. After that comes no output at all, hinting at a PHP error.

    Reverting to 3.0.4.1 reverted things back to normal.

  5. Eek
    Member
    Posted 10 months ago #

    I know changes are sometimes necesary, but having backward compatibility is always a huge plus, especially since more than 90% of your plugin users will be just that. Users. They will not have the necesarry skills to modify their themes to make it work again. But yeah, you could say that if they didn't modifiy their widget's php's, they'll be fine.

    Also, I'm using lwa with otto's simple facebook connect, and I could share the code snippet to include a login button to your widgets, also I could make some options in the option page for users to include / exclude button if they have SFC installed or not. If you'd want to include them in a next release or something :)

    Thanks,
    Eek

  6. Daedalon
    Member
    Posted 10 months ago #

    If a backwards incompatibility of this scale (whole site breaking) is known, then it'd be nice to handle so that users who would experience this wouldn't, because the handler code catches it and intervenes.

    In this case this order of magnitude in the error was rather surprising - perhaps due to a mistake in the elseif() as Marcus mentioned.

  7. efernandez
    Member
    Posted 10 months ago #

    I had exactly the same issue, breaking the page that uses Login with AJAX. When a fix is released I'll retry the 3.1.x branch.

  8. Marcus
    NetWebLogic Support
    Plugin Author

    Posted 10 months ago #

    @Eek, paste away, if I can use it, I will!

  9. efernandez
    Member
    Posted 8 months ago #

    Hi, any news on an update that would include this fix?
    Thanks.

  10. esmi
    Theme Diva & Forum Moderator
    Posted 8 months ago #

    @efernandez: As per the Forum Welcome, please post your own topic. This one is 2 months old!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.