[英]need to use www.mydomain.com/filename/ instead of www.mydomain.com/file.php?id=1
www.mydomain.com/filename/ instead of www.mydomain.com/file.php?id=1 www.mydomain.com/filename/而不是www.mydomain.com/file.php?id=1
currently im developing a Auto index site script目前我正在开发一个自动索引站点脚本
From index.php i had put a hyper link to download page Download page and on file.php page i had put从 index.php 我放了一个超链接到下载页面 下载页面和文件。我放了 php 页面
$id=$_REQUEST['id'];
$query = "update mydatabase SET views = views+1 where id ='".$id."'";
$update = mysqli_query($con,$query) or die(mysql_error());
$query = "SELECT * from mydatabase where id='".$id."'";
$result = mysqli_query($con,$query) or die(mysql_error());
$row = mysqli_fetch_assoc($result);
<?php echo $row['id'];?>
<?php echo $row['name'];?>
<?php echo $row['size'];?>
etc.. ETC..
when i click on Download page it redirect me to www.mydomain.com/file.php?id=1 page and show the related file details.当我点击下载页面时,它会将我重定向到www.mydomain.com/file.php?id=1页面并显示相关文件详细信息。
But i really need to change the above url as www.mydomain.com/song/file-name但我真的需要将上述 url 更改为www.mydomain.com/song/file-name
please can anybody advise or help me on this??请问有人可以建议或帮助我吗?
Maybe you can try this on your download page.也许你可以在你的下载页面上试试这个。
history.replaceState(null, null, '/song/file-name')
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.