smansakra
11-24-2008, 10:48 AM
please look at this
on php code, i can slipt a valiable and print it:
<?php
$text="john = 34";
list($name,$age) = split("=",$text);
echo $name."'s age is ".$age;
?>
can anyone help me to split same variable on javascript?
<script type="text/javascript">
var text = "john = 34";
//--- what should i write here?--//
//--- what should i write here?--//
//--- what should i write here?--//
</script>
thanks so much
on php code, i can slipt a valiable and print it:
<?php
$text="john = 34";
list($name,$age) = split("=",$text);
echo $name."'s age is ".$age;
?>
can anyone help me to split same variable on javascript?
<script type="text/javascript">
var text = "john = 34";
//--- what should i write here?--//
//--- what should i write here?--//
//--- what should i write here?--//
</script>
thanks so much