how to Modify a form using php sessions -



how to Modify a form using php sessions -

i m trying modify form using sessions. m trying application user login using username , password.after login home page displays particular user can add together details , modify details.i have problem when modifying details. details doesnt displayed edit details.the value entered add together form doesnt display in text box of modify. how can display details?

here code

if(isset($_post['update'])){ mysql_query("update cvformat set surname='".$_post['surname']."', mname='".$_post['mname']."',pid='".$_post['pid']."',dob='".$_post['dob']."',city='".$_post['city']."',region='".$_post['region']."', country='".$_post['country']."', diocese='".$_post['diocese']."',nationality='".$_post['nationality']."',fname='".$_post['fname']."',mothername='".$_post['mothername']."', edate='".$_post['edate']."',city2='".$_post['city2']."',region2='".$_post['region2']."',country2='".$_post['country2']."',datef='".$_post['datef']."', dateo='".$_post['dateo']."', city3='".$_post['city3']."',region3='".$_post['region3']."',country3='".$_post['country3']."',bishop='".$_post['bishop']."',tedate='".$_post['tedate']."',city4='".$_post['city4']."',region4='".$_post['region4']."', country4='".$_post['country4']."', tdirector='".$_post['tdirector']."',sof='".$_post['sof']."',decreefv='".$_post['decreefv']."',fvdate='".$_post['fvdate']."',city5='".$_post['city5']."',region5='".$_post['region5']."', country5='".$_post['country5']."', cres='".$_post['cres']."', q1='".$_post['q1']."',s1='".$_post['s1']."',y1='".$_post['y1']."',p1='".$_post['p1']."',q2='".$_post['q2']."',s2='".$_post['s2']."', y2='".$_post['y2']."', p2='".$_post['p2']."', q3='".$_post['q3']."',s3='".$_post['s3']."',y3='".$_post['y3']."', p3='".$_post['p3']."',ca='".$_post['ca']."',sp='".$_post['sp']."' name='".$_session['name']."'") or die(mysql_error()); }; $mydata= mysql_query("select * cvformat name='".$_session['name']."'")or die(mysql_error()); while($record = mysql_fetch_assoc($mydata)) { ?> <h4 align="right" style="margin-right:170px;">welcome <?=$_session['name'];?>!<a href="logout.php" style="text-decoration:none;">logout</a></h4> <div id="header" align="center"><img src="images/header.png" alt="" /></div> <form name="xiform" id="xiform" method="post" action="pdf/pdf1.php"> <table border="0px" cellspacing="0px" cellspacing="10px" align="center" width="700px"> <tr> <td style="width:200px;"><div class="label"><b >surname,name:</b></div></td> <td><input type="text" name="surname" id="surname" style="width:250px; padding:5px; value="<?php if(isset($_session['name'])) { echo $record['surname']; } ?>">

} how can display value in textbox using sessions? please help me out this

try :

while($record = mysql_fetch_assoc($mydata)) { ?> <h4 align="right" style="margin-right:170px;">welcome <?php echo $record['name'];?>!<a href="logout.php" style="text-decoration:none;">logout</a></h4> <div id="header" align="center"><img src="images/header.png" alt="" /></div> <form name="xiform" id="xiform" method="post" action="pdf/pdf1.php"> <table border="0px" cellspacing="0px" cellspacing="10px" align="center" width="700px"> <tr> <td style="width:200px;"><div class="label"><b >surname,name:</b></div></td> <td><input type="text" name="surname" id="surname" style="width:250px; padding:5px; value="<?php echo $record['surname']; ?>"> <?php } ?>

php session

Comments

Popular posts from this blog

javascript - THREE.js reposition vertices for RingGeometry -

javascript - I need to update the text of a paragraph by inline edit -

assembly - What is the addressing mode for ld, add, and rjmp instructions? -