Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Cutting the RTE generated content
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Forum LockedCutting the RTE generated content

 Post Reply Post Reply
Author
dozer View Drop Down
Newbie
Newbie


Joined: 06 May 2006
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote dozer Quote  Post ReplyReply Direct Link To This Post Topic: Cutting the RTE generated content
    Posted: 06 May 2006 at 2:34pm
Hello,

I would like to flood some content created using RTE Editor to other sections of my site.

For example - showing the first two lines of text from a blog or articles entry on the site's main page (with or without all the graphical features)...

How can this be accomplished? clearly this is not possible using regular string manipulation (or is it?)

Thanks in advance.
Back to Top
dozer View Drop Down
Newbie
Newbie


Joined: 06 May 2006
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote dozer Quote  Post ReplyReply Direct Link To This Post Posted: 13 May 2006 at 7:54pm
Borg, Please help...
I know how to manipulate strings, but all the additional HTML tags on the way are making me sweat Smile
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 15 May 2006 at 9:13am
Sorry I'm not even sure what you are trying to do, but it looks like you are requiring quite a substantial bit of customised programming.
Back to Top
dozer View Drop Down
Newbie
Newbie


Joined: 06 May 2006
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote dozer Quote  Post ReplyReply Direct Link To This Post Posted: 17 May 2006 at 8:46am
Hello again,
 
Lets say I've read from the user an article with 20 lines and stored it to my DB.
All I want is to extract the first few (2-3) lined from that article, remove all the design features (bold, font size ect.) and write those few lines to the screen.
 
for example:
 
Article Headline 1
 first line...  first line...  first line...  first line...
 second line...  second line...  second line...   second line...
                                                                [ click here for full article ]
 
Article Headline 2
 first line...  first line...  first line...  first line...
 second line...  second line...  second line...   second line...
                                                                [ click here for full article ]
 
Article Headline 3
 first line...  first line...  first line...  first line...
 second line...  second line...  second line...   second line...
                                                                [ click here for full article ]


Edited by dozer - 17 May 2006 at 8:48am
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 17 May 2006 at 9:36am
This is not actually part of the RTE, which is designed to be integrated into a pre-existing web from, not to build an ASP application from.

Have a look in the ASP -> Tutorial section of this web site as there are some tutorials on how to write to and display data from a database.
Back to Top
dozer View Drop Down
Newbie
Newbie


Joined: 06 May 2006
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote dozer Quote  Post ReplyReply Direct Link To This Post Posted: 17 May 2006 at 2:31pm
Man, my english sucks.
I'm having a hard time explaining myself.
 
I know how to extract data from DB.
All I want is to manipulate data generated by the RTE and "crop" the first line or two (and not the whole data)
 
maby splitting the source string by (chr(10)) and showing only the first line or two form the output array??
 
But how will I get rid of the text formatting?
 
Thanks again
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 17 May 2006 at 4:04pm
You could use the Mid and Trim functions built into ASP to remove unwanted text from an ASP string, but removing the HTML would be much harder, using regular expressions would probably be the simplest way.

Have a look of Google for the Regular Expression string for stripping HTML from a string.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.