i have products. getting feedback user against each product. when user clicks on "reply" button feedback, dialog box appears.
now, problem that, each time "reply" button opens dialog against same id. make sure, printing id in dialog box returns same id each time... want let dialog open different id.
how can ?
in way getting id of product:
$get_product = "select * product_reviwes product_code = '$pro_code' order user_reply_date desc";
the code this:
$a = strtolower($product_owner); $b = strtolower($email); if($a == $b){ echo "<br> <small><div align='center'><a href='#login-box' class='login-window'>reply</a></div></small> <hr> <div id='login-box' class='login-popup'> <a href='#' class='close'><img src='images/close_pop.png' class='btn_close' title='close window' alt='close' /></a> <form method='post' class='signin' action='$url&id1=$id'> <fieldset class='textbox'> <label class='username'> <span>please enter reply</span> <input id='reply' name='reply' value='' type='text' autocomplete='on' placeholder='please enter reply maximum 1000 letters' maxlength='1000'> </label> <br> id = $id;// testing see id <br> <button class='submit button1' type='submit' name='post'>reply</button> </fieldset> </form> </div>"; }
if change
href='#login-box' with
href='$url&id1=$id'
then picks desired id dialog-box not open
try method
<div id='login-box-<?=$id;?>' class='login-popup'>
and while clicking reply button show respective login-box div based on id
<button class='submit button1' type='button' onclick='$("#login-box-<?=$id;?>").show()' name='post'>reply</button>
Comments
Post a Comment