Javascript PHP函数。使用其他函数中的函数
我对php函数有问题,或者我需要知道如何(或是否工作)使用:Javascript PHP函数。使用其他函数中的函数,javascript,php,jquery,mysql,post,Javascript,Php,Jquery,Mysql,Post,我对php函数有问题,或者我需要知道如何(或是否工作)使用: 我想在这里使用search echo$\u POST['search']的结果:(进入其他php函数) <?php $content = file_get_contents("http://youtube.com/get_video_info?video_id=".$HERE); parse_str($content, $ytarr); echo $ytarr['title']; ?> 这里是。$我想把searh
我想在这里使用search echo$\u POST['search']的结果:(进入其他php函数)
<?php
$content = file_get_contents("http://youtube.com/get_video_info?video_id=".$HERE);
parse_str($content, $ytarr);
echo $ytarr['title'];
?>
这里是。$我想把searh result函数放在这里。如果有人在WR29242JR(示例)中提交了一篇文章,其中包含第一个代码,在第二个代码中,我希望得到确切的第一个结果
我希望我足够清楚。我是业余爱好者,但我想学习。
谢谢!只要用
substr
返回的结果替换$HERE
:
$content = file_get_contents("http://youtube.com/get_video_info?video_id=" . substr($_POST["search"], -11))
$content=file\u get\u contents(“http://youtube.com/get_video_info?video_id=“.substr($\u POST[“search”],-11))
?很好。非常感谢。很简单。:D
$content = file_get_contents("http://youtube.com/get_video_info?video_id=" . substr($_POST["search"], -11))