Hello,
Here is my problem in my first.php program I retrieved values from the database and displayed (each row contails one display and one edit button),when I click on edit button The page should be redirected to second.php and the id of that particular row should be retrived to the second.php page so that based on that id i can delete or upadte the data.
[php]
<html>
<body>
<table width="53%" border="0" cellspacing="5" cellpadding="0" align="left">
<form action="update. php" method='post'>
<?php
include("dbconn ect.php");
$res=mysql_quer y("select * from addemployee ");
echo"<table border='1'>
<tr>
<th>name</th>
<th>platform</th>
<th>designation </th>
<th>id</th>
<th>taddr</th>
<th>paddr</th>
<th>email</th>
<th>idcno</th>
<th>phno</th>
<th> update<th>
</tr>";
while($row=mysq l_fetch_array($ res))
{
echo "<tr>";
echo "<td> " . $row['name'] . "</td>";
echo "<td> " . $row['platform'] . "</td>";
echo "<td> " . $row['designation'] . "</td>";
echo "<td> " . $row['id'] . "</td>";
echo "<td> " . $row['taddr'] . "</td>";
echo "<td> " . $row['paddr'] . "</td>";
echo "<td> " . $row['email'] . "</td>";
echo "<td> " . $row['idcno'] . "</td>";
echo "<td> " . $row['phno'] . "</td>";
echo " <input type='hidden' value='$row[empid]' name='empid'>";
echo "<td>
<input type='button' name='Edit' value='Edit' onclick= 'self.open("sec ond.php?empid={ $row.[$empid]}","",width=400 );return false'>
<input type='button' name='Edit' value='Dlete' onclick=window. open('delelte.p hp')>
</td>";
echo"</tr>";
}
echo "</table>";
?>
</form>
</table>
</body>
</html>[/php] Read the Posting Guidelines at the top of this forum!!
Especially the part about enclosing shown code within php or code tags!!!
moderator
by this code Im not able to retrive id to second .php page.
please help me.
regards,
ramya
1 1685
well, you are sending the page to 'update.php' instead of 'second.php'
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Eric Kincl |
last post by:
Hello, its been a while since I posted/looked here... my normal email client
doesn't handle newsgroups :( (ximian evolution)
I was wondering how you stick a file into a database, and then retrive it
again for the user with PHP/MySQL. I tried the following which apparently
didnt work...
Very quick overview of what I did...
html
|
by: iffy agbim |
last post by:
I have a form that displays information selected from an Access Data
base. A select statement is used to do this on my asp page
SQLQuery = "SELECT * FROM tblopgaCOm2 WHERE billNo = '"
& Request.Form("BILLNO") & "' AND area LIKE 'AUDIT'"
billNo and area are the 2 fields used together to make the record we
need unique. example Bill d456(billNo) can be
assigned to various depts(area). as many depts as it is
assigned rep the many times...
|
by: jeghers |
last post by:
i have a page where info can be inserted in a form that consists of some
textarea and some textfield.
but when i get to the page, i want the last inserted info, which is saved in
a database, to be retrived and be displayet ind the 6 text field/area??? can
that be done?
the user can then edit some of the text and leave some of it unedited.....
can it be done??
|
by: MIchael McDowell |
last post by:
Anyidea how this might be done using and XML Web Service
and the XMLSerialzation class?
A pointer to an online example would be deeply appreciated.
Thankyou in advance,
Michael McD
|
by: Miguel Dias Moura |
last post by:
Hello,
i have an ASP.net / VB page with a Script (submitValues) and a Form.
1. The form has 20 input texts and a "Submit" button.
2. The script declares 20 variables. The value of each variable is taken
from each of the 20 input texts.
3. When the button "Submit" is click the variable values are sent to an
email address using AspNetEmail.
| |
by: Manish Naik |
last post by:
Hi,
Using ASP.Net, I want to store and retrive documents (Word, excel,
etc) from SQL Server 2000 database. I have tried image type data
field, but could not succed. Can any one help me please.
Regards,
Manish Naik
|
by: balakrishnan.dinesh |
last post by:
Hi frnds,
Im having a problem with retriving "\" backslash , In my
javascript client side page , ill get the response from the server side
, the response will contain some url like "\bank\index.htm" .
So what i have to do is, ill get those url and display them in
textfields ,
The problem is , while retriving the url , the backslashes are
missing , for some backslashes its generating junk values like box
|
by: praveen205011026 |
last post by:
hi, this is praveen, I want to get a field value of a from and move it to another page so that i can use it there, and by that value i want to retrive information from the data base can any help me.
|
by: prabhakarbtechit |
last post by:
Hi,
i am beginer in .net i have stored Free Text Box values i mean html content, while retriving that values i have to substring it, so after substring that values it comes with html tags in display i want to quit it, can any one help me
Regards,
G.prabhakaran
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |