Thanks for responding. Yes, all of my code is already wrapped in a document ready function as you suggested. For some reason, the content is still not always loaded when my script runs. Is there a way to ensure that the ACF plugin is loaded before my script?