Incorrect Theme and Upload URLs After Migration

Something went seriously wrong here. Is there a chance you can repeat the process on behalf of your client? Try to use Duplicator plugin it really helps with migrations. Or do a manual mysql dump on old hosting and import the database yourself. This definitely went wrong during the database migration.

dynamic image path within a javascript file

If you’re in JS you can’t use PHP (<?php ?>), you need to another way to get a PHP variable into JS. The normal way with WordPress is to use wp_localize_script(). wp_localize_script( ‘wpse_274344’, ‘myScriptObject’, array( ‘markerImageUrl’ => get_theme_file_uri( ‘/img/mapmarker.png’ ), ) ); Add that code after your call to wp_enqueue_script() or wp_register_script(). Replace wpse_274344 with … Read more