Really confused!! I run once and it worked, but when i tried today...it didn't work
Which part is missing
if(isset($_POST['upload'])){
$filename=$_FILES['file']['name'];
$filetype=$_FILES['file']['type'];
$filesize=$_FILES['file']['size'];
if(empty($filename)){
$warning="<span class=style2><font color=red>* You did not upload any file</font></span>";}else
if((!empty($filename))&&($filetype!='application/msword')){
$warning="<span class=style2><font color=red>* Word document only allowed to be uploaded</font></span>";
}else
if((!empty($filename))&&($filesize>120000)){
$warning="<span class=style2><font color=red>* File size exceeds maximum allowed</font></span>";
}else{
COPY TO UPLOAD BLABLABLA..}
THe problem is that when i upload the word document with less than 120 kb filesize, "* Word document only allowed to be uploaded"
Do something every fifth time?
I'm trying to write a loop, but I want it to do something different after every fifth instance. Like, I want it do something like this:Quoteecho $a1;echo $a2;echo $a3;echo $a4;echo $a5.$b;echo $a6;And
comparing tables across databases sql refinement ideas required
Hi all
Help with usergroups? prolly really quick
So were coding our own forums for a game system we made an we have the users level setup but now I need to make it do user groups. See the groups are defined by numbers:0 - banned1 - registered2 -
php form help
Hey,I use a control file to set my meta tags and titlesHere's an exampleCode: <?phpswitch ($sheet_name) { case 'page-2'://The page that has $sheet_name equal to the case value, this is the
Certain files upload, while others do not
I want to read the data from an uploaded file. Not sure why, but it only uploads for certain files. Not sure if it has to do with the size or what. Even when I comment all of the if and else
php multiple action on submit
I have a form which says:<form enctype='multipart/form-data' method='post' action='process.php' target='_blank'>I need to call process.php on submit or on clicking submit button. Now
how do I show what a user have selected from a checkbox?
From my code below, how would i show which check boxes have been checked and which radio buttons selected?Code:
How do I give a developer access to a specific directory and nothing else?
I want to give a develop access to a specific directory and nothing elseI can give them an FTP account with access to a sub directory, but this doesn't exactly solve the problem!1. They can write PHP
Customizing message/behavior
Hi,I'm using the ASP.NET membership/authorization controls in my application. Some parts of my application are reserved for users who are in certain roles i.e. editor, writer, etc. I control this with
Baffled by Undefined Index in Simple Array: Please Help!
Hello. I have a form which posts an array to this script. However, I can't seem to access the values in the array; I keep getting an undefined index. Something is not right, but the code is so simple!