using .get()
using .get()
i am trying to get the contents of a php file into a div. however none of the php code is inserted, it will only insert html(stuff outside of the <?php markers).
- function preview()
{
var content = jQuery('#message').val();
jQuery.get('parser.php', {content:content}, function(txt){
jQuery('#preview').html(txt);
});
};
jQuery('#message').keyup(function (){
preview();
});
and my parser.php page(as a simple example)
- <?php
echo 'boo';
?>