WordPress.org

Support

Support » How-To and Troubleshooting » Change permalink hyphen to an underscore???

Change permalink hyphen to an underscore???

  • I have an old blog site that is running movable type and I have upgraded to wordpress. the upgrade has gone really smooth and now I am in the process of matching old urls in the new system.

    However, all the permalinks have underscores instead of the dashes. Is there a global was to change all those quickly and easily?

    Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • piratazzurro
    Member

    @piratazzurro

    I’m interested in the same problem 🙂

    Boris
    Member

    @travel-junkie

    you should probably use .htaccess for it. just read somewhere that search engines don’t like underscores that much. sorry i can’t be of more help, but if you search for .htaccess you should get loads if information…

    all the permalinks have underscores instead of the dashes. Is there a global was to change all those quickly and easily?

    It can be easily done with one SQL query:

    UPDATE wp_posts
      SET
        guid =  REPLACE(guid, '_', '-'),
        post_name = REPLACE(post_name, '_', '-');
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Change permalink hyphen to an underscore???’ is closed to new replies.