If anybody has ever noticed that when you open a image in Facebook something like this happens:-
suppose you are on homepage on Facebook:- https://www.facebook.com/
now if you open a image it gets opened in new modal like window and URL changes to:- https://www.facebook.com/photo.php?fbid=10151125374887397&set=a.338008237396.161268.36922302396&type=1&theater
now as far as I know If they were using a modal overlay to display image then URL would have remained same, and if a new page has been loaded then there should not have a background showing previous page. What is this method of displaying images. Is there any jquery or java script plugin for this
Actually what Facebook does is make use of the HTML5 History API. You can read some more information here: http://diveintohtml5.info/history.html
So what they’re doing is loading up a modal when you view an image, and they change the URL in the address bar to a physical resource using the HTML5 History API. This allows them to change the URL without actually redirecting to another page. But if you copy and paste the url, it links directly to the resource (the view image page)