Reputation: 308
We had build a website using angular js, html and php. When passing the values between the two pages using state params in angular js. The values are visible in url like below.
We don't need to show the real values in url while passing to different page. I don't how to get this. Please help me to acheive.
Upvotes: 0
Views: 92
Reputation: 4632
I don't think there is a way to "hide" the values on the url, what you can do is once the page "mounted", replace the url by a fake "display url".
by doing this (so the page doesn't get refreshed/redirect):
so if you redirect to:
/app/create_addpos/update/9486904359/1820
you can change this to:
window.history.pushState("", "", '/app/create_addpos/update/'); // or some other url
Do this on the /app/create_addpos/update/9486904359/1820
page.
Upvotes: 1