Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How is data in a site change without ajax request or url changed?

Tags:

c#

asp.net

I was looking at the https://www.dotnetperls.com/ and when i click on 'C#' link in the page the page loads with different content and i dont see any ajax request in the Network tab in the browser and there no url change also.

How is this achieved?

like image 312
user2713706 Avatar asked Jan 03 '23 08:01

user2713706


1 Answers

That's because the content is already loaded into the page when you first visit the site. If you look at Event Listeners in Chrome for the link, you'll see javascript hooked in to change the rendered HTML element on click.

like image 76
DiskJunky Avatar answered Jan 13 '23 13:01

DiskJunky