|
Posted by affiliateian on 03/02/07 11:35
ok, running this now:
<?php
$filename=__FILE__;
$content = implode('', file($filename));
preg_match("/<title>(.*)<\/title>/i", $content, $match);
$title = $match[1];
$link='http://www.stumbleupon.com/submit?url='.
$_SERVER['SCRIPT_URI'].'&title='.urlencode($title);
?>
<a href='<?php echo $link;?>'> Link to stumbleupon</a>
Unfortunately, I think because we are running the php in an include
file, the echo link is not working. Viewing the php file directly
works but when this piece of code is placed in a php file inside
a .shtml file, it no longer echos the url or title.
Any ideas of how we can get around this?
Navigation:
[Reply to this message]
|