Note that there are some explanatory texts on larger screens.

plurals
  1. POHow can I pass parameter
    primarykey
    data
    text
    <p>Just for examples</p> <pre><code>machineId = 150018; paper = raphel('canvas_container', 15, 20); rect = paper.rect().attr({.....}); rect.node.ondblclick = function() { window.open("graph.php?mach_id=" + id); } </code></pre> <p>Question: How can I pass machineId value to id;</p> <p>I need the result is to open new window with url <a href="http://localhost/graph.php?mach_id=150018" rel="nofollow">http://localhost/graph.php?mach_id=150018</a>;</p> <hr> <p><em>code from duplicate question</em></p> <pre><code>function showUtilization(machineId, rectUtil, txtResult, txtMCName, rectCover) { for (i = 0; i &lt; machineId.length; i++) { $.ajax({ url: 'ajax/getonemachineinfo.php', data: { id: machineId[i] }, dataType: 'text', async: false, success: function(data) { results = data.split(','); status = results[0]; utilize = results[1]; // Machine Name switch (status) { case '0': var colorCode = "#FF0000"; break; case '1': var colorCode = "#33CC33"; break; case '2': var colorCode = "#808080"; break; } txtMCName[i].attr({ fill: colorCode }); // utilization rectUtil[i].attr({ width: (utilize * conversionFactor())/100 }); if (utilize &lt;= 30) { var colorAttr = [{ fill: "#FF0000" }]; } else if ((utilize &gt; 30) &amp;&amp; (utilize &lt;= 60)) { var colorAttr = [{ fill: "#FFFF00" }]; } else if (utilize &gt; 60) { var colorAttr = [{ fill: "#33CC33" }]; } rectUtil[i].attr(colorAttr); txtResultAttr = [{ text: utilize + '%'}]; txtResult[i].attr(txtResultAttr); txtResult[i].attr(colorAttr); rectCover[i].node.ondblclick = function() { window.open("graph.php?mach_id=" + machineId[i]); } } }); } } (2 </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload