Possible Duplicate:
javascript array converted to a php array?
I have an array in javascript, Now i need to assign javascript array to php array
i am beginner to scripting language,
Can anyone please help me
Thanks in advance.
<script type = text/javascript >
var jsArray = [];
var jsDescArray = [];
for (var i = 0; i <= <?php echo $t_num ?>; i++) {
jsArray.push( "<?php echo $url ?>="+thread[i].id );
jsDescArray.push( thread[i].title );
}
<?php
$str=json_decode('jsArray');
$str1[] = json_decode( 'jsDescArray', true );
?>
</script>