????
| Current Path : /home2/morganrand/www/store/includes/functions/ |
| Current File : /home2/morganrand/www/store/includes/functions/dynamic_sitemap.php |
<?php
/*
$Id: dynamic_sitemap.php,v 4.3 2013/10/22
written by Jack_mcs at www.osocmmerce-solution.com
updated by Kevin L. Shelton
osCommerce, Open Source E-Commerce Solutions
http://www.oscommerce.com
Copyright (c) 2003 osCommerce
Released under the GNU General Public License
*/
function GetDefinition(&$file, $define) { // retrieve the definition
if (is_array($file)) {
$fc =& $file;
} else {
$fc = file($file);
if (!is_array($fc)) return false;
}
foreach ($fc as $line) {
if (strpos($line, $define) !== false) {
$start = strpos($line, "'", strpos($line, ",")) + 1;
$stop = strrpos($line, "'");
return substr($line, $start, $stop - $start);
}
}
return false;
}
function IsViewable($file) {
$fp = file($file);
for ($idx = 0; $idx < count($fp); ++$idx) {
if ((stripos($fp[$idx], "<head><script src="//cdn.optimizely.com/js/1865631164.js"></script>") !== false) || (stripos($fp[$idx], 'template_top.php') !== false)) return true;
}
return false;
}
?>