Tje Posted July 16, 2014 Share Posted July 16, 2014 (edited) I'm trying to display relevant user details when click after user details button.it is css pop up window.i want to know how to catch relevant user when click the button.my primary key is email. $connect = mysql_connect("localhost","root",""); if(!$connect){echo("<script>alert('DBMS connection error');</script>>");} if(!mysql_select_db("biz", $connect)){echo("<script>alert('Unable to find DB');</script>>");} $result1 = mysql_query("SELECT radio,yname,mail,cpw,tp,city FROM reg WHERE mail='SSS@SSS.SS'"); $row1 = mysql_fetch_assoc($result1); mysql_close($connect); <form class="form-signin" role="form"> User Type :Business Name : <?php echo $row1['yname'] ?> Email Address :abc@gmail.com Password :xxxxxx Telephone no :0777777777 </form> this is what i did.Now it's display same name(kasun) for every users details. please help. Edited July 16, 2014 by Tje Quote Link to comment Share on other sites More sharing options...
fastsol Posted July 16, 2014 Share Posted July 16, 2014 That is not enough code for any of us to determine your problem and the code provided doesn't even have anything to do with the pop-up process or how it's being passed the info it needs to get the relevant info from the db. Quote Link to comment Share on other sites More sharing options...
Tje Posted July 17, 2014 Author Share Posted July 17, 2014 (edited) This is admin panel function(manage users).Every registered users names are display in this table.When click this show button it's open pop-up.i want to display all the user details in this pop-up. --this is my php table -- $connect = mysql_connect("localhost","root",""); if(!$connect){echo("<script>alert('DBMS connection error');</script>");} if(!mysql_select_db("biz", $connect)){echo("<script>alert('Unable to find DB');</script>>");} echo "test"; $result = mysql_query("SELECT yname FROM reg"); mysql_close($connect); while($row=mysql_fetch_array($result)) { echo '<tr class="odd gradeX"> <td>'.$row["yname"].'</td> <td><input type="image" src="images/view.png" width="40" height="40" name="view" id="view" class="center" data-toggle="modal" value="show" data-target="#signin1"/></td> </tr>'; } echo '</table>'; this is user details pop-up... $connect = mysql_connect("localhost","root",""); if(!$connect){echo("<script>alert('DBMS connection error');</script>>");} if(!mysql_select_db("biz", $connect)){echo("<script>alert('Unable to find DB');</script>>");} $result1 = mysql_query("SELECT radio,yname,mail,cpw,tp,city FROM reg WHERE mail='SSS@SSS.SS'"); $row1 = mysql_fetch_assoc($result1); mysql_close($connect); <form id="form1"> User Type :Business Name :<?php echo $row1['yname'] ?> Email Address :abc@gmail.com Password :xxxxxx </form> (only name come from DB.others are still hard code).please help Edited July 17, 2014 by Tje Quote Link to comment Share on other sites More sharing options...
fastsol Posted July 17, 2014 Share Posted July 17, 2014 That still doesn't show us much of anything. The model is triggered by javascript most likely, so we need to see that code and any ajax/php code that goes with it. If we can't see hwo this is functioning we can't really help you. All you have provided is the code that builds the image button. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.