ok this is the page. espan-glish.com/comments/
i want to display this code <center><a href="http://www.espan-glish.com/comments/index.php"><img src="http://mintywhite.com/images/techtips/0 ... a></center>
below the image that is on that site. but i will have a lot of images on different pages. so i just want a php or java script that will generate the web page url and the image address(url) automatically, so i wont hava to be typing the name of each page for each linking code.
like on this page myhotcomments.com/graphics/53696
that the code is there. and if it would be possible to add the webpage title
so how do i generate show an image address using php.
i already know how to put a web page self url using php.
i put this code in the head section
<?php
function curPageURL() {
$pageURL = 'http';
if ($_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;
}
?>
the i add this code whereever i want the url to appear
<?php echo curPageURL(); ?>
but now how do i get an the image url
i would really appreaciate any good help
image linking to me code php automatically
Moderator: General Moderators
Re: image linking to me code php automatically
Please use the php code tags.