May 4, 2011

Removing HTML | CyberSEO Pro | Support Forum

Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_TopicIcon
Removing HTML
Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 (0 votes) 
February 22, 2013
9:58 pm
Avatar
Brett
Guest
Guests

How would I remove certain html tags and the content inside of it?

Example  <div class="feedflare">text, links, images, etc...</div>

How would I remove that from a feed is what I need to know.

Thanks,
Brett

February 23, 2013
6:55 am
Avatar
CyberSEO
Admin
Forum Posts: 3912
Member Since:
July 2, 2009
sp_UserOnlineSmall Online

Use Login to see this link. E.g.:

Login to see the code

February 23, 2013
6:44 pm
Avatar
Brett
Guest
Guests

I added this code and it removed ALL of the content from the posts. Not just the div.

$post['post_excerpt'] = preg_replace('/<div class="feedflare">.*?</div>/is', '', $post['post_excerpt']);
$post['post_content'] = preg_replace('/<div class="feedflare">.*?</div>/is', '', $post['post_content']);

February 24, 2013
8:01 am
Avatar
CyberSEO
Admin
Forum Posts: 3912
Member Since:
July 2, 2009
sp_UserOnlineSmall Online

It's to give you an universal solution without seeing the actual feed contents. If you want to order a custom code, please contact me by email.

Forum Timezone: Europe/Amsterdam

Most Users Ever Online: 541

Currently Online: CyberSEO
43 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

ninja321: 84

s.baryshev.aoasp: 68

Freedom: 61

Pandermos: 54

MediFormatica: 49

B8europe: 48

Member Stats:

Guest Posters: 337

Members: 2817

Moderators: 0

Admins: 1

Forum Stats:

Groups: 1

Forums: 5

Topics: 1627

Posts: 8278

Newest Members:

igor.buzaev, jeremyboucher, lthompson2709, MAC, duty3canada, backlinkmorocco

Administrators: CyberSEO: 3912