Recently I just moved my website to new server. it was working fine with the old server. but now after i changed to new server the wordpress layout is collapsed. when i saw the console i have seen this error(refer the image). it also adding x to the script it make the error coming. please help me with this.enter image description here

enter image description here

  • It looks like your code is messed up, with the <script>-tag inside the JavaScript function. Are you sure the files are copied as-is? – Pim Sep 21 '18 at 13:16
  • yes all the files are there, but i can't able to figure out what is the issue – Manikandan Vijayakumar Sep 22 '18 at 5:01

Try & paste this below code your active theme functions.php file

add_action( 'wp_enqueue_scripts', 'load_jquery_fix', 100 );
function load_jquery_fix() {
    if ( ! is_admin() ) {
        wp_deregister_script( 'jquery' );
        wp_register_script( 'jquery', ( "//ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js" ), false, '1.11.3' );
        wp_enqueue_script( 'jquery' );
  • 1
    Please edit your answer, and add an explanation: why could that solve the problem? – fuxia Sep 21 '18 at 12:58
  • I have copy pasted above code, but still i have the errors – Manikandan Vijayakumar Sep 22 '18 at 5:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.