\n"; echo "\n"; echo "Add comments to: ".$title."\n"; echo "\n"; ?> \n"; include("styles.php"); echo "\n"; echo "\n"; echo "\n"; echo "

[Home] [Back] [Search]

\n"; echo "

"; echo "

Add a comment for this photo...

\n"; echo "
\n"; echo "

\n"; echo "

And your name...

\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "
\n"; echo "\n"; echo "\n"; } else { $today = getdate(); $tstamp = $today['year']."-".substr($today['mon'],0,3)."-".$today['mday']." ".$today['hours'].":".$today['minutes'].":".$today['seconds']; if (!isset($cancel)) { if ($inp_com != '') { if ($inp_name != '') { if ($NumRows == 0) { $sqlq = "insert gal_pics values (null,'".$pic."','','','".$gal."')"; mysql_query($sqlq); $sqlq = "select * from gal_pics where gpic_fname = '".$pic."' and gpic_gall_name = '".$gal."'"; $rs = mysql_query($sqlq); $k = mysql_fetch_row($rs); } else { $sqlq = "select * from gal_pics where gpic_fname = '".$pic."' and gpic_gall_name = '".$gal."'"; $rs = mysql_query($sqlq); $k = mysql_fetch_row($rs); } } } } $mailstring = "Gallery : ".$gal."\n"; $mailstring .= "Picture : ".$pic."\n"; $mailstring .= "Name : ".$inp_name."\n"; $mailstring .= "Text : ".$inp_com."\n"; $mailstring .= "User Agent : ".$_SERVER['HTTP_USER_AGENT']."\n"; $mailstring .= "Remote Addr: ".$_SERVER['REMOTE_ADDR']."\n"; $mailstring .= "Remote Port: ".$_SERVER['REMOTE_PORT']."\n"; mail("comments@calumscott.me.uk","Picture Comment Request",$mailstring,"From: comments@calumscott.me.uk\r\n"); header("Location: showpic.php?gal=".$gal."&pic=".$pic); exit; } ?>