• Richard

    (@greenenergycafe)


    We are using WP on a hosted domain. On that hosted domain we have an add-on domain, and that is where the WP is used.
    It installed and is running fine.
    Our question is regarding the URL shown in a browser when the site is visited. When we open the homepage in a browser, we get a URL such as: https://yourdomain.com, as expected. When we follow any links we get instead a URL with the IP address, such as: https://[IPaddress]/~subdirectory/domain name/section/
    This works, but I’d prefer to have a more discreet and friendly URL.
    I contacted the hosting company, and they suggested going into the mySQL database table ‘wp_options’ and manually changing the ‘Site URL’ and ‘Home’ fields to what we wanted displayed in the browser URL display. That worked for solving that issue, but created other issues, such as as soon as we move off the homepage via a link on the homepage, we get a 500 error. Obviously, there’s more involved than those two fields.
    Anyone know how complex this is going to get to be able to solve the first problem yet not upset the rest of the apple cart???

Viewing 4 replies - 1 through 4 (of 4 total)
  • That’ll be because all the post GUIDs still point at the old URL..

    Run this in phpmyadmin on the WordPress database (using the SQL tab).

    SELECT guid FROM wp_posts

    I think you’ll find all the entries still point to the old URL..

    Quick fix would be to use a search and replace query (you can copy and paste the code below directly into the SQL tab of phpmyadmin – be sure to select the WordPress database first).

    PLEASE BACKUP BEFORE USING:

    UPDATE wp_posts SET guid = replace(guid,'https://OLDURLHERE/','https://NEWURLHERE/') WHERE guid LIKE 'https://OLDURLHERE%'

    Update OLDURLHERE and NEWURLHERE as appropriate..

    Again, please backup before using.

    Thread Starter Richard

    (@greenenergycafe)

    Thanks!

    Give me a day to work it through. By this time of the day, my head swims ‘this way’, while my common sense swims ‘that way’.

    Assuming i’ve read your problem correctly, that’s the only thing i could think of.

    Let me know if it helps, and please … don’t forget to backup your data first (just incase)..

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘URL simplification’ is closed to new replies.