pulling info from database and removing html
Posted: Fri Dec 16, 2005 11:59 am
I have a news database with 3 columns... id, author, timestamp, and post - id & timestamp for obvious reasons, author so there is somebody to blame is something is falsely published, and post for the actual news post. Now... I currently have it set up so that it will accept html.
I am wondering if anybody knows how I can extract like 8 words from the beginning of the post column and turn into just "site map" to use as the heading of the news post.
EDIT: OK after reading that... even I was confused by it so here's what I want...
If this is in the news post column...
This is what I want it to turn into...
I am wondering if anybody knows how I can extract like 8 words from the beginning of the post column and turn
Code: Select all
<a href="#asdf">site map</a>EDIT: OK after reading that... even I was confused by it so here's what I want...
If this is in the news post column...
Code: Select all
Welcome to the new <a href="http://www.paradisedirect.com">Paradise Direct</a>! We are making huge changes in our web design and hosting department. To find out how these changes can benefit you, visit our services page!Welcome to the new Paradise Direct!
Welcome to the new Paradise Direct! We are making huge changes in our web design and hosting department. To find out how these changes can benefit you, visit our services page![/b]