Answer the question
In order to leave comments, you need to log in
jquery.smoothState.js - how to add class for body?
Hello!
There is a wonderful plugin [ https://github.com/miguel-perez/smoothState.js ] that kills two birds with one stone: ajax content loading plus css3 animation of this process. When using it, one unpleasant problem arose - it is impossible to add / update / load the class of body
the requested page.
Example: some content from page body.homepage
c is loaded into the #main block on page c body.single
The loading is successful, animations are displayed, only the body retains the same .homepage class , but .single is needed page, and after the download is complete, update the current one ... but I don’t know how to do it.
I would be extremely happy to help, because I myself will be looking for a solution for a long time, because. not strong in js/jquery.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question