Request for additional functions/variables

Error message

Deprecated function: implode(): Passing glue string after array is deprecated. Swap the parameters in drupal_get_feeds() (line 394 of /var/www/pied-piper.ermarian.net/includes/common.inc).
AuthorTopic: Request for additional functions/variables
Apprentice
Member # 3517
Profile #0
I'd like to be able to define my own functions, but that seems to be impossible now, so in lieu of that, I'd like to ask if at least a few more useful functions could be exported.

My initial choices:
short max(short a,short b)
{if (a > b)return a;
else return b;}

short min(short a,short b){
if (a < b)return a;
else return b;}

short minmax(short min,short max,short k) {
if (k < min) return min;
if (k > max) return max;
return k;}
If these look familiar it's because they are just lifted from the editor source.

These would make scripting conditional loops a lot easier.

I'd also really like to have better user input, using storable string and integer variables with at least a local scope.

Regards,

mrb
Posts: 40 | Registered: Sunday, October 5 2003 07:00