Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
Basically I'm working with a CMS that has the entire html input in a single variable, and I need to remove this bunch of html depending on a variable:
[syntax="html"] <img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
Main page for the members area.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
View your personal homepage.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
You can design / edit your personal webpage and edit your site account settings.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
View all your messages that have been sent to you.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
Submit all of your items in this area including pictures to blogs and much more.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
Edit all of your items you have added on the site.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
View all of the info on your friends that are in your network.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
View all of the favorites that you have added to your list.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
View all of the bulletins posted by your friends.
<img src="http://www.bmxpo.com/151/file/style/konsort/a1.gif" alt="" style="vertical-align:middle;" />
Invite your friends to come and join us.Code: Select all
$patterns[] = '/<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
Main page for the members area.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
View your personal homepage.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
You can design \/ edit your personal webpage and edit your site account settings.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
View all your messages that have been sent to you.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
Submit all of your items in this area including pictures to blogs and much more.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
Edit all of your items you have added on the site.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
View all of the info on your friends that are in your network.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
View all of the favorites that you have added to your list.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
View all of the bulletins posted by your friends.
<img src="(.*?)a1.gif" alt="" style="vertical-align:middle;" \/>
Invite your friends to come and join us./';
$replacements[] = '';
$sHtml = preg_replace($patterns, $replacements, $sHtml);Any ideas?
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]