扫码关注官方订阅号
我想要得到/submit/post应该怎么样获得
光阴似箭催人老,日月如移越少年。
AngularJS提供了一个$location服务,用于解析地址栏。用$location.path();应该就直接拿到/submit/post部分了。
AngularJS
$location
$location.path();
/submit/post
参考: http://www.angularjs.cn/A00M
微信扫码关注PHP中文网服务号
QQ扫码加入技术交流群
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
PHP学习
技术支持
返回顶部
AngularJS提供了一个$location服务,用于解析地址栏。用$location.path();应该就直接拿到/submit/post部分了。参考: http://www.angularjs.cn/A00M