PHP/HTML question.
#5

Quote:
Originally Posted by XFlawless
Посмотреть сообщение
Add enctype="multipart/form-data" to your <form>.

I want to check the image size, then it should be save.

PHP код:
list($width$height$type$attr) = getimagesize($_FILES['pic_name']['tmp_name']);
if (
$width 125 || $height 125)
{
  echo 
"Maximum width and height exceeded. Please upload images below 125 x 125 px size";
  exit();
}
// Check file extension then save the file. 

Are you blind :P ? He is clearly using POST method.
Ok i did this:

Код HTML:
<form name="addmapform" method="post" action="objectadd.php" enctype="multipart/form-data">
And what does "exit();" do ?

EDIT

PHP код:
echo $width " - " $height " - " $type " - " $attr
tried this, but doesnt show something
Reply


Messages In This Thread
PHP/HTML question. - by Michael@Belgium - 22.03.2012, 17:49
Re: PHP/HTML question. - by Slice - 22.03.2012, 18:00
Re: PHP/HTML question. - by mevi - 22.03.2012, 18:18
Re: PHP/HTML question. - by XFlawless - 23.03.2012, 02:47
Re: PHP/HTML question. - by Michael@Belgium - 23.03.2012, 16:48
Re: PHP/HTML question. - by royal_king - 23.03.2012, 17:13
Re: PHP/HTML question. - by Michael@Belgium - 23.03.2012, 19:41
Re: PHP/HTML question. - by XFlawless - 24.03.2012, 03:16

Forum Jump:


Users browsing this thread: 1 Guest(s)