Jump to content

[SOLVED] thumbnails to fullsize


runei

Recommended Posts

Hello.

 

Im working on a simple photo gallery for my website. I have created pagination and thumbnails for the gallery, but i also want users to click a image and see it in full size. I briefly looked at a java script but i am not really sure how to proceed. Appreciate any suggestions.

 

runei

 

heres the java script.

<a href="javascript:window.open('path......','FullView','top=100,left=100,width=7 00,height=500,resizable=yes,scrollbars=no,location =no,menubar=no,status=no,toolbar=no'); void('');">

<img src="path....">

</a>

 

 

heres my code:

 

<?php
echo "<table cellspacing=\"10\"cellpadding=\"10\">";
$sql = "SELECT * FROM mar_photo";
$res = mysql_query($sql) or die (mysql_error());
//Puts it into an array

$pager = new PS_Pagination($con,$sql,15,20);
$rs = $pager->paginate();

$i = 0;
$max_columns = 6;

while($row = mysql_fetch_assoc($rs))
{
echo "<td border=\"1\" id=\"form\">";	
//Outputs the image and other data
echo "<img src=images/thumbs/".$row['photo']." > <br>";

echo "<b>Title :</b> ".$row['name'] . "<br> ";

echo "</td>";
      if(++$i == $max_columns) 
       {
           echo "</tr>";
           $i=0;
       }  // end if 
}

echo $pager->renderFullNav();

echo "</table>";

Link to comment
https://forums.phpfreaks.com/topic/147585-solved-thumbnails-to-fullsize/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.