Jump to content

Strange PHP $_POST problem with IE


ahzulfi

Recommended Posts

Hello,

i have made Video Sharing Script called ClipBucket its Live Demo is here

http://clip-bucket.com/livedemo

 

use

usename : demo

password : demo

 

for demo login

 

the problem m getting is on this page

http://clip-bucket.com/livedemo/watch_video.php?v=315c27e5a3c50d0

 

When i use FireFox and Click On "Add To Favoutires" the Form Submits and value is then called in PHP using $_POST['form_field'] and then Video added to the favourites

but

when i use Internet Explorer 6~7  and Click on "Add To Favoutires" the Form Sumits but the value doesnt pass to $_POST and hence Video doesnt add to favourites.

 

here is the code that i use for sumission in HTML

 

<form method="post">
<input name="add_to_fav" type="image" value="add_video" src="{$imageurl}/fav_icon.png" 	alt="Add This Video To Favourites" title="Add This Video To Favourites"/>
</form>

 

Here is the code which check the FORM_FIELD value

//Adding Video To Favourite

if(isset($_POST['add_to_fav'])){

$userquery->logincheck();

$msg=$myquery->AddToFavourite($_COOKIE['userid'],$videos['videoid']);

}

 

 

Dont know, Why internet Explorer is Causing this problem  ???

 

Please Help Me    :-\

 

Thanks

ArslanHassan

 

Link to comment
https://forums.phpfreaks.com/topic/92598-strange-php-_post-problem-with-ie/
Share on other sites

:o :o :o

Man i sort this problem out and it seems to be a very strange one

 

the problem is that

the image field of form like

<input type='image' value ='somevalue' name='test'>

 

in all browsers, except IE , value of $_POST['test'] will be 'somevalue' bu IE shows nothing

instead its shows the value using x-y coordinates

$_POST['test_x'] & $_POST['test_y]

 

This seems to be very strange for me....

 

how can this be fixed......

now i got another problem, i have passed a value to the image field ie

 

<input type='image' value='value1' name='image'>

<input type='image' value='value2' name='image'>

 

i want to get value from $_POST['image'] , when one the image field is pressed it will passed the value ie if second one is pressed it will pass the value 'value2' but in IE m not getting its value due to which i m having too much problem.

i have 10+ customers with each 3 Templates = 30 Pages  i have to change if i have to set a hidden field, this would be a nice idea but please tell me if there is any other way to get rid of this problem

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.