首页 > 解决方案 > Apache proxy pass URL to avoide # from Angular login page

问题描述

Our developers are working on Angular development and they implemented an application and its login URL as follows http://app./ag/#/can/auth/login. They wants to clean this url by removing # from this login URL.Is it possible to create Apache proxy pass to remove this # from this URL? I mean we need to access the above URL by http://app./ag/can/auth/login.

标签: angularapacheangular-ui-router

解决方案


You can simply remove this from the Angualr configuration :

RouterModule.forRoot(routes/*, { useHash: true }*/)

This will remove the hash from the URL.


推荐阅读