Reply to Re: 2 submision buttons & IE problem

Your name:

Reply:


Posted by Rik on 01/22/07 21:27

luigi7up wrote:
> I tried this:
>
> <button type='submit' name='task[0]' value='refresh' title='dodaj u
> košaricu' >Bla Bla</button>
> <button type='submit' name='task[0]' value='add' title='dodaj u
> košaricu'>Bla</button>"
>
> still no result in IE.


Please don't topppost. I'll forgive you this time as I was too lazy to
check my abviously now faulty answer :-P.

Indeed, running the following:
<?php
readfile('php://input');
?>
<form method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>">
<button type='submit' name='task' value='refresh' title='dodaj u
košaricu' >Bla Bla</button>
<button type='submit' name='task' value='add' title='dodaj u
košaricu'>Bla</button>
</form>

Clicking the first button:
Results in MSIE:
task=Bla+Bla&task=Bla

In Firefox:
task=refresh


So, 2 differences: the one posts both _contents_ of 'task', the later
overriding the first, the other only posts the clicked button with the
_value_.

I don't know which one's at fault here, as I never use the <button>, and
now I know why :-).
The other option I gave was just to use a styled <input type="submit">, now
I know this one works without a doubt, as I use it regulary.
--
Rik Wasmus

[Back to original message]


УдалСнная Ρ€Π°Π±ΠΎΡ‚Π° для программистов  •  Как Π·Π°Ρ€Π°Π±ΠΎΡ‚Π°Ρ‚ΡŒ Π½Π° Google AdSense  •  England, UK  •  ΡΡ‚Π°Ρ‚ΡŒΠΈ Π½Π° английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Π‘Π°ΠΉΡ‚ ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ Π² Π‘Ρ‚ΡƒΠ΄ΠΈΠΈ Π’Π°Π»Π΅Π½Ρ‚ΠΈΠ½Π° ΠŸΠ΅Ρ‚Ρ€ΡƒΡ‡Π΅ΠΊΠ°
ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ΠΈΠ΅ ΠΈ ΠΏΠΎΠ΄Π΄Π΅Ρ€ΠΆΠΊΠ° Π²Π΅Π±-сайтов, Ρ€Π°Π·Ρ€Π°Π±ΠΎΡ‚ΠΊΠ° ΠΏΡ€ΠΎΠ³Ρ€Π°ΠΌΠΌΠ½ΠΎΠ³ΠΎ обСспСчСния, поисковая оптимизация