需要显示的位置已经在代码那指明,请各路高人指点一二。
url取值方法如下: http://xxx.com/test.php?v=/xxx/xxx.mp3
代码分割线
------------------------------------------------------------------------------------------
<?php
error_reporting(0);
header("Content-Type: text/html; charset=utf-8");
$v=$_GET["v"];
?>
<script type="text/javascript">
var url = '<?php echo $v ?>';
url = url.replace(/\//g,'%252F');
</script>
<iframe class="xxxxx" width="480" height="360" src="http://static.xxx.com/video?outlink_code=9f7144ed&path='这里需要显示js处理后的值,跟前面的部分组成完整的url'" scrolling="no" frameborder="0"></iframe>
代码分割线
------------------------------------------------------------------------------------------
期望的显示结果为
<iframe class="xxxxx" width="480" height="360" src="http://static.xxx.com/video?outlink_code=9f7144ed&path=%252Fxxx%252Fxxx.mp3" scrolling="no" frameborder="0"></iframe>
url取值方法如下: http://xxx.com/test.php?v=/xxx/xxx.mp3
代码分割线
------------------------------------------------------------------------------------------
<?php
error_reporting(0);
header("Content-Type: text/html; charset=utf-8");
$v=$_GET["v"];
?>
<script type="text/javascript">
var url = '<?php echo $v ?>';
url = url.replace(/\//g,'%252F');
</script>
<iframe class="xxxxx" width="480" height="360" src="http://static.xxx.com/video?outlink_code=9f7144ed&path='这里需要显示js处理后的值,跟前面的部分组成完整的url'" scrolling="no" frameborder="0"></iframe>
代码分割线
------------------------------------------------------------------------------------------
期望的显示结果为
<iframe class="xxxxx" width="480" height="360" src="http://static.xxx.com/video?outlink_code=9f7144ed&path=%252Fxxx%252Fxxx.mp3" scrolling="no" frameborder="0"></iframe>