Show
Ignore:
Timestamp:
06/29/05 23:04:21 (8 years ago)
Author:
fproulx
Message:

2005-06-17 Francois Proulx <francois.proulx@…>

  • Added IFrame and SimpleIFrame content types.
Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/wifidog-auth/wifidog/include/schema_validate.php

    r651 r657  
    2727require_once BASEPATH.'classes/AbstractDb.php'; 
    2828require_once BASEPATH.'classes/Session.php'; 
    29 define('REQUIRED_SCHEMA_VERSION', 18); 
     29define('REQUIRED_SCHEMA_VERSION', 19); 
    3030 
    3131/** Check that the database schema is up to date.  If it isn't, offer to update it. */ 
     
    451451        } 
    452452         
     453        $new_schema_version = 19; 
     454        if($schema_version < $new_schema_version) 
     455        { 
     456            echo "<h2>Preparing SQL statements to update schema to version  $new_schema_version</h2>\n"; 
     457            $sql .= "\n\nUPDATE schema_info SET value='$new_schema_version' WHERE tag='schema_version';\n";  
     458            $sql .= "CREATE TABLE iframes ("; 
     459            $sql .= "iframes_id text NOT NULL PRIMARY KEY REFERENCES content ON DELETE CASCADE ON UPDATE CASCADE,"; 
     460            $sql .= "url text,"; 
     461            $sql .= "width int4,"; 
     462            $sql .= "height int4"; 
     463            $sql .= ");\n"; 
     464        } 
     465         
    453466                $db->ExecSqlUpdate("BEGIN;\n$sql\nCOMMIT;\n", true); 
    454467                echo "</html></head>";