I have some DIV\'s in my HTML that I load dynamically using AJAX.
$(\"#workPanel\").load(\"ex.html\");
I also have some static links that onclic
I think this is what you're after:
To run masonry again you need to shuffle once the .load() completes, you can do this by running it as the callback function, like this:
$("#workPanel").load("ex.html", function() { $('#primary').masonry(); });