Gallery Help Please

Started on the old forum in December 2007 · view the original in the archive · old links redirect here

2 replies · 454 views · started 18 years ago · 1 min read

Guest #1

Hi,the following file worked up until the sites went of line last week,but i now get the following error and dont know why

Warning: copy(misc/beutDayPurpleSexyFairyDark.gif) [function.copy]: failed to open stream: Permission denied in /home/******/public_html/addmisc.php on line 24 Couldn't copy file.

<?php include("config.inc.php"); echo '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta http-equiv="Content-Type" content="text/html"/> <meta http-equiv="Cache-Control" content="no-cache" forua="true"/> <title>add pic</title></head> <body bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080"> '; if ($upload="upload"&&$superdat_name){ if (!eregi("\.(gif|jpg|png|jpeg|wbmp)$",$superdat_name)){ print "**Unsuported File extention!!!**"; }else{ $superdat_name = preg_replace( '/[^a-zA-Z0-9\.\$\%\'\`\-\@\{\}\~\!\#\(\)\&\_\^]/' ,'',str_replace(array(' ','%20'),array('_','_'),$superdat_name)); if(strlen($superdat_name)>53){ print "**File Name to long!!!**"; }else{ if (empty($superdat)) { print "**No input file specified!!!**"; }else{ copy("$superdat", "misc/$superdat_name") or die("Couldn't copy file."); } echo "**$superdat_name** has been successfully uploaded"; } } } $result=mysql_query("select * from members where username='$username' and password='$password'"); $number_of_rows = mysql_num_rows($result); if ($number_of_rows>0) echo "<a href=\"welcome.php?username=$username&amp;password=$password\">Main Page</a>"; { ?> <FORM ACTION="addmisc.php?username=$username" METHOD="POST" ENCTYPE="multipart/form-data"> **File to be sent :** <input type="file" name="superdat"> <input type="hidden" name="upload" value="upload"/> <INPUT TYPE=SUBMIT NAME="submit" VALUE="Upload File"> <?}?> </FORM> </body> </html>
nclemale36 Lead · 537 posts #2

Hi,the following file worked up until the sites went of line last week,but i now get the following error and dont know why

Warning: copy(misc/beutDayPurpleSexyFairyDark.gif) [function.copy]: failed to open stream: Permission denied in /home/******/public_html/addmisc.php on line 24 Couldn't copy file.

<?php include("config.inc.php"); echo '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta http-equiv="Content-Type" content="text/html"/> <meta http-equiv="Cache-Control" content="no-cache" forua="true"/> <title>add pic</title></head> <body bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080"> '; if ($upload="upload"&&$superdat_name){ if (!eregi("\.(gif|jpg|png|jpeg|wbmp)$",$superdat_name)){ print "**Unsuported File extention!!!**"; }else{ $superdat_name = preg_replace( '/[^a-zA-Z0-9\.\$\%\'\`\-\@\{\}\~\!\#\(\)\&\_\^]/' ,'',str_replace(array(' ','%20'),array('_','_'),$superdat_name)); if(strlen($superdat_name)>53){ print "**File Name to long!!!**"; }else{ if (empty($superdat)) { print "**No input file specified!!!**"; }else{ copy("$superdat", "misc/$superdat_name") or die("Couldn't copy file."); } echo "**$superdat_name** has been successfully uploaded"; } } } $result=mysql_query("select * from members where username='$username' and password='$password'"); $number_of_rows = mysql_num_rows($result); if ($number_of_rows>0) echo "<a href=\"welcome.php?username=$username&amp;password=$password\">Main Page</a>"; { ?> <FORM ACTION="addmisc.php?username=$username" METHOD="POST" ENCTYPE="multipart/form-data"> **File to be sent :** <input type="file" name="superdat"> <input type="hidden" name="upload" value="upload"/> <INPUT TYPE=SUBMIT NAME="submit" VALUE="Upload File"> <?}?> </FORM> </body> </html>

have u lost ya misc folder in the downtime.

Guest #3

have u lost ya misc folder in the downtime.

No the folders are still there, it happens in all cats, everything was working ok till site went of line for a few days, hits counter is no longer working either External image (may be gone) worked hard on the site as well ,took me ages to get the gallery working in the first place

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close