Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - [MOD-RTE] Create Summary ;)
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Forum Locked[MOD-RTE] Create Summary ;)

 Post Reply Post Reply
Author
superlative View Drop Down
Groupie
Groupie

Not Comparative, I m Superlative :)

Joined: 26 November 2004
Location: Turkey
Status: Offline
Points: 125
Post Options Post Options   Thanks (0) Thanks(0)   Quote superlative Quote  Post ReplyReply Direct Link To This Post Topic: [MOD-RTE] Create Summary ;)
    Posted: 21 March 2005 at 9:44am
Hi Everyone;
 
I ask How to create summary... in yesterday 5.53 PM. I worked about 23-24 hours for eliminate some html tags for summary. I resolve this problem and I want to share this with you. I wrote this code and resolve my summary problem. Please protect copyright lines. This is not only for RTE. You can use this any Text...
 
@Admins : You can do sticky topic or lock, and you can promote me Big smile mod builder group :) I wrote another mod for RTE : [MOD-RTE] Give home folder to users If this message view as dirty (appear scroolbar for code tag reason) I can edit and correct.
 

'****DO NOT REMOVE THESE LINES*****

'Eliminate some HTML tags Function...

'Written by Kaan DOGAN aka Superlative

'www.kaan.tk - www.knowhow.gen.tr

'*******************************
'Text is your html source value

Text = Trim(Mid(Text,1,500))

'You can add some html tags to bellow array for exclude some tags

TermX = Array("<img","<a href","<b","</a","</b","</p","<p")
pos1=1

skipchar=0
Do
pos1 = InStr(pos1, Text, "<")
If pos1<>0 then
     pos2 = InStr(pos1, Text, ">")+1

     If pos2=1 then pos2 = Len(Text)+1 

     temp_term=Mid(Text,pos1,pos2-pos1)

     skipchar = 0
 
    For i=0 to ubound(TermX)

         If Trim(Mid(temp_term,1,len(TermX(i)))) = TermX(i) then skipchar=1

     Next
 
 If skipchar=0 then

  Text = Replace(Text,Temp_Term,"")

  Else

  pos1=pos1+1

  End if
End if
Loop Until pos1=0
 
Thats All !! Tongue This is gift from me for RTE users..


Edited by superlative - 21 March 2005 at 2:02pm
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.