Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Retrieve submited value of the submit botton.

Posted on 2006-07-13
2
229 Views
Last Modified: 2013-12-13
Retrieve submited value of the submit botton.
Please don't user javascript

1st form

Form1.php

<form method="POST" action="didclick.php">
<input type="submit" value="ClickA" name="ClickA" >
<br>
<input type="submit" value="ClickB" name="ClickB" >
</form>


2nd form
didclick.php
<?php
Echo "Did click";
///something here
?>

Thanks
0
Comment
Question by:jetleestye
2 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 250 total points
ID: 17103279

<form method="POST" action="didclick.php">
<input type="submit" value="ClickA" name="ClickA" >
<br>
<input type="submit" value="ClickB" name="ClickB" >
</form>


2nd form
didclick.php
<?php
$click = "N/A";
if (isset($_POST['ClickA']))  $click = "ClickA";
if (isset($_POST['ClickB']))  $click = "ClickB";
 
Echo "Did click: $click";
///something here
?>
0
 

Author Comment

by:jetleestye
ID: 17104094
thank you
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Generating table dynamically is the most common issue faced by php developers.... So it seems there is a need of an article that explains the basic concept of generating tables dynamically. It just requires a basic knowledge of html and little maths…
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question