trying to change this php into smarty
hi okay
i am trying to add vids useing bitsontherun
but i would like to secure them i have the following which works but its missing a key issue
{php}
function get_signed_player($videokey,$playerkey) {
$path = "players/".$videokey."-".$playerkey.".js";
$expires = round((time()+3600)/60)*60;
$secret = "XQk1AIiCdNSBY57g5WlHpKcs";
$signature = md5($path.':'.$expires.':'.$secret);
$url = 'http://content.bitsontherun.com/'.$path.'?exp='.$expires.'&sig='.$signature;
return $url;
};
echo "<p>Watch this cool video:</p>";
echo "<script type='text/javascript' src='".get_signed_player('Yg1KVjze','byzWRkIQ')."'></script>";
{/php}
this part in the php Yg1KVjze i would like to set useing {$v.field_value} ie extra field
it i could get the above into smarty rather than direct php i think it would work better
any help on this would be great thanks in advance
__________________
X-cart - 4.3.2 loads of mods and custom code
|