Home > Backend Development > PHP Tutorial > mysql_fetch_arry()返回的变量是字符串,怎么用超链接显示到页面上?

mysql_fetch_arry()返回的变量是字符串,怎么用超链接显示到页面上?

WBOY
Release: 2016-06-13 12:25:28
Original
1100 people have browsed it

mysql_fetch_arry()返回的变量是字符串,如何用超链接显示到页面上??
mysql_fetch_arry()返回的变量是字符串,这个字符串是一个文件的路径,如何用超链接显示到页面上??用户可以直接点击这里超链接就可以打开这个文件。
------解决思路----------------------
是同一页面接收的数据么?
------解决思路----------------------
输出用html的a标签。
------解决思路----------------------

<br />$str = mysql_fetch_array($rs);<br />echo '<a herf="'. $str .'">超链接到文件</a>';<br />
Copy after login

------解决思路----------------------
加个标记。
然后需要加域名。
------解决思路----------------------
echo '
herf="'. $str .'">超链接到文件';

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template