Jump to content


Photo

submit <BUTTON> does not react


  • Please log in to reply
4 replies to this topic

#1 van2

van2
  • New Members
  • Pip
  • Newbie
  • 4 posts

Posted 05 September 2006 - 12:10 AM

Hi,

I have the strangest problem:

I have a site that navigates through dynamic php pages in a sort of "wizard" format. The entire script is one big file, so it keeps calling itself and relies on POST and SESSION variables to know what's going on.
I'm using html POST forms on each page and have only server-side validation, and do not want to use any client side script.

Here's the strange thing: I'm using html <BUTTON type="submit"> tags inside html FORMS. Most buttons work, but using the exact same code in other places, it displays correctly, but simply doesn't react. Have tried all of the following:

1. Tried three different web browsers
2. changed form method to "GET"
3. changed action field of form
4. added name, value parameters to buttons and form
5. added various additional fields to the form

The only thing that made it work was changing to <INPUT> instead of <BUTTON>, but this isn't good, since I'm using uniform stylized buttons everywhere.

And here's the strangest thing: one of the buttons doesn't work at all, another one works about every third click!

Anybody have any idea what this could be?

PHP v.4.4.4 w/ apache 2.1 and latest browsers

Here's the code in its most basic form (which doesn't work):

<form method="post" action="index.php">
<button type="submit">push here</button>
</form>



#2 Unknown User

Unknown User
  • Members
  • PipPip
  • Member
  • 16 posts

Posted 05 September 2006 - 12:16 AM

Wow thats wierd, i only just started makeing my webpage and don't know to much, but perhaps if you gave each button its own name?

<form method="post" action="index.php">
<button type="submit" name="submit1">push here</button>
</form>

?? IDK

#3 Wintergreen

Wintergreen
  • Members
  • PipPipPip
  • Advanced Member
  • 107 posts

Posted 05 September 2006 - 12:27 AM

I'd agree with the name thing, although it almost sounds like all your submit buttons are on the same form?

#4 perezf

perezf
  • Members
  • PipPipPip
  • Advanced Member
  • 301 posts
  • LocationFort Lauderdale

Posted 05 September 2006 - 12:38 AM

try this
<input type="submit" name="submit1" value="push here">

instead of this
<button type="submit" name="submit1">push here</button>


#5 van2

van2
  • New Members
  • Pip
  • Newbie
  • 4 posts

Posted 05 September 2006 - 07:53 PM

Thanks for the comments, I figured it out, i forgot to remove an empty (invisible) dreamweaver layer just above a portion of the the top of the page, so the layer was absorbing the clicks for all buttons that it covered! That's why some clicks were successful others weren't.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users