Skip to content

anonymous /gist:8371ce267d480d2b6859 secret
Created

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
// NEW CODE:
// Update the dynamic data if we're on the continents.php page
if ($_SERVER['SCRIPT_NAME'] == '/continents.php')
{
$catDataObj = get_category_by_slug( @$_GET['continent'] );
if ($catDataObj !== false) // check that we have a valid continent value
{
$cid = $catDataObj->term_id;
$filter = array('filter'=>'cats', 'filterDetail'=>'all:' . $cid);
$contentDiv = preg_replace('|<li class="erwpFeaturedPhotos".*?data-filterDetail="[^"]*"|', '<li class="erwpFeaturedPhotos" data-filter="' . $filter['filter'] . '" data-filterDetail="' . $filter['filterDetail'] . '"', $contentDiv);
}
}
// EXISTING CODE:
// Search for dynamic content and replace
$contentDiv = self::replaceDynamicRotatorHTML($contentDiv);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.