Re: [WebDNA] WebDNA vs. php war ;-)
This WebDNA talk-list message is from 2010
It keeps the original formatting.
numero = 104826
interpreted = N
texte = I don't want to be the PHP defender as I've said before I agree WebDNA =is much simpler but...On 19 Feb 2010, at 20:37, Matthew Bohne wrote:> Or, the one that irks me the most...>=20> if (isnull($_GET['variable'])) {> $newname=3D$_POST['variable'];> } else {> $newname=3D$_GET[['variable'];> }>=20> versus>=20> [text show=3Df]varname=3D[variable][/text]Unfortunately your 5 year old snippet is showing its age. Since PHP =4.1.0 there has been a $_REQUEST array that carries the contents of =$_POST and $_GET (and $_COOKIE too)So the code these days to match your WebDNA would be...And...>=20> $value) {> echo $key . " - " . $value . "
";> }> foreach ($_POST as $key=3D>$value) {> echo $key . " - " . $value . "
";> } ?>>=20> versus>=20> [formvariables]> [name] - [value]
> [/formvariables]>=20becomes...$value){echo $key . " - " . $value . "
";}?>CheersPaul
Associated Messages, from the most recent to the oldest:
I don't want to be the PHP defender as I've said before I agree WebDNA =is much simpler but...On 19 Feb 2010, at 20:37, Matthew Bohne wrote:> Or, the one that irks me the most...>=20> if (isnull($_GET['variable'])) {> $newname=3D$_POST['variable'];> } else {> $newname=3D$_GET[['variable'];> }>=20> versus>=20> [text show=3Df]varname=3D[variable][/text]Unfortunately your 5 year old snippet is showing its age. Since PHP =4.1.0 there has been a $_REQUEST array that carries the contents of =$_POST and $_GET (and $_COOKIE too)So the code these days to match your WebDNA would be...And...>=20> $value) {> echo $key . " - " . $value . "
";> }> foreach ($_POST as $key=3D>$value) {> echo $key . " - " . $value . "
";> } ?>>=20> versus>=20>
[formvariables]> [name] - [value]
> [/formvariables]>=20becomes...$value){echo $key . " - " . $value . "
";}?>CheersPaul
Paul Willis
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:
Forumulas.db & Variables (2002)
WCS Newbie question (1997)
calculating tax rates, mail order solutions and version 2 (1997)
credit card authorization question (1997)
Pirated WebCat? NOT... (2003)
multi-paragraph fields (1997)
autosensing lanague selection (1997)
A *secret* new webdna tag !!! (1999)
Pass Thru Page? (1998)
RE: Credit card processing - UK (1997)
French characters in variables (2001)
Protect vs Authenicate (1997)
WebCatalog for guestbook ? (1997)
Shopping Cart Deletion (2000)
[format xs] freeze (1997)
Re:PCS Customer submissions ? (1997)
WebCat2 - storing unformatted date data? (1997)
Calculating multiple shipping... (1997)
Can webcat 3.0/4.0 handle 1,000,000 hits a day? (2000)
frames & carts (1997)