• Resolved Mike Price

    (@castroboy)


    Hey there

    Love this plugin and always recommend it. However, I am now hosting on a platform that uses nginx before Apache and it appears this is causing all image uploads on mapped domains to show the original network subdomain URL rather than the mapped domain.

    Is there a specific nginx rewrite rule that you know of, that I can easily add so that when I upload an image on a mapped domain, the image URL shows the mapped domain rather than the network subdomain?

    Example, currently all media uploads on a subsite named mydomain.com are showing a media URL of subsite.networkdomain.com Thanks for your help!

    https://www.ads-software.com/plugins/wordpress-mu-domain-mapping/

Viewing 6 replies - 1 through 6 (of 6 total)
  • I am having the same issue, but under Apache instead of Nginx. Any help with this would be very much appreciated.

    Thread Starter Mike Price

    (@castroboy)

    yeah it sucks there is no answer to this at all from the developer… ?? lol

    Plugin Author Ron Rennick

    (@wpmuguru)

    The image URLs are generated by WP.

    Regardless of what webserver software you are using rewrite rules change what is accessed by a URL but cannot be used to change URLs generated by WP.

    Image Uploads showing Network SubDomain URL

    If those links are in your post/page content DM dynamically replaces them with the mapped domain URL.

    Thread Starter Mike Price

    (@castroboy)

    Hey Ron,

    Thanks so much for replying. I do have a follow up question so that I can better understand the issue. Example is my network domain is mikepricetw.com. However, with Domain mapping, I have a mapped domain of footballpickoff.com

    However, if I upload an image from footballpickoff.com, the image URL once uploaded shows: https://football.mikepricetw.com/wp-content/uploads/sites/5/2014/09/austin4.jpg

    I am trying to figure out how to get it to show the mapped domain since the photo is indeed uploaded from the mapped domain. Does that make sense? Is there a fix for this or are you saying this is the only way WordPress can handle this situation? Thanks again for your help!!

    Plugin Author Ron Rennick

    (@wpmuguru)

    the image URL once uploaded shows: https://football.mikepricetw.com/wp-content/uploads/sites/5/2014/09/austin4.jpg

    Are you referring to the URL in the dashboard or in a post/page on the front end of the site? If the second scenario, what is your primary domain for that site?

    Thread Starter Mike Price

    (@castroboy)

    Ron,

    Thanks again for your response. I think I may have wasted your time as I now see from the frontend of the mapped domain that the uploaded image does indeed show the URL of the mapped domain correctly.

    However, it is in the backend Dashboard that the file URL shows the subdomain and not the mapped domain URL. This is not a problem! I could have sworn that when visiting the page source of the mapped domain, that the image had shown the wrong URL , but it doesn’t now that I checked again today.

    I do see though another plugin causing the non mapped domain to show but this isn’t your problem ?? Thanks again for taking a look at this and again sorry that I was mistaken. It appears the issue only exists on the backend which I don’t care about and im sure thats normal. Have a good rest of your Sunday!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Image Uploads showing Network SubDomain URL’ is closed to new replies.