Re: Referrer field to header field conversion
This WebDNA talk-list message is from 1997
It keeps the original formatting.
numero = 15740
interpreted = N
texte = You are trying to change a field in the header of a cart. WebCatalog's'SmartCart' creates a unique cart before you even realize you need.To set the value of Header30 of a given cart, you need a [setHeader] context:[SetHeader db=your.db&cart=[cart]]header30=[referrer][/setheader] (see how[cart] works?)That string should be used where you have Header30=[url][referrer][url]By the way, [referrer] is already a URL, so doesn't need the [url] conversioncontext. That context replaces URL problem characters, like spaces, into theirURL-acceptable gibberish: %20. I think [convertChars] converts it back tonormal, but I will probably forever confuse these.Good Luck!Pat McCormickBrian B. Burton wrote:> Hello Again!>> A while ago I asked how to take the initial referrer of a visitor to my web> site and put this info in their shopping cart for later reference. I got> some excellent suggestions, but I still can't seem to make it work. The> problem is the visitor comes to an entry page, then clicks the big pretty> graphic to actually enter the site, in the process doing a search, and> generating a cart value. ( I now realise that this isn't required, as you> can do embedded searches (which I do), and generate cart numbers later, but> anyway...) I want to add the Header30=[referrer] tag, something like this...>
href=Search.tmpl$search?Header30=[url][referrer][/url]&cart=[cart]&db=mypro> d.txt&geSKU=0>> This doesn't work, because you apparently can't add info to a cart value> (after all it only exists as a number in a URL)> so then I tried...> > which creates a cart file, doesn't append the referrer into it, and will> cause a problem if anybody uses the back button after shopping for a while> to get back to the search screen!> so then I tried...> href=Search.tmpl$add?Header30=[url][referrer][/url]&cart=[cart]&db=myprod.t> xt&sku=0>> but this was doomed to fail as I have no SKU with a value of 0 and I really> have NO desire to add any line items to the shopping cart file at this time.> (not to mention stupid customer questions that I would invariable hear as a> result of this!)>> So again I am exactly where I started...nowhere.>> What I need is a $create? command to create a shopping cart file so I can> play with the headers without adding any line items. Or is there another> way I am overlooking?>> Brian B. Burton>> P.S. I installed webcatalog 2.01 updater last night, and ever since then my> shopping carts have only lasted 2 hours before being auto deleted. I thought> it was (is) supposed to be 24 Hours?
Associated Messages, from the most recent to the oldest:
You are trying to change a field in the header of a cart. WebCatalog's'SmartCart' creates a unique cart before you even realize you need.To set the value of Header30 of a given cart, you need a
[setheader] context:[SetHeader db=your.db&cart=
[cart]]header30=
[referrer][/setheader] (see how
[cart] works?)That string should be used where you have Header30=
[url][referrer][url]By the way,
[referrer] is already a URL, so doesn't need the
[url] conversioncontext. That context replaces URL problem characters, like spaces, into theirURL-acceptable gibberish: %20. I think
[convertchars] converts it back tonormal, but I will probably forever confuse these.Good Luck!Pat McCormickBrian B. Burton wrote:> Hello Again!>> A while ago I asked how to take the initial referrer of a visitor to my web> site and put this info in their shopping cart for later reference. I got> some excellent suggestions, but I still can't seem to make it work. The> problem is the visitor comes to an entry page, then clicks the big pretty> graphic to actually enter the site, in the process doing a search, and> generating a cart value. ( I now realise that this isn't required, as you> can do embedded searches (which I do), and generate cart numbers later, but> anyway...) I want to add the Header30=
[referrer] tag, something like this...>
href=Search.tmpl$search?Header30=[url][referrer][/url]&cart=
[cart]&db=mypro> d.txt&geSKU=0>> This doesn't work, because you apparently can't add info to a cart value> (after all it only exists as a number in a URL)> so then I tried...>
[url][referrer][/url]&cart=
[cart]>> which creates a cart file, doesn't append the referrer into it, and will> cause a problem if anybody uses the back button after shopping for a while> to get back to the search screen!> so then I tried...>
href=Search.tmpl$add?Header30=[url][referrer][/url]&cart=
[cart]&db=myprod.t> xt&sku=0>> but this was doomed to fail as I have no SKU with a value of 0 and I really> have NO desire to add any line items to the shopping cart file at this time.> (not to mention stupid customer questions that I would invariable hear as a> result of this!)>> So again I am exactly where I started...nowhere.>> What I need is a $create? command to create a shopping cart file so I can> play with the headers without adding any line items. Or is there another> way I am overlooking?>> Brian B. Burton>> P.S. I installed webcatalog 2.01 updater last night, and ever since then my> shopping carts have only lasted 2 hours before being auto deleted. I thought> it was (is) supposed to be 24 Hours?
Pat McCormick
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:
Math, Multiple Equasions and Show/Hide (1998)
searching for items that begin with a number (2004)
please anybody help (2005)
Looking for Experienced WebDNA Developer (2006)
Help! WebCat2 bug (1997)
Hiding the URL(was Cart ID Duplication) (2001)
Passing values (1999)
Cookie set browser session. (1998)
[WebDNA] Can webDNA be forced to be able to read ANY file in ANY folder in a webroot in =?UTF-8?Q?CentOS=3F?= (2018)
WebCat2 beta 11 - new prefs ... (1997)
[CART] inside a [LOOP] (1997)
Webcat no longer supported? (2006)
Bug or syntax error on my part? (1997)
Un[url]ize (1999)
Mac Vs WindowsNT (1997)
This list needs a digest: rant, rave... (1997)
WebDNA problem (2006)
still having shipCost.db Problem (1997)
WebCat2b13MacPlugin - [math][date][/math] problem (1997)
Using Applescript to process WebCatalog functions (1998)