Yes, all are using the same template, with php path set to
https://www.tedweinstein.com/pics/phplugins
OLD - from a few months ago - works fine - here’s top of index.php for
(Angel Island Jaunt - Ted Weinstein Photography) - if you view page source you can see the Google tracking code is correctly embedded in the page head.
> <?php
/*
*
* TTG Core Elements - "PHPlugins" User Hook interface
* designed by john bishop images (http://johnbishopimages.com)
* for Matthew Campagna of The Turning Gate (http://theturninggate.net)
*
*/
// Begin hook processing
define( 'TTG_ROOT', __FILE__ );
define( 'TTG_HOOK', '/home/tedweins/public_html/pics/phplugins' );
define( 'TTG_COMP', 'TTG CE4-Gallery 4.0' );
if (file_exists( TTG_HOOK . '/phplugins.php')) {
require_once TTG_HOOK . '/phplugins.php';
}
if (function_exists('ttg_user_load')) {
$void = ttg_user_load( TTG_COMP, TTG_ROOT );
}
?><?php
if (!function_exists('currentPageURL')) {
// Gets current page URL
function currentPageURL() {
$pageURL = 'http';
if (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on') {$pageURL .= "s";}
$pageURL .= "://";
if ($_SERVER["SERVER_PORT"] != "80") {
$pageURL .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"];
} else {
$pageURL .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"];
}
return $pageURL;
}
}
if (!function_exists('currentPageLocation')) {
// Gets current page parent location
function currentPageLocation() {
$currentPageURL = currentPageURL();
$returnURL = '';
$finalSlash = strrpos(currentPageURL(), '/');
if (strrpos($currentPageURL, '.') > strrpos($currentPageURL, '/')) // has a file after the final slash, e.g. http://url/directory/index.php
$returnURL = substr($currentPageURL, 0, $finalSlash);
else if (strrpos($currentPageURL, '?') > strrpos($currentPageURL, '/')) // has a ? after the final slash, e.g. http://url/directory/index.php
$returnURL = substr($currentPageURL, 0, $finalSlash);
else if ($finalSlash == strlen($currentPageURL)-1) // final character is a slash, e.g. http://url/directory/
$returnURL = substr($currentPageURL, 0, $finalSlash);
else // final character is not a slash, e.g. http://url/directory
$returnURL = $currentPageURL;
return $returnURL;
}
}
if (!function_exists('currentPageName')) {
// Gets current page name.
function currentPageName() {
return substr($_SERVER["SCRIPT_NAME"],strrpos($_SERVER["SCRIPT_NAME"],"/")+1);
}
}
if (!function_exists('truncate')) {
// Truncates string to length.
function truncate($str, $len=70) {
if (strlen($str) > $len) {
return substr($str, 0, $len-2) . '…';
} else {
return $str;
}
}
}
// Set constants for use in PHPlugins
define("PAGEIMAGE", "photos/20240316_768C8205.jpg");
define("CURRENTPAGEURL", currentPageURL());
define("CURRENTPAGELOCATION", currentPageLocation());
define("CURRENTPAGENAME", currentPageName());
define("ALBUMTITLE", 'Angel Island Jaunt');
if (!defined('TTG_SITE')) {
define("TTG_SITE", "http://www.tedweinstein.com/");
}
?><!DOCTYPE html>
<!--[if lt IE 7]><html class="ce4 no-js lt-ie9 lt-ie8 lt-ie7" dir="ltr" lang="en" xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"><![endif]-->
<!--[if IE 7]><html class="ce4 no-js lt-ie9 lt-ie8" dir="ltr" lang="en" xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"><![endif]-->
<!--[if IE 8]><html class="ce4 no-js lt-ie9" dir="ltr" lang="en" xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"><![endif]-->
<!--[if gt IE 8]><!--><html class="ce4 no-js gt-ie8" dir="ltr" lang="en" xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"><!--<![endif]-->
<head>
<meta charset="utf-8" />
<!--[if IE]><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><![endif]-->
<meta name="robots" content="noarchive, noindex, nofollow" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="author" content="Ted Weinstein Photography" />
<meta name="title" content="Angel Island Jaunt - Ted Weinstein Photography" />
<meta name="generator" content="CE4 Gallery 6.1.6, 28 published images" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="HandheldFriendly" content="True" />
<meta name="MobileOptimized" content="320" />
<meta name="viewport" content="width=device-width, height=device-height, maximum-scale=1.0, minimum-scale=1.0, initial-scale=1.0" />
<title>Angel Island Jaunt - Ted Weinstein Photography</title>
<link rel="apple-touch-icon-precomposed" href="./lib/images/apple-touch-icon.png" />
<link rel="icon" type="image/x-icon" href="./lib/images/favicon.ico" />
<script>
if (screen.width < 768 || navigator.userAgent.match(/Android|Blackberry|SymbianOS|iPhone|iPod|iPad/i)){
window.location.replace('mobile.php'); }
</script>
<link rel="stylesheet" type="text/css" media="all" href="./lib/css/scaffolding.min.css" />
<link rel="stylesheet" type="text/css" media="all" href="./lib/css/font-awesome.min.css" />
<link rel="stylesheet" type="text/css" media="all" href="./lib/css/style-common.css" />
<link rel="stylesheet" type="text/css" media="all" href="./lib/css/style-component.css" />
<?php
$add_mode = true;
if ( function_exists('ttg_style_navigation') ) {
if ( !(ttg_style_navigation( TTG_COMP, TTG_ROOT )) ) {
$add_mode = false;
}
}
if ( $add_mode ) { ?> <link rel="stylesheet" type="text/css" media="screen" href="./lib/css/navigation.css" />
<?php } ?>
<link rel="stylesheet" type="text/css" media="print" href="./lib/css/print.css" />
<script src="./lib/js/modernizr.custom.79601.js"></script>
<script src="./lib/js/jquery-1.11.3.min.js"></script>
<script src="./lib/js/jquery.ba-throttle-debounce.min.js"></script>
<script src="./lib/js/init.head.min.js"></script>
<!--[if (gte IE 6)&(lte IE 8)]>
<script src="./lib/js/respond.min.js"></script>
<![endif]-->
<!--[if (lte IE 10)]>
<![endif]-->
<?php
if ( function_exists('ttg_head_end') ) {
$void = ttg_head_end( TTG_COMP, TTG_ROOT );
} ?>
</head>
And here is NEW - ** DOESN’T WORK** - here’s top of index.php for
(Two Days in Oxford with the Chenery Gals - Ted Weinstein Photography) - if you view source, you can see the Google code is NOT inserted in the head.
<?php
/*
*
* TTG Core Elements - "PHPlugins" User Hook interface
* designed by john bishop images (http://johnbishopimages.com)
* for Matthew Campagna of The Turning Gate (http://theturninggate.net)
*
*/
// Begin hook processing
define( 'TTG_ROOT', __FILE__ );
define( 'TTG_HOOK', '/home/tedweins/public_html/pics/phplugins' );
define( 'TTG_COMP', 'TTG CE4-Gallery 4.0' );
if (file_exists( TTG_HOOK . '/phplugins.php')) {
require_once TTG_HOOK . '/phplugins.php';
}
if (function_exists('ttg_user_load')) {
$void = ttg_user_load( TTG_COMP, TTG_ROOT );
}
?><?php
if (!function_exists('currentPageURL')) {
// Gets current page URL
function currentPageURL() {
$pageURL = 'http';
if (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on') {$pageURL .= "s";}
$pageURL .= "://";
if ($_SERVER["SERVER_PORT"] != "80") {
$pageURL .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"];
} else {
$pageURL .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"];
}
return $pageURL;
}
}
if (!function_exists('currentPageLocation')) {
// Gets current page parent location
function currentPageLocation() {
$currentPageURL = currentPageURL();
$returnURL = '';
$finalSlash = strrpos(currentPageURL(), '/');
if (strrpos($currentPageURL, '.') > strrpos($currentPageURL, '/')) // has a file after the final slash, e.g. http://url/directory/index.php
$returnURL = substr($currentPageURL, 0, $finalSlash);
else if (strrpos($currentPageURL, '?') > strrpos($currentPageURL, '/')) // has a ? after the final slash, e.g. http://url/directory/index.php
$returnURL = substr($currentPageURL, 0, $finalSlash);
else if ($finalSlash == strlen($currentPageURL)-1) // final character is a slash, e.g. http://url/directory/
$returnURL = substr($currentPageURL, 0, $finalSlash);
else // final character is not a slash, e.g. http://url/directory
$returnURL = $currentPageURL;
return $returnURL;
}
}
if (!function_exists('currentPageName')) {
// Gets current page name.
function currentPageName() {
return substr($_SERVER["SCRIPT_NAME"],strrpos($_SERVER["SCRIPT_NAME"],"/")+1);
}
}
if (!function_exists('truncate')) {
// Truncates string to length.
function truncate($str, $len=70) {
if (strlen($str) > $len) {
return substr($str, 0, $len-2) . '…';
} else {
return $str;
}
}
}
// Set constants for use in PHPlugins
define("PAGEIMAGE", "photos/20240529_IMG_2169.jpg");
define("CURRENTPAGEURL", currentPageURL());
define("CURRENTPAGELOCATION", currentPageLocation());
define("CURRENTPAGENAME", currentPageName());
define("ALBUMTITLE", 'Two Days in Oxford with the Chenery Gals');
if (!defined('TTG_SITE')) {
define("TTG_SITE", "http://www.tedweinstein.com/");
}
?><!DOCTYPE html>
<!--[if lt IE 7]><html class="ce4 no-js lt-ie9 lt-ie8 lt-ie7" dir="ltr" lang="en" xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"><![endif]-->
<!--[if IE 7]><html class="ce4 no-js lt-ie9 lt-ie8" dir="ltr" lang="en" xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"><![endif]-->
<!--[if IE 8]><html class="ce4 no-js lt-ie9" dir="ltr" lang="en" xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"><![endif]-->
<!--[if gt IE 8]><!--><html class="ce4 no-js gt-ie8" dir="ltr" lang="en" xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"><!--<![endif]-->
<head>
<meta charset="utf-8" />
<!--[if IE]><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><![endif]-->
<meta name="robots" content="noarchive, noindex, nofollow" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="author" content="Ted Weinstein Photography" />
<meta name="title" content="Two Days in Oxford with the Chenery Gals - Ted Weinstein Photography" />
<meta name="generator" content="CE4 Gallery 6.1.6, 60 published images" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="HandheldFriendly" content="True" />
<meta name="MobileOptimized" content="320" />
<meta name="viewport" content="width=device-width, height=device-height, maximum-scale=1.0, minimum-scale=1.0, initial-scale=1.0" />
<title>Two Days in Oxford with the Chenery Gals - Ted Weinstein Photography</title>
<link rel="apple-touch-icon-precomposed" href="./lib/images/apple-touch-icon.png" />
<link rel="icon" type="image/x-icon" href="./lib/images/favicon.ico" />
<script>
if (screen.width < 768 || navigator.userAgent.match(/Android|Blackberry|SymbianOS|iPhone|iPod|iPad/i)){
window.location.replace('mobile.php'); }
</script>
<link rel="stylesheet" type="text/css" media="all" href="./lib/css/scaffolding.min.css" />
<link rel="stylesheet" type="text/css" media="all" href="./lib/css/font-awesome.min.css" />
<link rel="stylesheet" type="text/css" media="all" href="./lib/css/style-common.css" />
<link rel="stylesheet" type="text/css" media="all" href="./lib/css/style-component.css" />
<?php
$add_mode = true;
if ( function_exists('ttg_style_navigation') ) {
if ( !(ttg_style_navigation( TTG_COMP, TTG_ROOT )) ) {
$add_mode = false;
}
}
if ( $add_mode ) { ?> <link rel="stylesheet" type="text/css" media="screen" href="./lib/css/navigation.css" />
<?php } ?>
<link rel="stylesheet" type="text/css" media="print" href="./lib/css/print.css" />
<script src="./lib/js/modernizr.custom.79601.js"></script>
<script src="./lib/js/jquery-1.11.3.min.js"></script>
<script src="./lib/js/jquery.ba-throttle-debounce.min.js"></script>
<script src="./lib/js/init.head.min.js"></script>
<!--[if (gte IE 6)&(lte IE 8)]>
<script src="./lib/js/respond.min.js"></script>
<![endif]-->
<!--[if (lte IE 10)]>
<![endif]-->
<?php
if ( function_exists('ttg_head_end') ) {
$void = ttg_head_end( TTG_COMP, TTG_ROOT );
} ?>
</head>
I have looked line-by-line - what is the difference between the two index.php files for these two parallel, identically-generated galleries that is leading to different behavior?