Replacing an URL inside the post content
-
Hello,
I am using a plugin that automatically insert content to my posts, the IMDB Automator plugin. Inside the plugin’s main.php file, I have 2 URLs that I want to change; both URLs have this structure:
1.
http://ads.mynetwork.com/offer?prod=1&ref=1234&q=’.(get_option(‘imdb_title’)?$title:”).’ – Full Movie2.
http://ads.mynetwork.com/offer?prod=2&ref=5678&q=’.(get_option(‘imdb_title’)?$title:”).’ – Full MovieI want to change these URLs to be like these:
http://ads.mynetwork.com/offer?prod=1&ref=1234
http://ads.mynetwork.com/offer?prod=2&ref=5678The entire paragraphs containing the URLs are these:
1.
$content .= ‘
<img src=”http://www.mysite.com/wp-content/uploads/2014/10/watch-button.png”></td></tr>’;2.
if ($video[‘storyline’] && get_option(‘imdb_storyline’)) $content .= ‘<tr><td colspan=”2″><h2>‘.(get_option(‘imdb_title’)?$title:”).’ Online – Download & Watch Full Movie:</h2>
<img src=”http://www.mysite.com/wp-content/uploads/2014/11/movie-player1.jpg” width=”900″ height=”600″ /><h2>Full Movie ‘.(get_option(‘imdb_title’)?$title:”).’ Online:</h2>
‘.$video[‘storyline’].'</td></tr>’;I tried to search for the URLs, or for a part of the URLs, but I am always getting the no results message. How can I search and replace these URLs? Please tell me exactly what to type to the search field, and what to type to the replace field!
Thank you for your help!
Best Regards,
Oli
The topic ‘Replacing an URL inside the post content’ is closed to new replies.