Re: Extract my page name
This WebDNA talk-list message is from 2006
It keeps the original formatting.
numero = 66728
interpreted = N
texte = HiOnly problem with this is the domain name can change.CheersOn 4 Apr 2006, at 16:09, Gary Krockover wrote:> I'm guessing a grep to remove any instance of /www.mydomain.com/ > (doing nothing if that is not present) before moving on to the > [middle]:>> [text show=f]PREPAGENAME=[grep search=whatever pattern to remove / > www.anycharacters.com/][myURL][/grep]>> [text]PAGENAME=[Middle StartAfter=/&EndBefore=.][PREPAGENAME][/ > middle][/text]>> Sorry, my grep-fu is weak so I can't help you there. There may be > a way to use only grep as well - I'm sure that there is, so this > has been a pretty unhelpful suggestion but I'm ready for anything > besides the "SQL or not to SQL" posts. :)>> G.>> At 09:53 AM 4/4/2006, you wrote:>> Hi>>>> Sorry I'm sure this is simple my brain has just stopped functioning>> at the moment.>>>> I have a database with various urls in it that could be stored as >> '/ mypage.html' or they could be '/www.mydomain.com/mypage.html'>>>> In either case I need a way to extract the mypage bit that will work>> with any variation of that and I can't figure out how to do it. Does>> anyone have any suggestions, I have always used...>>>> [text]PAGENAME=[Middle StartAfter=/&EndBefore=.][myURL][/middle][/ >> text]>>>> ...which used to work fine until the domains part was also>> introduced. Unfortunately I have little or no control over the>> entered url so I need to figure out a way.>>>> Any help much appreciated.>>> -------------------------------------------------------------> This message is sent to you because you are subscribed to> the mailing list
.> To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to digest@talk.smithmicro.com>> Web Archive of this list is at: http://webdna.smithmicro.com/========================================Steve Craig - Asylum Interactive LtdTel +44 1330 860550 Fax +44 1330 860880========================================http://www.asylumweb.comEmail: steve@asylumweb.comSkype: s.craig - iChat: steve.craig========================================-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Associated Messages, from the most recent to the oldest:
HiOnly problem with this is the domain name can change.CheersOn 4 Apr 2006, at 16:09, Gary Krockover wrote:> I'm guessing a grep to remove any instance of /www.mydomain.com/ > (doing nothing if that is not present) before moving on to the > [middle]:>> [text show=f]PREPAGENAME=[grep search=whatever pattern to remove / > www.anycharacters.com/][myURL][/grep]>> [text]PAGENAME=[Middle StartAfter=/&EndBefore=.][PREPAGENAME][/ > middle][/text]>> Sorry, my grep-fu is weak so I can't help you there. There may be > a way to use only grep as well - I'm sure that there is, so this > has been a pretty unhelpful suggestion but I'm ready for anything > besides the "SQL or not to SQL" posts. :)>> G.>> At 09:53 AM 4/4/2006, you wrote:>> Hi>>>> Sorry I'm sure this is simple my brain has just stopped functioning>> at the moment.>>>> I have a database with various urls in it that could be stored as >> '/ mypage.html' or they could be '/www.mydomain.com/mypage.html'>>>> In either case I need a way to extract the mypage bit that will work>> with any variation of that and I can't figure out how to do it. Does>> anyone have any suggestions, I have always used...>>>> [text]PAGENAME=[Middle StartAfter=/&EndBefore=.][myURL][/middle][/ >> text]>>>> ...which used to work fine until the domains part was also>> introduced. Unfortunately I have little or no control over the>> entered url so I need to figure out a way.>>>> Any help much appreciated.>>> -------------------------------------------------------------> This message is sent to you because you are subscribed to> the mailing list .> To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to digest@talk.smithmicro.com>> Web Archive of this list is at: http://webdna.smithmicro.com/========================================Steve Craig - Asylum Interactive LtdTel +44 1330 860550 Fax +44 1330 860880========================================http://www.asylumweb.comEmail: steve@asylumweb.comSkype: s.craig - iChat: steve.craig========================================-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Steve Craig
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
RE: E-mailer error codes (1997)
E-mail loop ! (1997)
E-mail/Invoice (1998)
Yet another db manager (2004)
Date search - yes or no (1997)
WebCat2 - Getting to the browser's username/password data (1997)
Searching two databases (2001)
japanese characters (1997)
Server Freeze (1998)
[index] (1997)
RE: Multiple Stores and WebCatalog Prefs (1997)
[addlineitems] (1997)
Running webcat 6 on Windows XP Prof. (2005)
WebCat2b14MacPlugIn - [include] doesn't hide the search string (1997)
Limiting user access to .tmpl files (1997)
when is date system date or order date? (1997)
normal users.db calls ... (1998)
listfiles-looking for slick solution (1997)
DNS Lookup 2 (2000)
Help! WebCat2 bug (Ben's input) (1997)