I have a button, I want it to echo something after it is clicked... I have this (example echo/code)... <form method="post" action=""> <input src="delete.png" name="delete" type="image" value="delete" > </form> <? if(!empty($_POST['delete'])) { echo "Hi"; } ?> I run this on firefox and it works, -Echos 'Hi'... I run this on IE and it doesnt work, -it refreshes the page, but no 'Hi' is loaded, how come? Please can anyone fix this? Thanks... James
When you click an image button in IE you get $_POST['delete_x'] and $_POST['delete_y'] reflecting the exact coordinates of where the user clicked. So you need to check whether either $_POST['delete'] or $_POST['delete_x'] is set, not just the first.
Sucks that people still even use IE, life would be so much easier if the whole world just used Firefox haha
You could do: <form method="post" action="#"> <input src="delete.png" name="delete" type="image" value="delete" > </form> <?php if(isset($_POST['delete'])) { echo "Hi"; } ?> Code (markup):
Use Google Chrome! I only started using it the other day but I'm already liking it alot. It even has a built in spell check and is very fast!