【发布时间】:2017-12-13 04:25:18
【问题描述】:
例如,假设http://www.google.com/Stack/overflow
在上面的例子中,溢出是最后一个字符。我需要获取那个溢出字符
请帮助我实现这一目标
window.location.href
【问题讨论】:
-
window.location.href[window.location.href.length -1]:P -
最后一个字符,还是最后一个路径段?
-
@varun 这会将最后一个字母作为google.com/varun o/p 作为“n” rite i nee varun the whole word
-
@Shyam 那么你的问题是错误的伙伴!一个角色就是一个单位!
标签: javascript jquery html