Trying to pass the input value in the query string but failing why?
- by Ahmad Fouad
Hello,
I have this code in the page.
<input type="text" value="Enter your video URL here..." size="30" class="video_url" />
<input type="button" value="Preview" class="preview_button" />
<div id="preview"></div>
<script type="text/javascript">
(function($) {
$(".preview_button").click(function(){
var url = $('.video_url').val();
$("#preview").load('<?php bloginfo('template_directory'); ?>/templates/preview.php?url=' + url);
});
}) (jQuery);
</script>
However on preview.php I can never see the url value. What I am doing wrong?