moves all the Load More Posts-related code in this theme into inc/load-more-posts.php, for ease of finding it all
Why
Fixes #65 by ensuring that a conditional, which checks whether an argument is set in the POSTed params, will not always return false, by correcting the variable name that is checked to the proper name of the array containing the POSTed data
Testing/Questions
Features that this PR affects:
the "Load More Posts" button on region pages, such as /region/midwest/
Questions that need to be answered before merging:
[ ] Is this PR targeting the correct branch in this repository?
Steps to test this PR:
check out master/staging
visit /region/midwest/ and click the "More Posts" button until the page contains an element matching the selector #homepage-bottom article:not(.type-post) or #homepage-bottom article.type-roundup: this is a Roundup, which should not be appearing in the LMP return
check out this branch
Refresh /region/midwest/ and continue clicking until you're satisfied that no markup matching that selector are being returned by the LMP AJAX query.
Changes
This pull request makes the following changes:
$_post
to$_POST
inc/load-more-posts.php
, for ease of finding it allWhy
Fixes #65 by ensuring that a conditional, which checks whether an argument is set in the POSTed params, will not always return false, by correcting the variable name that is checked to the proper name of the array containing the POSTed data
Testing/Questions
Features that this PR affects:
/region/midwest/
Questions that need to be answered before merging:
Steps to test this PR:
/region/midwest/
and click the "More Posts" button until the page contains an element matching the selector#homepage-bottom article:not(.type-post)
or#homepage-bottom article.type-roundup
: this is a Roundup, which should not be appearing in the LMP return/region/midwest/
and continue clicking until you're satisfied that no markup matching that selector are being returned by the LMP AJAX query.