WordPress.org

Ready to get started?Download WordPress

Forums

Advanced AJAX Page Loader
Trigger AJAX after going to another page? (2 posts)

  1. bfeeley
    Member
    Posted 1 year ago #

    I know this falls outside the scope of the plugin (which is awesome btw!), but I'm wondering how to trigger the AJAX load when coming form another page. Example:

    I'm running the AAPL plugin, and I'm really only utilizing it on 1 page:

    vynation.brianfeeley.com/team

    When you click on the team members, it loads their bio at the top of the page via the url vynation.brianfeeley.com/i_am/team-member-name.

    Now, I also have links to the bios on the homepage that send you to the example link above. But of course, since I can't exclude those urls, they try to fire the ajax loader on the homepage, instead of going to the team page and THEN loading the bio.

    So, question is, how would i go about having someone click the link on the homepage, send them to the team page, and then fire the ajax call to load the correct bio?

    b.

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

  2. Jesús Franco
    Member
    Posted 1 year ago #

    So far I've understood the plugin code, it's not feasible but you could rewrite it a bit in order to:

    - load the scripts only in the page you need that functionality

    - then, on document.ready, fire the AJAX action to load the content in the area you want

    So, It's not so easy, and if you only want that function in an specific homepage, probably you would be best served with children pages.

    AJAX should be used to enhance the users experience, not only to provide a fancy effect.

    My 2 cents

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.