WordPress.org

Ready to get started?Download WordPress

Forums

Advanced AJAX Page Loader
[resolved] Just want to exclude homepage from ajax load (4 posts)

  1. binga30
    Member
    Posted 1 year ago #

    Hi,

    I have been using the plugin to great effect on my site, and have modified line 43 of the ajax-page-loader.js to exclude some page of my site from loading in ajax.

    Ex: if ( this.href.indexOf(AAPLhome) >= 0 etc....

    Now i need to exclude the homepage links from loading in ajax. I cant use the full relative path as that means all links will be excluded so I tried to target my links by adding a class and using the jquery hasClass selector. However this does not work.

    Ex: if ( this.hasClass('homelink)) etc....

    This gives the error this.hasClass is not a function. Can someone with a little more jquery experience please help me out to get this working?

    Thanks

    http://wordpress.org/extend/plugins/advanced-ajax-page-loader/

  2. rhaney
    Member
    Posted 1 year ago #

    I need the same thing for my site.. any luck or solution for this?

  3. binga30
    Member
    Posted 1 year ago #

    Yeh what I ended up doing was target the class of my link like above.

    Take a look here:
    http://stackoverflow.com/questions/14347632/jquery-if-statement-and-hasclass

  4. whoopcg
    Member
    Posted 1 year ago #

    Where should I insert that sort of code?

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic