Suggestions:
1) Use javascript to determine the script to run--slow and prone to
attacks because you have little control over
2) Code different functions depending on the size of the text
3) Include a different file with the code to execute depending on the
size of the text
Cheers,
Marco
Sounds like a good time for a switch to me...
---John Holmes...
-Original Message-
From: Peter Houchin [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 16, 2002 8:19 PM
To: php_gen
Subject: [PHP] to use switch or not to use switch
howdy
am just courious to see what
the answer can be as simple as:
?
$k = sizeof($field);
if(...)
$file = 'this';
elseif(...)
$file = 'that';
// etc ...
include($file);
?
--
Maxim Maletsky
[EMAIL PROTECTED]
On Wed, 16 Oct 2002
sorry, strlen(), not sizeof().
--
Maxim Maletsky
[EMAIL PROTECTED]
On Thu, 17 Oct 2002 03:03:13 +0200 Maxim Maletsky [EMAIL PROTECTED] wrote:
the answer can be as simple as:
?
$k = sizeof($field);
if(...)
$file = 'this';
elseif(...)
4 matches
Mail list logo