Beginner question about onclick=window.open
Posted: Thu Apr 22, 2010 3:33 pm
Hello
I am pretty new to php and web development. Have many years programming in other langs.
here is my question. How can I get the following to work correctly.
<?php
$str_MyNewPic='/home/mudgeste/public_html/photo_Gallery/public/images/'.$photo->division.'/'.$photo->month.'_'.$photo->year.'/'$photo->filename.'/';
?>
<a onclick="window.open(<?php echo $str_MyNewPic; ?>, 'mywindow', 'width=800', 'height=200')" href="#">
<img src="<?php echo 'http://www.mudgesteve.com/photo_Gallery ... ->filename; ?>" />
<?php echo $str_MyNewPic; ?>
</a>
I am trying to open a very large picture in its own window.
currently '$str_MyNewPic' holds the path to the picture.
I thought the onclick="window.open(what page to view, name for the new window, width of it, height of it)" href="#"
Please help
I am pretty new to php and web development. Have many years programming in other langs.
here is my question. How can I get the following to work correctly.
<?php
$str_MyNewPic='/home/mudgeste/public_html/photo_Gallery/public/images/'.$photo->division.'/'.$photo->month.'_'.$photo->year.'/'$photo->filename.'/';
?>
<a onclick="window.open(<?php echo $str_MyNewPic; ?>, 'mywindow', 'width=800', 'height=200')" href="#">
<img src="<?php echo 'http://www.mudgesteve.com/photo_Gallery ... ->filename; ?>" />
<?php echo $str_MyNewPic; ?>
</a>
I am trying to open a very large picture in its own window.
currently '$str_MyNewPic' holds the path to the picture.
I thought the onclick="window.open(what page to view, name for the new window, width of it, height of it)" href="#"
Please help