If the value in the loop is obtained, the solution is as follows:

Source: Internet
Author: User
If you get the value in the loop, the question is: how do you display the value in the loop in the DIV that needs to be popped up? For example, I have $ records [& quot; qq & quot;] in the $ records array. when a user clicks this tr, the $ records [& quot; the value of qq & quot;] is uploaded to the pop-up div. if JScriptcode is used to obtain the value in the loop
Q: How do I display and loop values in the DIV to be popped up?

For example, I have $ records ["qq"] in the $ records array. when a user clicks this tr, the value of $ records ["qq"] in this tr is automatically uploaded to the pop-up inside div
JScript code
  function popUserDetail(x){    var popUp = document.getElementById("popUserDetail");  var h = (x.rowIndex)*20;        popUp.style.top= 25 + h + "px";        popUp.style.left="142px";        popUp.style.width="200px";        popUp.style.height="100px";        popUp.style.visibility="visible";            }


PHP code
  While ($ records = mysql_fetch_array ($ rows) {$ arr = ct ($ records ['uniqueid']); $ fileLastUploadTime = $ arr [1]; print'                         '. St ($ records ['lastt'], $ fileLastUploadTime ).'                          '. $ Records ['barname'].'                          '. $ Records ['lastlogin'].'                          '. Date ("Y-m-d H: I: s", $ arr [1]).'                          '. $ Records ['endtm'].'                          '. $ Arr [0].'                          '. $ Records ['version'].'                          ';} Print'D
  
Customer ID:
Initial login:
Customer address:
Contact QQ:
'; Print' homepage | previous page | next page | last page
'. $ Total.' records the current '. $ pageId.' page in total '. $ pageCount.' page ';




------ Solution --------------------
Print'
Set an id
Print '...Contact QQ:';

Then, in the Js function
Function popUserDetail (x, qq ){
Var popUp = document. getElementById ("popUserDetail ");
Var h = (x. rowIndex) * 20;
PopUp. getElementById ('QQ'). innerText = qq;
PopUp. style. top = 25 + h + "px ";
PopUp. style. left = "142px ";
PopUp. style. width = "200px ";
PopUp. style. height = "100px ";
PopUp. style. visibility = "visible ";
}

What does that mean? I misinterpret your thoughts.
------ Solution --------------------

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.