我爱占星网 我爱占星网
首页
编程
java
php
前端
首页 编程 java php 前端

URL美化

I can't seem to figure out how to add an extra "/" to the end of my website's URL without affecting the URLs that are referenced in the file.

So, I want to change the URL from

http://url.com/home

to

http://url.com/home/

without affecting the URLs that are embedded in the files.

Do you have any idea on how to do this?

Thanks, Rob

You can use <base> tag in <head> section

<head>
    <base href="http://mydomain.com/" /> 
</head>

With this all relative links will be prefixed with given base.

近期文章

  • Apache没有执行PHP脚本[关闭]
  • 在php中执行.exe并填充输入
  • 如何获得与mp3的链接作为扩展名
  • 如何使用php日期函数显示本地服务器时间的不同时间?
  • 替换&nbsp; &安培; &复制; 和另一个ISO-8859-1 by regex在php中
  • Wordpress the_title(); 显示空白
  • 动态添加php生成的表单元素
  • 使用PHP转换JSON字符串中的“Java源代码字符”
  • simplexml_load_file 403禁止
  • 偶数/奇数确定CSS类
  • PHP MySQL数据库备份cron作业
  • PHP显示本地时间(静态)并考虑夏季/冬季
  • 如何优化MySQL游戏排行榜 - 大规模子查询问题
  • 列出来自多个用户的推文(PHP)
  • MySQL concat函数获取超链接[关闭]
  • 选择框中的更改会弹出确认框
  • 无法登录我的网站工作
  • 单击链接时转到上一个网页
  • 使用implode创建链接只会使一个数组项成为链接?
  • mysql语法错误(在select查询中)报告错误[关闭]

Copyright ©2022 我爱占星 All Rights Reserved.

浙ICP备2022030071号-1

部分图文来自网络,如有侵犯您的版权,请告诉我们删除

友情链接:代码精华