Posted by william.hooper on 10/14/07 13:55
here is my form:
<html>
<head></head>
<body>
<FORM ACTION="code.php" method="post">
<INPUT TYPE=SUBMIT NAME="arty.jpg" VALUE="Action">
</FORM>
</body>
</html>
here is code.php:
<?php
if(!empty($_POST)){
foreach($_POST as $myFile => $value){
echo "$myFile";
}
}
?>
What I was expecting is that the code would print out "arty.jpg" when
you click the button.
Instead it prints out "arty_jpg"
So the Post method is changing "." to "_"
But I need to pass the filename which may include both "_" and "."
character.
I guess I need some kind of escape and unescape funtion.
Please can someone reccomend one.
PS I am working on a file upload / downalod / delete form at this
link:
http://willyhoops.com/upload/
Many Thanks...
Navigation:
[Reply to this message]
|