能否传到服务器端呢?因为我要转化成字符串进行处理。
比如:“http://expert.csdn.net/Expert”,对我有用的只是“expert.csdn.net”
比如:“http://expert.csdn.net/Expert”,对我有用的只是“expert.csdn.net”
解决方案 »
- ext中,控件用了clearListeners()如何再让它恢复?
- 急急急 .. smarty中使用 My97DatePicker
- javascript返回值传递问题
- 父窗口(框架)弹出子窗口(框架),子窗口如何刷新父窗口
- IE和FIRFOX的不同,document设置属性的问题~
- eval的问题
- showModalDialog 的刷新问题
- 谁能写这个小程序?很简单的
- 各位高手:为什么用window.location.reload()会提示刷新对话框呢?怎样不让它提示?
- 心情好,发分
- 我有一个关于另存的问题,要把htm另存为log,文件,请问怎么用javascript实现?
- 类似CSDN给分程序的问题
var strPath = location.href;
var strURL=window.location.pathname;
<body>
<input type="hidden" id="h" value="">
</body>
<script language="javascript">
h.value=location.href;
</script>
var strUrl = window.location.href;
strUrl = strUrl.split("http://")[1].split("/")[0]
alert(strUrl);
</script>