PHP קוד:
echo <<<html
</table>
<script type="text/javacript">
function results(id)
{
window.open("http://www.theyovel.net/polls/results.php?id"+id,"window","width='320',height='620'");
}
</script>
<input type="submit" name="submit" value="הצבע" /> [<a href="javascript:results({$r['id']});">תוצאות</a>]
</form>
html;
זה מתוך קוד PHP, כאשר {$r['id']} הוא ה-id של הסקר...
למי שרוצה את פלט ה-HTML:
PHP קוד:
<script type="text/javacript">
function results(id)
{
window.open("http://www.theyovel.net/polls/results.php?id"+id,"window","width='320',height='620'");
}
</script>
<input type="submit" name="submit" value="הצבע" /> [<a href="javascript:results(3);">תוצאות</a>]
</form>
מה הבעיה?, תודה לעוזרים מראש.