1 |
1475
|
Luisehahne
|
<?php
|
2 |
|
|
/**
|
3 |
|
|
*
|
4 |
|
|
* @category modules
|
5 |
|
|
* @package output_filter
|
6 |
|
|
* @author WebsiteBaker Project
|
7 |
|
|
* @copyright 2004-2009, Ryan Djurovich
|
8 |
|
|
* @copyright 2009-2011, Website Baker Org. e.V.
|
9 |
|
|
* @link http://www.websitebaker2.org/
|
10 |
|
|
* @license http://www.gnu.org/licenses/gpl.html
|
11 |
|
|
* @platform WebsiteBaker 2.8.x
|
12 |
|
|
* @requirements PHP 5.2.2 and higher
|
13 |
|
|
* @version $Id$
|
14 |
|
|
* @filesource $HeadURL$
|
15 |
|
|
* @lastmodified $Date$
|
16 |
|
|
*
|
17 |
|
|
*/
|
18 |
|
|
|
19 |
|
|
// Must include code to stop this file being access directly
|
20 |
|
|
if(defined('WB_PATH') == false) { die("Cannot access this file directly"); }
|
21 |
1477
|
Luisehahne
|
global $i;
|
22 |
1475
|
Luisehahne
|
$table_name = TABLE_PREFIX .'mod_output_filter';
|
23 |
|
|
$field_name = 'sys_rel';
|
24 |
1477
|
Luisehahne
|
$i = (!isset($i) ? 1 : $i);
|
25 |
|
|
print "<div style=\"margin:1em auto;font-size:1.1em;\">";
|
26 |
|
|
print "<h4>Step $i: Updating Output Filter</h4>\n";
|
27 |
|
|
$i++;
|
28 |
|
|
$OK = "<span class=\"ok\">OK</span>";
|
29 |
|
|
$FAIL = "<span class=\"error\">FAILED</span>";
|
30 |
|
|
if ( ($database->field_exists($table_name,$field_name) )) {
|
31 |
|
|
print "<br /><strong>'Output Filter already updated'</strong> $OK<br />\n";
|
32 |
|
|
} else {
|
33 |
|
|
$description = 'VARCHAR(1) NOT NULL DEFAULT \'0\'';
|
34 |
|
|
if( ($database->field_add($table_name,$field_name,$description )) ) {
|
35 |
|
|
print "<br /><strong>Updating Output Filter</strong> $OK<br />\n";
|
36 |
|
|
} else {
|
37 |
|
|
print "<br /><strong>Updating Output Filter</strong> $FAIL<br />\n";
|
38 |
|
|
}
|
39 |
1475
|
Luisehahne
|
}
|
40 |
1477
|
Luisehahne
|
print "</div>";
|