Site logo

Archived topic

multi domain into single instance of wordpress installation

1 reply · Started by Joyce on October 30, 2020

Viewing posts 1–2 of 2

Hi Team,

I have multi domains point into single instance of wordpress server. I just find out my 2nd domain js/css/images links are the 1st domain link. How can I change these links from absolute path into relative path? I am NOT looking for multisite or network, thanks.

dns-prefetch
<link rel='dns-prefetch' href='//1st-domain-name.com' />

js

http://1st-domain-name.com/wp-content/plugins/gp-premium/menu-plus/functions/js/sticky.min.js?ver=1.12.2' id='generate-sticky-js'
http://1st-domain-name.com/wp-content/themes/generatepress/assets/js/main.min.js?ver=3.0.2' id='generate-main-js'
http://1st-domain-name.com/wp-content/themes/generatepress/assets/js/back-to-top.min.js?ver=3.0.2' id='generate-back-to-top-js'
http://1st-domain-name.com/wp-includes/js/wp-embed.min.js?ver=5.5.2' id='wp-embed-js'
http://1st-domain-name.com/wp-content/plugins/search-filter/style.css?ver=1
http://1st-domain-name.com/wp-content/themes/generatepress/assets/css/main.min.css?ver=3.0.2
http://1st-domain-name.com/wp-content/themes/generatepress_child_new/style.css?ver=1602907978
http://1st-domain-name.com/wp-includes/js/jquery/jquery.js?ver=1.12.4-wp' id='jquery-core-js

images

<meta name="viewport" content="width=device-width, initial-scale=1"><style>.recentcomments a{display:inline !important;padding:0 !important;margin:0 !important;}</style><link rel="icon" href="http://1st-domain-name.com/wp-content/uploads/2020/09/cropped-icon-1-32x32.jpg" sizes="32x32" />
<link rel="icon" href="http://1st-domain-name.com/wp-content/uploads/2020/09/cropped-icon-1-192x192.jpg" sizes="192x192" />
<link rel="apple-touch-icon" href="http://1st-domain-name.com/wp-content/uploads/2020/09/cropped-icon-1-180x180.jpg" />
<meta name="msapplication-TileImage" content="http://1st-domain-name.com/wp-content/uploads/2020/09/cropped-icon-1-270x270.jpg" />
<img  class="header-image is-logo-image" alt="" src="http://1st-domain-name.com/wp-content/uploads/2020/09/cropped-Home1-3.png" title="" width="1000" height="297" />

link
<a href="http://1st-domain-name.com/" title="" rel="home">

I checked https://generatepress.com/forums/topic/generateblocks-container-background-image-sets-absolute-urls/, but now sure how to do this (regenerate your CSS in Settings > GenerateBlocks)

I install https://wordpress.org/plugins/multiple-domain/ but it does not update all js/css link prefix, some are still pointing to the primary domain name, thanks.

I am using nginx web server, I know it may related to nginx conf setting.

server { 
 listen       80;
 server_name  1st-domain-name.com www.1st-domain-name.com 
 root    /xxx/xxx; 

 # Load configuration files for the default server block.
 include /etc/nginx/default.d/*.conf;

 location / {
    try_files $uri $uri/ /index.php?$args;
}

 error_page 404 /404.html;
  location = /40x.html {
 }

 error_page 500 502 503 504 /50x.html;
  location = /50x.html {
 }
}

Thanks,
Joyce

This archived topic is closed to new replies.