Quantcast
Channel: Topic Tag: MySQL | WordPress.org
Viewing all articles
Browse latest Browse all 5540

cagsmith on "Removing broken shortcodes"

$
0
0

Ok, for what it's worth, I dumped the table into Notepad++ and used some regex to extract the link IDs. As a result I've been able to come up with a whole load of statements looking like this:

UPDATE 'wp_posts' SET 'post_content' = REPLACE ('post_content', '[amazon_link id="B0001IX3MS" target="_blank" ]', '';
UPDATE 'wp_posts' SET 'post_content' = REPLACE ('post_content', '[amazon_link id="B0001IX3R8" target="_blank" ]', '';
UPDATE 'wp_posts' SET 'post_content' = REPLACE ('post_content', '[amazon_link id="B0001IX454" target="_blank" ]', '';

But I'm getting a syntax error in PhpMyAdmin when attempting to run these... anyone have any idea?


Viewing all articles
Browse latest Browse all 5540

Trending Articles