Javascript-PHP - assing a concatenated string to a variable -
i want include variable between 2 strings , assign new variable. tried
var row="<tr><td>".$i."</td></tr>";
and
var row="<tr><td>"$i"</td></tr>";
and
var row="<tr><td>$i</td></tr>";
and
var row=$("<tr><td>$i</td></tr>");
and
var row=$("<tr><td>"$i"</td></tr>");
and
var row=$("<tr><td>".$i."</td></tr>");
but none of previous works. there way that?
you mixing js & php.
php:
$row = "<tr><td>" . $i . "</td></tr>";
or
$row = "<tr><td>$i</td></tr>";
javascript:
var row = "<tr><td>" + + "</td></tr>";
Comments
Post a Comment