[PHPLIB-DEV] cvs commit From: negro (phplib-dev <email protected>)
Date: 11/25/99

From: negro
Date: Thu Nov 25 15:59:47 1999
Modified files:
      php-lib/CHANGES
      php-lib/php/of_checkbox.inc
      php-lib/php/of_file.inc
      php-lib/php/of_radio.inc
      php-lib/php/of_select.inc
      php-lib/php/of_text.inc
      php-lib/php/of_textarea.inc

Log message:
- Removed AGAIN all trailing "\n" from form tags generated via
  OOH_FORMS.
- Removed some ^M in CHANGES file.

Index: php-lib/CHANGES
diff -u php-lib/CHANGES:1.149 php-lib/CHANGES:1.150
--- php-lib/CHANGES:1.149 Sat Nov 13 22:52:12 1999
+++ php-lib/CHANGES Thu Nov 25 15:59:14 1999
@@ -1,5 +1,10 @@
-$Id: CHANGES,v 1.149 1999/11/13 21:52:12 padraic Exp $
+$Id: CHANGES,v 1.150 1999/11/25 14:59:14 negro Exp $
 
+25-Nov-1999 negro
+ - Removed AGAIN all trailing "\n" from form tags generated via
+ OOH_FORMS.
+ - Removed some ^M in CHANGES file.
+
 13-Nov-1999 padraic
   - slight mods to the cache control directives to combine
     multiple field values into a single header() statement
@@ -29,27 +34,27 @@
     table structure to split your session record or use the database
     specific blob interface of your database (or work on a general
     blob API container, using a database specific blob container).
+
+ The ac_get_value() and ac_store() functions must work atomic
+ themselves. They must do their own locking. They cannot
+ rely on ac_get_lock() and ac_release_lock() being called -
+ these functions have a different purpose.
+
+ The ac_get_lock() and ac_release_lock() functions are here
+ to brace a page_open()/page_close() pair with locking. That
+ is useful for user variables or application variables.
+ Activating this functionality is done by setting
+ database_lock_semaphore in ct_*.inc. If enabled, page_open()
+ will lock a session (NOT! the entire session table, PLEASE!)
+ and that lock will persist until page_close() where it is
+ released. This will effectively serialize your pages and
+ SERIOUSLY slows down an application, but some applications
+ may use it. I'd rather have a "per session variable" lock, but
+ that is not possible from within PHP3, but only with severe
+ modifications of the interpreter.
 
- The ac_get_value() and ac_store() functions must work atomic
- themselves. They must do their own locking. They cannot
- rely on ac_get_lock() and ac_release_lock() being called -
- these functions have a different purpose.
-
- The ac_get_lock() and ac_release_lock() functions are here
- to brace a page_open()/page_close() pair with locking. That
- is useful for user variables or application variables.
- Activating this functionality is done by setting
- database_lock_semaphore in ct_*.inc. If enabled, page_open()
- will lock a session (NOT! the entire session table, PLEASE!)
- and that lock will persist until page_close() where it is
- released. This will effectively serialize your pages and
- SERIOUSLY slows down an application, but some applications
- may use it. I'd rather have a "per session variable" lock, but
- that is not possible from within PHP3, but only with severe
- modifications of the interpreter.
-
- Locking is still broken in most non-sql containers like shm,
- file, dba and dbm.
+ Locking is still broken in most non-sql containers like shm,
+ file, dba and dbm.
 
   - Modelled db_msql.inc after db_mysql.inc to bringt database API up
     to current revision. Have no msql running, so I cannot test it.
Index: php-lib/php/of_checkbox.inc
diff -u php-lib/php/of_checkbox.inc:1.4 php-lib/php/of_checkbox.inc:1.5
--- php-lib/php/of_checkbox.inc:1.4 Sat Sep 11 16:23:54 1999
+++ php-lib/php/of_checkbox.inc Thu Nov 25 15:59:15 1999
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 1998 by Jay Bloodworth
  *
- * $Id: of_checkbox.inc,v 1.4 1999/09/11 14:23:54 kk Exp $
+ * $Id: of_checkbox.inc,v 1.5 1999/11/25 14:59:15 negro Exp $
  */
 
 class of_checkbox extends of_element {
@@ -38,7 +38,7 @@
     }
     if ($this->extrahtml)
       $str .= " $this->extrahtml";
- $str .= ">\n";
+ $str .= ">";
     
     $count = 1;
     return $str;
@@ -55,7 +55,7 @@
         reset($this->value);
         while (list($k,$v) = each($this->value)) {
           if ($v==$val) {
- $x = 1;
+ $x = 1;
             $str .= "<input type='hidden' name='$this->name' value='$v'>\n";
             $t =" bgcolor=#333333";
             break;
@@ -67,7 +67,7 @@
         $x = 1;
         $t = " bgcolor=#333333";
         $str .= "<input type='hidden' name='$this->name'";
- $str .= " value='$this->value'>";
+ $str .= " value='$this->value'>\n";
       }
     }
     $str .= "<table$t border=1><tr><td>&nbsp</td></tr></table>\n";
Index: php-lib/php/of_file.inc
diff -u php-lib/php/of_file.inc:1.4 php-lib/php/of_file.inc:1.5
--- php-lib/php/of_file.inc:1.4 Thu Nov 18 00:47:41 1999
+++ php-lib/php/of_file.inc Thu Nov 25 15:59:15 1999
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 1998 by Jay Bloodworth
  *
- * $Id: of_file.inc,v 1.4 1999/11/17 23:47:41 uw Exp $
+ * $Id: of_file.inc,v 1.5 1999/11/25 14:59:15 negro Exp $
  */
 
 class of_file extends of_element {
@@ -22,7 +22,7 @@
     $str .= "<input type='file' name='$this->name'";
     if ($this->extrahtml)
       $str .= " $this->extrahtml";
- $str .= ">\n";
+ $str .= ">";
     
     $count = 2;
     return $str;
Index: php-lib/php/of_radio.inc
diff -u php-lib/php/of_radio.inc:1.5 php-lib/php/of_radio.inc:1.6
--- php-lib/php/of_radio.inc:1.5 Thu Nov 18 00:47:42 1999
+++ php-lib/php/of_radio.inc Thu Nov 25 15:59:15 1999
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 1998 by Jay Bloodworth
  *
- * $Id: of_radio.inc,v 1.5 1999/11/17 23:47:42 uw Exp $
+ * $Id: of_radio.inc,v 1.6 1999/11/25 14:59:15 negro Exp $
  */
 
 class of_radio extends of_element {
@@ -23,7 +23,7 @@
       $str .= " $this->extrahtml";
     if ($this->value==$val)
       $str .= " checked";
- $str .= ">\n";
+ $str .= ">";
 
     $count = 1;
     return $str;
@@ -36,9 +36,9 @@
     if ($this->value==$val) {
       $x = 1;
       $str .= "<input type='hidden' name='$this->name' value='$val'>\n";
- $str .= "<table border=1 bgcolor=#333333>";
+ $str .= "<table border=1 bgcolor=#333333>\n";
     } else {
- $str .= "<table border=1>";
+ $str .= "<table border=1>\n";
     }
     $str .= "<tr><td>&nbsp</tr></td></table>\n";
     
Index: php-lib/php/of_select.inc
diff -u php-lib/php/of_select.inc:1.5 php-lib/php/of_select.inc:1.6
--- php-lib/php/of_select.inc:1.5 Thu Nov 18 00:47:42 1999
+++ php-lib/php/of_select.inc Thu Nov 25 15:59:15 1999
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 1998 by Jay Bloodworth
  *
- * $Id: of_select.inc,v 1.5 1999/11/17 23:47:42 uw Exp $
+ * $Id: of_select.inc,v 1.6 1999/11/25 14:59:15 negro Exp $
  */
 
 class of_select extends of_element {
@@ -33,7 +33,7 @@
       $str .= " size='$this->size'";
     if ($this->extrahtml)
       $str .= " $this->extrahtml";
- $str .= ">\n";
+ $str .= ">";
 
     reset($this->options);
     while (list($k,$o) = each($this->options)) {
@@ -52,7 +52,7 @@
       }
       $str .= ">" . (is_array($o) ? $o["label"] : $o) . "\n";
     }
- $str .= "</select>\n";
+ $str .= "</select>";
     
     $count = 1;
     return $str;
Index: php-lib/php/of_text.inc
diff -u php-lib/php/of_text.inc:1.7 php-lib/php/of_text.inc:1.8
--- php-lib/php/of_text.inc:1.7 Thu Nov 18 00:47:42 1999
+++ php-lib/php/of_text.inc Thu Nov 25 15:59:16 1999
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 1998 by Jay Bloodworth
  *
- * $Id: of_text.inc,v 1.7 1999/11/17 23:47:42 uw Exp $
+ * $Id: of_text.inc,v 1.8 1999/11/25 14:59:16 negro Exp $
  */
 
 class of_text extends of_element {
@@ -40,7 +40,7 @@
       $str .= " size='$this->size'";
     if ($this->extrahtml)
       $str .= " $this->extrahtml";
- $str .= ">\n";
+ $str .= ">";
     
     $count = 1;
     return $str;
@@ -103,34 +103,34 @@
   }
   
   function self_validate_php($val) {
-
- $php_code = "";
- if (!is_array($val)) $val = array($val);
- reset($val);
- while (list($k, $v)=each($val)) {
-
- if ($this->length_e) {
- $condition = "";
- if ($this->minlength) $condition.=sprintf("(strlen($%s)<%s) || ", $this->name, (int)$this->minlength);
- if ($this->maxlength) $condition.=sprintf("(strlen($%s)>%s) || ", $this->name, (int)$this->maxlength);
- if (""!=$condition) {
- $condition.="false";
- $php_code.= $this->generate_php($condition, $this->name, $this->title, $this->length_e);
- }
- }
-
- if ($this->valid_e) {
- $condition = "";
- if ($this->icase)
- $condition.= sprintf("(!eregi(\"%s\", \"$%s\"))", $this->valid_regex, $this->name);
- else
- $condition.= sprintf("(!ereg(\"%s\", \"$%s\"))", $this->valid_regex, $this->name);
- if (""!=$condition)
- $php_code.=$this->generate_php($condition, $this->name, $this->title, $this->valid_e);
- }
- }
- return $php_code;
- } // end func self_validate_php($val)
+
+ $php_code = "";
+ if (!is_array($val)) $val = array($val);
+ reset($val);
+ while (list($k, $v)=each($val)) {
+
+ if ($this->length_e) {
+ $condition = "";
+ if ($this->minlength) $condition.=sprintf("(strlen($%s)<%s) || ", $this->name, (int)$this->minlength);
+ if ($this->maxlength) $condition.=sprintf("(strlen($%s)>%s) || ", $this->name, (int)$this->maxlength);
+ if (""!=$condition) {
+ $condition.="false";
+ $php_code.= $this->generate_php($condition, $this->name, $this->title, $this->length_e);
+ }
+ }
+
+ if ($this->valid_e) {
+ $condition = "";
+ if ($this->icase)
+ $condition.= sprintf("(!eregi(\"%s\", \"$%s\"))", $this->valid_regex, $this->name);
+ else
+ $condition.= sprintf("(!ereg(\"%s\", \"$%s\"))", $this->valid_regex, $this->name);
+ if (""!=$condition)
+ $php_code.=$this->generate_php($condition, $this->name, $this->title, $this->valid_e);
+ }
+ }
+ return $php_code;
+ } // end func self_validate_php($val)
 
 } // end TEXT
-?>
\ No newline at end of file
+?>
Index: php-lib/php/of_textarea.inc
diff -u php-lib/php/of_textarea.inc:1.7 php-lib/php/of_textarea.inc:1.8
--- php-lib/php/of_textarea.inc:1.7 Thu Nov 18 00:47:42 1999
+++ php-lib/php/of_textarea.inc Thu Nov 25 15:59:16 1999
@@ -3,7 +3,7 @@
  *
  * Copyright (c) 1998 by Jay Bloodworth
  *
- * $Id: of_textarea.inc,v 1.7 1999/11/17 23:47:42 uw Exp $
+ * $Id: of_textarea.inc,v 1.8 1999/11/25 14:59:16 negro Exp $
  */
 
 class of_textarea extends of_element {
@@ -25,7 +25,7 @@
       $str .= " wrap='$this->wrap'";
     if ($this->extrahtml)
       $str .= " $this->extrahtml";
- $str .= ">" . htmlspecialchars($this->value) ."</textarea>\n";
+ $str .= ">" . htmlspecialchars($this->value) ."</textarea>";
     
     $count = 1;
     return $str;
@@ -44,23 +44,23 @@
   }
   
   function self_validate_php($val) {
-
- $php_code = "";
-
- if ($this->length_e) {
- if ($this->minlength) {
- $condition.=sprintf("(strlen($%s) < %s) ||", $this->name, (int)$this->minlength);
- } else if ($this->maxlength) {
- $condition.=sprintf("(strlen($%s) > %s) ||", $this->name, (int)$this->maxlength);
- }
- if (""!=$condition) {
- $condition.="false";
- $php_code.= $this->generate_php($condition, $this->name, $this->title, $this->length_e);
- }
- }
-
- return $php_code;
- } // end func self_validate_php
+
+ $php_code = "";
+
+ if ($this->length_e) {
+ if ($this->minlength) {
+ $condition.=sprintf("(strlen($%s) < %s) ||", $this->name, (int)$this->minlength);
+ } else if ($this->maxlength) {
+ $condition.=sprintf("(strlen($%s) > %s) ||", $this->name, (int)$this->maxlength);
+ }
+ if (""!=$condition) {
+ $condition.="false";
+ $php_code.= $this->generate_php($condition, $this->name, $this->title, $this->length_e);
+ }
+ }
+
+ return $php_code;
+ } // end func self_validate_php
 
 } // end TEXTAREA
 

-
PHPLIB Developers Mailing List. Send messages to <phplib-dev <email protected>>.
To unsubscribe, send "unsubscribe" to <phplib-dev-request <email protected>> in
the body, not the subject, of your message.