javascript - how to make changes on the main page of the website based on the url TYPED by the user in the address bar -


i working on single page website asp.net server side technology want create experience 1 seen in this website. can see, when user scrolls page, url changes dynamically , navbar shows user in page.by clicking each navbar item, page scrolls right section , url changes again based on content. site using javascript's history api (history.js in context) , totally familiar how these apis work in javascript

my main problem this: when user types in url in address bar, want main page act if user clicked link in page , scroll specific part. example when user types www.mysite.com/products, want main page shown user , page automatically scroll products section of page

is there kind of routing trick have implement on server side? cause typing urls 1 showed above, 404 not found response (which logically correct since there main page in website's root folder , no products folder example)

how can achieve goal? in advance answers


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -