• Hi,

    I have developed a site locally using WAMPSERVER, the site runs perfectly and all my resource paths, i.e. css, js files etc are ok, for example:

    https://dev.domainname.co.uk/wp-content/plugins/contact-form-7/includes/css/styles.css?ver=3.4.2

    I then copy the site and database to the live server and although it all works ok for some reason some of the resource paths have incorporated the hosts physical path, i.e. the above is now:

    https://dev.domainname.co.uk/wp-content/plugins/websites/LinuxPackage05/97/wm/kz/97wmkz-33282.webfusion-hosting.co.uk/public_html/live/bpf_wp/wp-content/plugins/contact-form-7/includes/css/styles.css?ver=3.4.2

    I have searched and searched but cannot find a solution to resolve the issue.

    HELP

    Note: I modify my HOSTS file allowing me to develop using dev.domainname.co.uk so that I can point at local or live server as required.

Viewing 1 replies (of 1 total)
  • Thread Starter MarkHedley

    (@markhedley)

    As quite often happens when I am writing out the problem a potential answer springs to mind. In my wp-config I had the following

    define( 'WP_CONTENT_DIR', $_SERVER['DOCUMENT_ROOT'] . '/wp-content' );
    define( 'WP_PLUGIN_DIR', $_SERVER['DOCUMENT_ROOT'] . '/wp-content/plugins' );

    Apparently there are plugins that do not use these correctly and therefore end up with long resource paths. Commenting these out resolved the issue.

Viewing 1 replies (of 1 total)
  • The topic ‘Resource path change when copy site’ is closed to new replies.