• Chito

    (@chitaranjanthoudam)


    Recently I regenerated the thumbnails using “Regenerate Thumbnail” plugin after modifying the plugin to delete old thumbnails. All went fine, now old thumbnails has been deleted and I can see the new ones.

    Now the problem I am seeing is there are post which has hard codes images, example as below image url http://nezone.info/wp-content/uploads/2013/11/OSA_Football01-580×385.jpg. Since old thumbnails has been deleted image is now not showing in the post. I can see those post using this sql query:

    SELECT *
    FROM wp_posts
    WHERE post_content LIKE ‘%-%x%.jpg%’

    I am wondering how we can update the above url as http://nezone.info/wp-content/uploads/2013/11/OSA_Football01.jpg

    I tried with below query which comes out as “0 rows affected”, so wondering any one of hack can provide me a solution.

    UPDATE wp_posts SET post_content= replace(post_content, ‘%-%x%.jpg%’, ‘%.jpg%’)
    WHERE post_content LIKE ‘%-%x%.jpg%’

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Update hard coded image url in post content’ is closed to new replies.