|
||||
This is a quick hack for parsing url. You should be able to improve on this and come up with a function that does what you want... Share with us on your progress
![]() Thanks. PHP Code:
__________________
webmaster @ http://kongtechnology.com |
|
||||
Beware.... this board actually parsed some of my codes (the url) above... so, you need to modify a bit if you wanted to test it.
__________________
webmaster @ http://kongtechnology.com |
|
||||
I guess you will need to make my code into a function or something and let it run through your MESSAGE repeatedly to parse all occurences of urls (Currently, it only parse the first occurence).
Can you paste the Snitz forum function here to share with us?? Thanks.
__________________
webmaster @ http://kongtechnology.com |
|
||||
actually this snitzs function using javascript to..
vbscript: [php]function chkUrls(fString, fTestTag, fType) Dim strArray Dim Counter Dim strTempString strTempString = fString if Instr(1, fString, fTestTag) > 0 then strArray = Split(fString, fTestTag, -1) strTempString = strArray(0) for counter = 1 to UBound(strArray) if ((strArray(counter-1) = "" or len(strArray(counter-1)) < 5) and strArray(counter)<> "") then strTempString = strTempString & edit_hrefs("" & fTestTag & strArray(counter), fType) elseif ((UCase(right(strArray(counter-1),6)) <> "HREF=""") and (UCase(right(strArray(counter-1),5)) <> "[url]") and (UCase(right(strArray(counter-1),6)) <> "[url=""") and (UCase(right(strArray(counter-1),7)) <> "FILE:///") and (UCase(right(strArray(counter-1),7)) <> "HTTP://") and (UCase(right(strArray(counter-1),8)) <> "HTTPS://") and (UCase(right(strArray(counter-1),5)) <> "SRC=""") and (UCase(right(strArray(counter-1),5)) <> "SRC=""") and strArray(counter)<> "") then strTempString = strTempString & edit_hrefs("" & fTestTag & strArray(counter), fType) else strTempString = strTempString & fTestTag & strArray(counter) end if next end if chkUrls = strTempString end function[/php] javascript: PHP Code:
PHP Code:
|
|
||||
Ha... we should be able to convert that javascript into ASP or other server side code. I will try when I am free.
__________________
webmaster @ http://kongtechnology.com |
![]() |
«
Previous Thread
|
Next Thread
»
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| make link exchange function in wordpress | Rezats | Website Programming | 3 | 05-09-2005 01:03 AM |
| Parse error | therion | Website Programming | 25 | 20-05-2004 02:41 PM |
| print function | ardella | Website Programming | 2 | 13-05-2004 12:50 AM |
| stripslashes() function for JSP? | lcf | Website Programming | 3 | 21-04-2004 10:06 PM |
| How to make "Tell a friends" & "Newsletter" session function? | brutalasia | Website Design | 10 | 12-06-2003 09:16 AM |
All times are GMT +8. The time now is 10:56 AM.
Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0 vBulletin skin by ForumMonkeys.com.
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0 vBulletin skin by ForumMonkeys.com.











Linear Mode

