Re: Replace context problem ...
This WebDNA talk-list message is from 1997
It keeps the original formatting.
numero = 12530
interpreted = N
texte = At 7:11 PM -1000 7/17/97, Kenneth Grome altered the fabric of cyberspace,writing:> As the administrator of my web site I would like to be able to update ANY> record in ANY database. This seems like a reasonable request, right?>Here! Here!> Okay, so in order to do that, first I have to type my own username/password> into the browser's authentication box in order to access the [protected]> page for my admin replace template. So far, so good. I enter MY admin> username and password into the browser's authenticate box and I can then> access the replace form.>Thats right. If you use a protected page you will have to type a usr/passcombo. Ant this is where your problem begins. WebCat now has only youruser/pass and not the record owners in the db.Solution??You have to now do a $Search for the record that you want to replace againon this page. Then include a link that will have a form to replace thevalues that you want to change. The URL to the link needs to contain&user=[username]&pass=[password]. This should collect the user/pass combofrom the searched record. On the Edit.tmpl file you can do your editingand then send that off to a validator.tmpl to replace the values youchanged.Remember if you try to use [protect] on the .tmpl pages down the path, youwill again be forced into the same loop as before.The solution that I used had a differant approach, since this kind ofaction always takes place here. I used [ShowIf [IPAddress]^.net-hwy.com]to hide the link. Yes, I know that [IPAddress] should return a number, BUTif you have 'use DNS' checked in WebStar, it will return the 'host name' ofa DNS named box. Since I control the DNS, I name the box. That waysomeone can't spoof an IP number. Even if I am away from home, I canchange the IP address on the box that I'm using to one that I have a DNSrecord to and get the same effect.>> I was asking Grant if it would make sense to make WebCat2 use the> username/password values I'm trying to get it to use - before trying to use> the browser's username/password values. I don't know how the WebCat2 code> is written, though, so I don't know if this even possible.I feel that it would be ever so much more practical to have WebCat alsolook at the user.db for Admin user/pass combo that would be acceptable toover ride the standard username password security in the .db.Hope that I have brought some light to this...Just another 'Local Boy' displaced to the 'Mainland' by circumstance.Aloha<--Glenn-->~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~Glenn & Renee DavisExclusively Web / Net Highway (916) 887-0678Web Page Design / Hosting ServicesPOB 157, Cool,CA 95614-0157http://www.ExclusivelyWeb.comhttp://www.Net-Hwy.com &&& ||| (@ @) (@ @)----------------------------ooO---U---Ooo---------------ooO--(_)--Ooo------->> Mailto:renee@Net-Hwy.com Mailto:glenn@Net-Hwy.com Mailto:renee@ExclusivelyWeb.com Mailto:glenn@ExclusivelyWeb.com Graphics Design Webmaster
Associated Messages, from the most recent to the oldest:
At 7:11 PM -1000 7/17/97, Kenneth Grome altered the fabric of cyberspace,writing:> As the administrator of my web site I would like to be able to update ANY> record in ANY database. This seems like a reasonable request, right?>Here! Here!> Okay, so in order to do that, first I have to type my own username/password> into the browser's authentication box in order to access the [protected]> page for my admin replace template. So far, so good. I enter MY admin> username and password into the browser's authenticate box and I can then> access the replace form.>Thats right. If you use a protected page you will have to type a usr/passcombo. Ant this is where your problem begins. WebCat now has only youruser/pass and not the record owners in the db.Solution??You have to now do a $Search for the record that you want to replace againon this page. Then include a link that will have a form to replace thevalues that you want to change. The URL to the link needs to contain&user=
[username]&pass=
[password]. This should collect the user/pass combofrom the searched record. On the Edit.tmpl file you can do your editingand then send that off to a validator.tmpl to replace the values youchanged.Remember if you try to use
[protect] on the .tmpl pages down the path, youwill again be forced into the same loop as before.The solution that I used had a differant approach, since this kind ofaction always takes place here. I used [ShowIf
[ipaddress]^.net-hwy.com]to hide the link. Yes, I know that
[ipaddress] should return a number, BUTif you have 'use DNS' checked in WebStar, it will return the 'host name' ofa DNS named box. Since I control the DNS, I name the box. That waysomeone can't spoof an IP number. Even if I am away from home, I canchange the IP address on the box that I'm using to one that I have a DNSrecord to and get the same effect.>> I was asking Grant if it would make sense to make WebCat2 use the> username/password values I'm trying to get it to use - before trying to use> the browser's username/password values. I don't know how the WebCat2 code> is written, though, so I don't know if this even possible.I feel that it would be ever so much more practical to have WebCat alsolook at the user.db for Admin user/pass combo that would be acceptable toover ride the standard username password security in the .db.Hope that I have brought some light to this...Just another 'Local Boy' displaced to the 'Mainland' by circumstance.Aloha<--Glenn-->~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~Glenn & Renee DavisExclusively Web / Net Highway (916) 887-0678Web Page Design / Hosting ServicesPOB 157, Cool,CA 95614-0157http://www.ExclusivelyWeb.comhttp://www.Net-Hwy.com &&& ||| (@ @) (@ @)----------------------------ooO---U---Ooo---------------ooO--(_)--Ooo------->> Mailto:renee@Net-Hwy.com Mailto:glenn@Net-Hwy.com Mailto:renee@ExclusivelyWeb.com Mailto:glenn@ExclusivelyWeb.com Graphics Design Webmaster
Glenn Davis
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:
WebCat2: Master Counter snippet (1997)
Summary search -- speed (1997)
New Mac Public Beta Available (1997)
WebCatalog can't find database (1997)
Boolean showifs? (2000)
Ready,Set; Print! (1999)
WebCatalog Hosting (1996)
Log entry (1999)
[WriteFile] problems (1997)
Server crash (1997)
Almost a there but..bye bye NetCloak (1997)
Bad "from" address in sendmail (2004)
Protect vs Authenicate (1997)
multi-paragraph fields (1997)
problems with 2 tags shakur (1997)
problem serving foreign languages text (1997)
How do I get data out of an Orderfile... (2001)
Passing [quantity] (2000)
Price Change (1999)
More on the email templates (1997)