This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Remove .php -and- Force Trailing Slash | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteCond %{REQUEST_FILENAME}\.php -f | |
RewriteRule ^(([^/]+/)*[^./]+)/$ $1.php | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteCond %{REQUEST_URI} !(\.[a-zA-Z0-9]|/)$ | |
RewriteRule (.*)$ /$1/ [R=301,L] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Unset unwanted Scripts - by name | |
$unset_script = array('k2'); | |
foreach($this->_scripts as $name=>$script) | |
{ | |
foreach($unset_script as $script) | |
{ | |
if (strpos($name,$script) !== false) | |
{ | |
unset($this->_scripts[$name]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<-- Replace sample data --> | |
<-- Append '&is_video=true' for video (YouTube & Vimeo) and audio pins (Soundcloud) | |
http://api.addthis.com/oexchange/0.8/forward/pinterest_share/offer?url=http://domain.com&title=Sample Title&screenshot=http://placehold.it/350x550&description=Sample Description&pubid=XYZ | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Produce and size pop-up | |
<script> | |
function PopupCenter(pageURL, title,w,h) { | |
var left = (screen.width/2)-(w/2); | |
var top = (screen.height/2)-(h/2); | |
var targetWin = window.open (pageURL, title, 'toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width='+w+', height='+h+', top='+top+', left='+left); | |
} | |
</script> | |
<a rel="nofollow" href="javascript:void(0);" onclick="PopupCenter('http://api.addthis.com/oexchange/0.8/forward/facebook/offer?url=<?php echo $this->item->absoluteURL; ?>&pubid=ra-XXXXXX', 'FacebookShare',650,400);" title="Facebook Share">Facebook</a> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// remove single and double quotes - place at top of item override file | |
<?php | |
$safe = array("'", """); | |
$nonsafe = array("'", "\""); | |
?> | |
// code to generate meta data (change ExtrafieldAlias) - place after above code | |
<?php $doc->addCustomTag('<meta property="anything" content="'.str_replace($nonsafe, $safe, $this->item->extraFields->ExtrafieldAlias->value).'" />'); ?> |