Project

General

Profile

« Previous | Next » 

Revision 1894

Added by Dietmar over 11 years ago

  1. bugfix form intall form284db.sql
  2. bugfix wb_search_data.sql layout for table settings
    ! update menu_link module and set Version to 2.8.1

View differences:

branches/2.8.x/CHANGELOG
13 13

  
14 14

  
15 15

  
16
19 Mar-2013 Build 1894 Dietmar Woellbrink (Luisehahne)
17
# bugfix form intall form284db.sql
18
# bugfix wb_search_data.sql layout for table settings 
19
! update menu_link module and set Version to 2.8.1
16 20
19 Mar-2013 Build 1893 Dietmar Woellbrink (Luisehahne)
17

  
21
# little issue on handing the cache in TranslationTable
22
# fix missing block or block[0] issue in /admin/pages/section.php
18 23
19 Mar-2013 Build 1892 Dietmar Woellbrink (Luisehahne)
19 24
! update output_filter module set version to 0.4.1 
20 25
19 Mar-2013 Build 1891 Dietmar Woellbrink (Luisehahne)
branches/2.8.x/wb/upgrade-script.php
369 369
 */
370 370
	$aMissingTables = UpgradeHelper::existsAllTables($aPackage);
371 371
	if( sizeof($aMissingTables) == 0){
372
        echo '<h4 style="margin-left:0;">NOTICE: '.sizeof($aPackage).' total tables included in package are successful installed your database `'.$database->DbName.'` '.$OK.'</h4>';
372
        echo '<h4 style="margin-left:0;">NOTICE: '.sizeof($aPackage).' total tables included in package are successfully installed into your database `'.$database->DbName.'` '.$OK.'</h4>';
373 373
    } else {
374 374
        status_msg('<strong>:</strong><br />can\'t run Upgrade, missing tables', 'warning', 'div');
375 375
        echo '<h4>Missing required tables. You can install them in backend->addons->modules.<br />';
......
397 397
        </body>
398 398
        </html>";
399 399

  
400
        exit();
401
    }
400
		exit();
401
	}
402 402

  
403 403
echo '<h3>Step '.(++$stepID).': Setting default_theme</h3>';
404 404
$aDebugMessage = array();
405
    /**********************************************************
406
     *  - Adding field default_theme to settings table
407
     */
408
    $aDebugMessage[] = '<div style="margin-left:2em;">';
409
    $aDebugMessage[] = "<br /><span><strong>Adding default_theme to settings table</strong></span>";
410
    // db_update_key_value('settings', 'default_theme', $DEFAULT_THEME);
411
    $cfg = array(
412
    	'default_theme' => defined('DEFAULT_THEME')&& (DEFAULT_THEME!='') ? DEFAULT_THEME : $DEFAULT_THEME
413
    );
414
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
415
    $aDebugMessage[] = '</div>';
405
	/**********************************************************
406
	 *  - Adding field default_theme to settings table
407
	 */
408
	$aDebugMessage[] = '<div style="margin-left:2em;">';
409
	$aDebugMessage[] = "<br /><span><strong>Adding default_theme to settings table</strong></span>";
410
	// db_update_key_value('settings', 'default_theme', $DEFAULT_THEME);
411
	$cfg = array(
412
		'default_theme' => defined('DEFAULT_THEME')&& (DEFAULT_THEME!='') ? DEFAULT_THEME : $DEFAULT_THEME
413
	);
414
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
415
	$aDebugMessage[] = '</div>';
416 416

  
417 417
if($bDebugModus) {
418
    echo implode(PHP_EOL,$aDebugMessage);
418
	echo implode(PHP_EOL,$aDebugMessage);
419 419
}
420 420
$aDebugMessage = array();
421 421
echo'<h3>Step '.(++$stepID).': Updating core table included in package</h3>';
422
    /**********************************************************
423
     *  - Adding field sec_anchor to settings table
424
     */
425
    echo '<div style="margin-left:2em;">';
426
    echo "<h4>Adding/updating entries on table settings</h4>";
427
    $aDebugMessage[] = "<span>Adding/updating sec_anchor to settings table</span>";
428
    $cfg = array(
429
    	'sec_anchor' => defined('SEC_ANCHOR')&& (SEC_ANCHOR!='') ? SEC_ANCHOR : 'section_'
430
    );
431
   $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
422
	/**********************************************************
423
	 *  - Adding field sec_anchor to settings table
424
	 */
425
	echo '<div style="margin-left:2em;">';
426
	echo "<h4>Adding/updating entries on table settings</h4>";
427
	$aDebugMessage[] = "<span>Adding/updating sec_anchor to settings table</span>";
428
	$cfg = array(
429
		'sec_anchor' => defined('SEC_ANCHOR')&& (SEC_ANCHOR!='') ? SEC_ANCHOR : 'section_'
430
	);
431
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
432 432

  
433
    /**********************************************************
434
     *  - Adding redirect timer to settings table
435
     */
436
    $aDebugMessage[] = "<span>Adding/updating redirect timer to settings table</span>";
437
    $cfg = array(
438
    	'redirect_timer' => defined('REDIRECT_TIMER')&& (REDIRECT_TIMER!='') ? REDIRECT_TIMER : '1500'
439
    );
440
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
433
	/**********************************************************
434
	 *  - Adding redirect timer to settings table
435
	 */
436
	$aDebugMessage[] = "<span>Adding/updating redirect timer to settings table</span>";
437
	$cfg = array(
438
		'redirect_timer' => defined('REDIRECT_TIMER')&& (REDIRECT_TIMER!='') ? REDIRECT_TIMER : '1500'
439
	);
440
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
441 441

  
442
    /**********************************************************
443
     *  - Adding default_time_formatr to settings table
444
     */
445
    $aDebugMessage[] = "<span>Adding/updating default_time_format to settings table</span>";
446
    $cfg = array(
447
    	'default_time_format' => defined('DEFAULT_TIME_FORMAT')&& (DEFAULT_TIME_FORMAT!='') ? DEFAULT_TIME_FORMAT : 'h:i A'
448
    );
449
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
442
	/**********************************************************
443
	 *  - Adding default_time_formatr to settings table
444
	 */
445
	$aDebugMessage[] = "<span>Adding/updating default_time_format to settings table</span>";
446
	$cfg = array(
447
		'default_time_format' => defined('DEFAULT_TIME_FORMAT')&& (DEFAULT_TIME_FORMAT!='') ? DEFAULT_TIME_FORMAT : 'h:i A'
448
	);
449
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
450 450

  
451
    /**********************************************************
452
     *  - Adding rename_files_on_upload to settings table
453
     */
454
    $aDebugMessage[] = "<span>Adding/Updating rename_files_on_upload to settings table</span>";
455
    $cfg = array(
456
        'rename_files_on_upload' => (defined('RENAME_FILES_ON_UPLOAD')&& (RENAME_FILES_ON_UPLOAD!='') ? RENAME_FILES_ON_UPLOAD : 'ph.*?,cgi,pl,pm,exe,com,bat,pif,cmd,src,asp,aspx,js')
457
    );
458
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
451
	/**********************************************************
452
	 *  - Adding rename_files_on_upload to settings table
453
	 */
454
	$aDebugMessage[] = "<span>Adding/Updating rename_files_on_upload to settings table</span>";
455
	$cfg = array(
456
	    'rename_files_on_upload' => (defined('RENAME_FILES_ON_UPLOAD')&& (RENAME_FILES_ON_UPLOAD!='') ? RENAME_FILES_ON_UPLOAD : 'ph.*?,cgi,pl,pm,exe,com,bat,pif,cmd,src,asp,aspx,js')
457
	);
458
	if( version_compare( WB_VERSION, '2.8.2', '<' )) {
459
		$cfg = array(
460
		    'rename_files_on_upload' => 'ph.*?,cgi,pl,pm,exe,com,bat,pif,cmd,src,asp,aspx,js'
461
		);
462
	}
463
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
459 464

  
460
    /**********************************************************
461
     *  - Adding mediasettings to settings table
462
     */
463
    $aDebugMessage[] = "<span>Adding/updating mediasettings to settings table</span>";
464
    $cfg = array(
465
    	'mediasettings' => (defined('MEDIASETTINGS')&& (MEDIASETTINGS!='') ? MEDIASETTINGS : ''),
466
    );
465
	/**********************************************************
466
	 *  - Adding mediasettings to settings table
467
	 */
468
	$aDebugMessage[] = "<span>Adding/updating mediasettings to settings table</span>";
469
	$cfg = array(
470
		'mediasettings' => (defined('MEDIASETTINGS')&& (MEDIASETTINGS!='') ? MEDIASETTINGS : ''),
471
	);
467 472

  
468
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
473
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
469 474

  
470
    /**********************************************************
471
     *  - Adding fingerprint_with_ip_octets to settings table
472
     */
473
    $aDebugMessage[] = "<span>Adding/updating fingerprint_with_ip_octets to settings table</span>";
474
    $cfg = array(
475
    	'fingerprint_with_ip_octets' => (defined('FINGERPRINT_WITH_IP_OCTETS') ? FINGERPRINT_WITH_IP_OCTETS : '2'),
476
    	'secure_form_module' => (defined('SECURE_FORM_MODULE') ? SECURE_FORM_MODULE : '')
477
    );
475
	/**********************************************************
476
	 *  - Adding fingerprint_with_ip_octets to settings table
477
	 */
478
	$aDebugMessage[] = "<span>Adding/updating fingerprint_with_ip_octets to settings table</span>";
479
	$cfg = array(
480
		'fingerprint_with_ip_octets' => (defined('FINGERPRINT_WITH_IP_OCTETS') ? FINGERPRINT_WITH_IP_OCTETS : '2'),
481
		'secure_form_module' => (defined('SECURE_FORM_MODULE') ? SECURE_FORM_MODULE : '')
482
	);
478 483

  
479
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
484
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
480 485

  
481
    /**********************************************************
482
     *  - Adding page_icon_dir to settings table
483
     */
484
    $aDebugMessage[] = "<span>Adding/updating page_icon_dir to settings table</span>";
485
    $cfg = array(
486
    	'page_icon_dir' => (defined('PAGE_ICON_DIR')&& (PAGE_ICON_DIR!='') ? PAGE_ICON_DIR : '/templates/*/title_images'),
487
    );
486
	/**********************************************************
487
	 *  - Adding page_icon_dir to settings table
488
	 */
489
	$aDebugMessage[] = "<span>Adding/updating page_icon_dir to settings table</span>";
490
	$cfg = array(
491
		'page_icon_dir' => (defined('PAGE_ICON_DIR')&& (PAGE_ICON_DIR!='') ? PAGE_ICON_DIR : '/templates/*/title_images'),
492
	);
488 493

  
489
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
490
    /**********************************************************
491
     *  - Adding page_extended to settings table
492
     */
493
    $aDebugMessage[] = "<span>Adding/updating page_extendet to settings table</span>";
494
    $cfg = array(
495
    	'page_extendet' => (defined('PAGE_EXTENDET') ? PAGE_EXTENDET : 'true'),
496
    );
494
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
495
	/**********************************************************
496
	 *  - Adding page_extended to settings table
497
	 */
498
	$aDebugMessage[] = "<span>Adding/updating page_extendet to settings table</span>";
499
	$cfg = array(
500
		'page_extendet' => (defined('PAGE_EXTENDET') ? PAGE_EXTENDET : 'true'),
501
	);
497 502

  
498
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
503
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
499 504

  
500
    /**********************************************************
501
     *  - Adding wbmail_signature to settings table
502
     */
503
    $aDebugMessage[] = "<span>Adding/updating wbmail_signature to settings table</span>";
504
    $cfg = array(
505
    	'wbmail_signature' => (defined('WBMAIL_SIGNATURE')&& (WBMAIL_SIGNATURE!='') ? WBMAIL_SIGNATURE : '')
506
    );
505
	/**********************************************************
506
	 *  - Adding wbmail_signature to settings table
507
	 */
508
	$aDebugMessage[] = "<span>Adding/updating wbmail_signature to settings table</span>";
509
	$cfg = array(
510
		'wbmail_signature' => (defined('WBMAIL_SIGNATURE')&& (WBMAIL_SIGNATURE!='') ? WBMAIL_SIGNATURE : '')
511
	);
507 512

  
508
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
513
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
509 514

  
510
    /**********************************************************
511
     *  - Adding confirmed_registration to settings table
512
     */
513
    $aDebugMessage[] = "<span>Adding/updating confirmed_registration to settings table</span>";
514
    $cfg = array(
515
    	'confirmed_registration' => (defined('CONFIRMED_REGISTRATION') ? CONFIRMED_REGISTRATION : '0')
516
    );
515
	/**********************************************************
516
	 *  - Adding confirmed_registration to settings table
517
	 */
518
	$aDebugMessage[] = "<span>Adding/updating confirmed_registration to settings table</span>";
519
	$cfg = array(
520
		'confirmed_registration' => (defined('CONFIRMED_REGISTRATION') ? CONFIRMED_REGISTRATION : '0')
521
	);
517 522

  
518
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
523
	$aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
519 524

  
520
    /**********************************************************
521
     *  - Adding dev_infos to settings table
522
     */
523
    $aDebugMessage[] = "<span>Adding/updating dev_infos to settings table</span>";
524
    $cfg = array(
525
    	'dev_infos' => (defined('DEV_INFOS') ? DEV_INFOS : 'false')
526
    );
525
	/**********************************************************
526
	 *  - Adding dev_infos to settings table
527
	 */
528
	$aDebugMessage[] = "<span>Adding/updating dev_infos to settings table</span>";
529
	$cfg = array(
530
		'dev_infos' => (defined('DEV_INFOS') ? DEV_INFOS : 'false')
531
	);
527 532

  
528 533
    $aDebugMessage[] = (db_update_key_value( 'settings', $cfg ) ? " $OK<br />" : " $FAIL!<br />");
529 534

  
......
535 540
$aDebugMessage = array();
536 541
if(version_compare(WB_REVISION, REVISION, '<='))
537 542
{
538
    echo '<div style="margin-left:2em;">';
543
	echo '<div style="margin-left:2em;">';
539 544
	/**********************************************************
540 545
	 *  - Update search no results database filed to create
541 546
	 *  valid XHTML if search is empty
542 547
	 */
543 548
	if (version_compare(WB_VERSION, '2.8', '<'))
544 549
	{
545
        echo "<h4>Adding/updating fields on table search</h4>";
546
	    echo "Updating database field `no_results` on search table: ";
547
	    $search_no_results = addslashes('<tr><td><p>[TEXT_NO_RESULTS]</p></td></tr>');
548
	    $sql  = 'UPDATE `'.TABLE_PREFIX.'search` ';
550
		echo "<h4>Adding/updating fields on table search</h4>";
551
		echo "Updating database field `no_results` on search table: ";
552
		$search_no_results = addslashes('<tr><td><p>[TEXT_NO_RESULTS]</p></td></tr>');
553
		$sql  = 'UPDATE `'.TABLE_PREFIX.'search` ';
549 554
		$sql .= 'SET `value`=\''.$search_no_results.'\' ';
550 555
		$sql .= 'WHERE `name`=\'no_results\'';
551
	    echo ($database->query($sql)) ? " $OK<br />" : " $FAIL!<br />";
556
		echo ($database->query($sql)) ? " $OK<br />" : " $FAIL!<br />";
552 557
	}
553 558

  
554
	echo "<h4>Adding/updating field on table mod_menu_link</h4>";
559
	$aDebugMessage = array();
560
	echo "<h4>Adding/updating field on table pages</h4>";
555 561
	/**********************************************************
556
     *  - Add field "redirect_type" to table "mod_menu_link"
557
     *  has to be moved later to upgrade.php in modul menu_link, because modul can be removed
558
     */
559
	$table_name = TABLE_PREFIX.'mod_menu_link';
560
	$field_name = 'redirect_type';
561
	$description = "INT NOT NULL DEFAULT '301' AFTER `target_page_id`";
562
	add_modify_field_in_database($table_name,$field_name,$description);
563

  
564
    if($bDebugModus) {
565
        echo implode(PHP_EOL,$aDebugMessage);
566
    }
567

  
568
    $aDebugMessage = array();
569
    echo "<h4>Adding/updating field on table pages</h4>";
570
	/**********************************************************
571 562
	 *  - Add field "page_trail" to table "pages"
572 563
	 */
573 564
	$table_name = TABLE_PREFIX.'pages';
......
576 567
	add_modify_field_in_database($table_name,$field_name,$description);
577 568

  
578 569
	/**********************************************************
579
     *  - Add field "page_icon" to table "pages"
580
     */
570
	 *  - Add field "page_icon" to table "pages"
571
	 */
581 572
	$table_name = TABLE_PREFIX.'pages';
582 573
	$field_name = 'page_icon';
583 574
	$description = "VARCHAR( 512 ) NOT NULL DEFAULT '' AFTER `page_title`";
584
    add_modify_field_in_database($table_name,$field_name,$description);
575
	add_modify_field_in_database($table_name,$field_name,$description);
585 576

  
586 577
	/**********************************************************
587 578
	 *  - Add field "page_code" to table "pages"
......
589 580
	$table_name = TABLE_PREFIX.'pages';
590 581
	$field_name = 'page_code';
591 582
	$description = "INT NOT NULL DEFAULT '0' AFTER `language`";
592
    add_modify_field_in_database($table_name,$field_name,$description);
583
	add_modify_field_in_database($table_name,$field_name,$description);
593 584

  
594 585
	/**********************************************************
595
     *  - Add field "menu_icon_0" to table "pages"
596
     */
586
	 *  - Add field "menu_icon_0" to table "pages"
587
	 */
597 588
	$table_name = TABLE_PREFIX.'pages';
598 589
	$field_name = 'menu_icon_0';
599 590
	$description = "VARCHAR( 512 ) NOT NULL DEFAULT '' AFTER `menu_title`";
600
    add_modify_field_in_database($table_name,$field_name,$description);
591
	add_modify_field_in_database($table_name,$field_name,$description);
601 592

  
602 593
	/**********************************************************
603 594
	 *  - Add field "menu_icon_1" to table "pages"
604
     */
595
	 */
605 596
	$table_name = TABLE_PREFIX.'pages';
606 597
	$field_name = 'menu_icon_1';
607 598
	$description = "VARCHAR( 512 ) NOT NULL DEFAULT '' AFTER `menu_icon_0`";
608
    add_modify_field_in_database($table_name,$field_name,$description);
599
	add_modify_field_in_database($table_name,$field_name,$description);
609 600

  
610 601
	/**********************************************************
611 602
	 *  - Add field "tooltip" to table "pages"
612
     */
603
	 */
613 604
	$table_name = TABLE_PREFIX.'pages';
614 605
	$field_name = 'tooltip';
615 606
	$description = "VARCHAR( 512 ) NOT NULL DEFAULT '' AFTER `menu_icon_1`";
616
    add_modify_field_in_database($table_name,$field_name,$description);
607
	add_modify_field_in_database($table_name,$field_name,$description);
617 608

  
618 609
	/**********************************************************
619 610
	 *  - Add field "admin_groups" to table "pages"
620
     */
611
	 */
621 612
	$table_name = TABLE_PREFIX.'pages';
622 613
	$field_name = 'admin_groups';
623 614
	$description = "VARCHAR( 512 ) NOT NULL DEFAULT '1'";
624
    add_modify_field_in_database($table_name,$field_name,$description);
615
	add_modify_field_in_database($table_name,$field_name,$description);
625 616

  
626 617
	/**********************************************************
627 618
	 *  - Add field "admin_users" to table "pages"
......
629 620
	$table_name = TABLE_PREFIX.'pages';
630 621
	$field_name = 'admin_users';
631 622
	$description = "VARCHAR( 512 ) NOT NULL DEFAULT ''";
632
    add_modify_field_in_database($table_name,$field_name,$description);
623
	add_modify_field_in_database($table_name,$field_name,$description);
633 624

  
634 625
	/**********************************************************
635 626
	 *  - Add field "viewing_groups" to table "pages"
......
637 628
	$table_name = TABLE_PREFIX.'pages';
638 629
	$field_name = 'viewing_groups';
639 630
	$description = "VARCHAR( 512 ) NOT NULL DEFAULT '1'";
640
//	echo "<span>Modify field viewing_groups to pages table</span>";
641
//	echo ($database->field_modify($table_name, $field_name, $description) ? " $OK<br />" : " $FAIL!<br />");
642
    add_modify_field_in_database($table_name,$field_name,$description);
631
	 add_modify_field_in_database($table_name,$field_name,$description);
643 632

  
644 633
	/**********************************************************
645 634
	 *  - Add field "viewing_users" to table "pages"
......
647 636
	$table_name = TABLE_PREFIX.'pages';
648 637
	$field_name = 'viewing_users';
649 638
	$description = "VARCHAR( 512 ) NOT NULL DEFAULT ''";
650
    add_modify_field_in_database($table_name,$field_name,$description);
639
	add_modify_field_in_database($table_name,$field_name,$description);
651 640

  
652 641
	/**********************************************************
653
     *  - Add field "custom01" to table "pages"
654
     */
642
	 *  - Add field "custom01" to table "pages"
643
	 */
655 644
	$table_name = TABLE_PREFIX.'pages';
656 645
	$field_name = 'custom01';
657 646
	$description = "VARCHAR( 255 ) NOT NULL DEFAULT '' ";
658
    add_modify_field_in_database($table_name,$field_name,$description);
647
	add_modify_field_in_database($table_name,$field_name,$description);
659 648

  
660 649
	/**********************************************************
661
     *  - Add field "custom02" to table "pages"
662
     */
650
	 *  - Add field "custom02" to table "pages"
651
	 */
663 652
	$table_name = TABLE_PREFIX.'pages';
664 653
	$field_name = 'custom02';
665 654
	$description = "VARCHAR( 255 ) NOT NULL DEFAULT '' ";
666
    add_modify_field_in_database($table_name,$field_name,$description);
655
	add_modify_field_in_database($table_name,$field_name,$description);
667 656

  
668
    if($bDebugModus) {
669
        echo implode(PHP_EOL,$aDebugMessage);
670
    }
657
	if($bDebugModus) {
658
		echo implode(PHP_EOL,$aDebugMessage);
659
	}
671 660

  
672 661
	$aDebugMessage = array();
673 662
	/**********************************************************
674
     * modify wrong strucre on table sections
675
     * wrong structure let crash wb
676
     */
663
	 * modify wrong strucre on table sections
664
	 * wrong structure let crash wb
665
	 */
677 666
	echo "<h4>Change field structure on table sections</h4>";
678 667
	$table_name = TABLE_PREFIX.'sections';
679 668
	$description = "VARCHAR( 255 ) NOT NULL DEFAULT ''";
......
688 677
	$aDebugMessage[] = "<span>Modify field publ_end on sections table</span>";
689 678
	$aDebugMessage[] = ($database->field_modify($table_name, 'publ_end', $description) ? " $OK<br />" : " $FAIL!<br />");
690 679

  
691
    if($bDebugModus) {
692
        echo implode(PHP_EOL,$aDebugMessage);
693
    }
694
    echo '</div>';
680
	if($bDebugModus) {
681
		echo implode(PHP_EOL,$aDebugMessage);
682
	}
683
	echo '</div>';
695 684
}
696 685

  
697 686
if(version_compare(WB_REVISION, REVISION, '<='))
698 687
{
699
    $aDebugMessage = array();
700
    echo '<h3>Step '.(++$stepID).': Updating structure in table users/groups</h3>';
688
	$aDebugMessage = array();
689
	echo '<h3>Step '.(++$stepID).': Updating structure in table users/groups</h3>';
701 690
	/**********************************************************
702 691
	 * Modify Administrator on groups table
703 692
	 */
......
717 706
	$sql .= '`module_permissions` = \''.$sModulePermissions.'\', ';
718 707
	$sql .= '`template_permissions` = \''.$sTemplatePermissions.'\' ';
719 708
	$sql .= 'WHERE `group_id` = \'1\' ';
720
    $aDebugMessage[] = ($database->query($sql)) ? " $OK<br />" : " $FAIL!<br />";
721
    if( ($admin->is_authenticated() == true) && ($admin->ami_group_member('1') ) ) {
722
        $_SESSION['SYSTEM_PERMISSIONS'] = array_merge($_SESSION['SYSTEM_PERMISSIONS'], explode(',', $sSystemPermissions));
723
    }
709
	$aDebugMessage[] = ($database->query($sql)) ? " $OK<br />" : " $FAIL!<br />";
710
	if( ($admin->is_authenticated() == true) && ($admin->ami_group_member('1') ) ) {
711
	    $_SESSION['SYSTEM_PERMISSIONS'] = array_merge($_SESSION['SYSTEM_PERMISSIONS'], explode(',', $sSystemPermissions));
712
	}
724 713

  
725
    if($bDebugModus) {
726
        echo implode(PHP_EOL,$aDebugMessage);
727
    }
728
    echo '</div>';
729
    $aDebugMessage = array();
730
    /**********************************************************
714
	if($bDebugModus) {
715
		echo implode(PHP_EOL,$aDebugMessage);
716
	}
717
	echo '</div>';
731 718
	$aDebugMessage = array();
732 719
	/**********************************************************
733
 *   `confirm_code` VARCHAR(32) NOT NULL DEFAULT '',
734
 *   `confirm_timeout` INT(11) NOT NULL DEFAULT '0',
735
 */
720
	 *   `confirm_code` VARCHAR(32) NOT NULL DEFAULT '',
721
	 *   `confirm_timeout` INT(11) NOT NULL DEFAULT '0',
722
	 */
736 723
	echo '<div style="margin-left:2em;">';
737 724
	echo "<h4>Change field structure on table users</h4>";
738 725
	$table_name = TABLE_PREFIX.'users';
739 726
	$field_name = 'confirm_code';
740 727
	$description = "VARCHAR( 32 ) NOT NULL DEFAULT '' AFTER `password` ";
741
    add_modify_field_in_database($table_name,$field_name,$description);
728
	add_modify_field_in_database($table_name,$field_name,$description);
742 729

  
743 730
	$table_name = TABLE_PREFIX.'users';
744 731
	$field_name = 'confirm_timeout';
745 732
	$description = "INT(11) NOT NULL DEFAULT '0' AFTER `confirm_code` ";
746
    add_modify_field_in_database($table_name,$field_name,$description);
733
	add_modify_field_in_database($table_name,$field_name,$description);
747 734

  
748
    if($bDebugModus) {
749
        echo implode(PHP_EOL,$aDebugMessage);
750
    }
751
    echo '</div>';
735
	if($bDebugModus) {
736
	    echo implode(PHP_EOL,$aDebugMessage);
737
	}
738
	echo '</div>';
752 739

  
753
    $aDebugMessage = array();
754
   /**********************************************************
755
    * Updating group_id in table users
756
    */
740
	$aDebugMessage = array();
741
	/**********************************************************
742
	* Updating group_id in table users
743
	*/
757 744
	echo '<div style="margin-left:2em;">';
758 745
	echo "<h4>Updating users groups permissions on table groups</h4>";
759
        $aUsers = array();
746
	    $aUsers = array();
760 747
		// Get existing values
761 748
        $sql  = 'SELECT * FROM `'.TABLE_PREFIX.'users` ' ;
762 749
        $sql .= 'WHERE `user_id` != 1 ';
......
785 772
                $aDebugMessage[] = $database->is_error()==false ? $sMessage." $OK<br />" : $sMessage." $FAIL!<br />";
786 773
        }
787 774
        unset($aUsers);
788
    $aDebugMessage[] = '</div>';
775
	$aDebugMessage[] = '</div>';
789 776

  
790
    if($bDebugModus) {
791
    // $aDebugMessage[] =
792
        echo implode(PHP_EOL,$aDebugMessage);
793
    }else {
794
        echo '<span><strong>'.$iTotalUsers.' users updating the groups</strong></span>'." $OK<br />";
795
        echo '</div>';
796
    }
777
	if($bDebugModus) {
778
	// $aDebugMessage[] =
779
	    echo implode(PHP_EOL,$aDebugMessage);
780
	}else {
781
	    echo '<span><strong>'.$iTotalUsers.' users updating the groups</strong></span>'." $OK<br />";
782
	    echo '</div>';
783
	}
797 784
}
798 785

  
799 786
$aDebugMessage = array();
800 787
echo '<h3>Step '.(++$stepID).': Updating access and protected files in folders</h3>';
801 788

  
802 789
echo '<div style="margin-left:2em;">';
803
    /**********************************************************
804
    * upgrade media directory index protect files
805
    */
806
    $dir = (WB_PATH.MEDIA_DIRECTORY);
807
    echo '<h4>Upgrade media directory '.MEDIA_DIRECTORY.'/ index.php protect files</h4>';
808
    $aDebugMessage = rebuildFolderProtectFile($dir);
809
    if( sizeof( $aDebugMessage ) ){
810
    	echo '<span><strong>Upgrade '.sizeof( $aDebugMessage ).' directory '.MEDIA_DIRECTORY.'/ protect files</strong></span>'." $OK<br />";
811
    } else {
812
    	echo '<span><strong>Upgrade directory '.MEDIA_DIRECTORY.'/ protect files</strong></span>'." $FAIL!<br />";
813
    	echo implode ('<br />',$aDebugMessage);
814
    }
790
	/**********************************************************
791
	* upgrade media directory index protect files
792
	*/
793
	$dir = (WB_PATH.MEDIA_DIRECTORY);
794
	echo '<h4>Upgrade media directory '.MEDIA_DIRECTORY.'/ index.php protect files</h4>';
795
	$aDebugMessage = rebuildFolderProtectFile($dir);
796
	if( sizeof( $aDebugMessage ) ){
797
		echo '<span><strong>Upgrade '.sizeof( $aDebugMessage ).' directory '.MEDIA_DIRECTORY.'/ protect files</strong></span>'." $OK<br />";
798
	} else {
799
		echo '<span><strong>Upgrade directory '.MEDIA_DIRECTORY.'/ protect files</strong></span>'." $FAIL!<br />";
800
		echo implode ('<br />',$aDebugMessage);
801
	}
815 802

  
816 803
    $aDebugMessage = array();
817 804
    /**********************************************************
......
965 952
	 * upgrade modules if newer version is available
966 953
	 * $aModuleList list of proofed modules
967 954
	 */
968
	$aModuleList = array('wysiwyg','form','code','captcha_control','output_filter');
955
	$aModuleList = array(
956
	              'captcha_control','code','form','menu_link',
957
	              'output_filter','wysiwyg');
969 958
	if(sizeof($aModuleList)) 
970 959
	{
971 960
		echo '<h3>Step '.(++$stepID).': Upgrade proofed modules</h3>';
branches/2.8.x/wb/admin/interface/version.php
51 51

  
52 52
// check if defined to avoid errors during installation (redirect to admin panel fails if PHP error/warnings are enabled)
53 53
if(!defined('VERSION')) define('VERSION', '2.8.3');
54
if(!defined('REVISION')) define('REVISION', '1893');
54
if(!defined('REVISION')) define('REVISION', '1894');
55 55
if(!defined('SP')) define('SP', '');
branches/2.8.x/wb/install/sql/wb_search_data.sql
6 6
--
7 7
INSERT INTO `{TABLE_PREFIX}search` VALUES(1, 'header', '<h1>[TEXT_SEARCH]</h1>\r\n<form name="searchpage" action="[WB_URL]/search/index.php" method="get">\r\n<table cellpadding="3" cellspacing="0" border="0" style="width:100%; max-width:500px">\r\n<tr>\r\n<td>\r\n<input type="hidden" name="search_path" value="[SEARCH_PATH]" />\r\n<input type="hidden" name="referrer" value="[REFERRER]" />\r\n<input type="text" name="string" value="[SEARCH_STRING]" style="width: 100%;" />\r\n</td>\r\n<td width="100">\r\n<input type="submit" value="[TEXT_SEARCH]" style="width: 100%;" />\r\n</td>\r\n</tr>\r\n<tr>\r\n<td colspan="2">\r\n<input type="radio" name="match" id="match_all" value="all"[ALL_CHECKED] />\r\n<label for="match_all">[TEXT_ALL_WORDS]</label>\r\n<input type="radio" name="match" id="match_any" value="any"[ANY_CHECKED] />\r\n<label for="match_any">[TEXT_ANY_WORDS]</label>\r\n<input type="radio" name="match" id="match_exact" value="exact"[EXACT_CHECKED] />\r\n<label for="match_exact">[TEXT_EXACT_MATCH]</label>\r\n</td>\r\n</tr>\r\n</table>\r\n</form>\r\n<hr />', '');
8 8
INSERT INTO `{TABLE_PREFIX}search` VALUES(2, 'footer', '', '');
9
INSERT INTO `{TABLE_PREFIX}search` VALUES(3, 'results_header', '<p>[TEXT_RESULTS_FOR] "<strong>[SEARCH_STRING]</strong>":</p>\r\n<div class="searchresults">', '');
9
INSERT INTO `{TABLE_PREFIX}search` VALUES(3, 'results_header', '<p>[TEXT_RESULTS_FOR] <strong>[SEARCH_STRING]</strong>:</p>\r\n<div class="searchresults">', '');
10 10
INSERT INTO `{TABLE_PREFIX}search` VALUES(4, 'results_loop', '<h3 style="margin:10px 0 3px 0;"><a href="[LINK]">[TITLE]</a></h3>\r\n<div style="font-size:0.8em;">[TEXT_LAST_UPDATED_BY] [DISPLAY_NAME] [TEXT_ON] [DATE]</div>\r\n<p style="padding: 0 0 5px 0; margin: 2px 0 10px 0; border-bottom: 1px solid #777;">[DESCRIPTION].. [EXCERPT]</p>', '');
11 11
INSERT INTO `{TABLE_PREFIX}search` VALUES(5, 'results_footer', '</div>', '');
12 12
INSERT INTO `{TABLE_PREFIX}search` VALUES(6, 'no_results', '<p>[TEXT_NO_RESULTS]</p>', '');
branches/2.8.x/wb/modules/menu_link/sql/mod_menu_link.sql
1
-- phpMyAdmin SQL Dump
2
-- version 3.5.7
3
-- Erstellungszeit: 15. Mrz 2013 um 18:21
4
--
5
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
6
-- --------------------------------------------------------
7
-- Database structure for WebsiteBaker core
8
--
9
-- Replacements: {TABLE_PREFIX}, {TABLE_ENGINE}, {TABLE_COLLATION}
10
--
11
-- --------------------------------------------------------
12
--
13
-- Tabellenstruktur für Tabelle `{TABLE_PREFIX}mod_menu_link`
14
--
15
DROP TABLE IF EXISTS `{TABLE_PREFIX}mod_menu_link`;
16
CREATE TABLE IF NOT EXISTS `{TABLE_PREFIX}mod_menu_link` (
17
  `section_id` int(11) NOT NULL DEFAULT '0',
18
  `page_id` int(11) NOT NULL DEFAULT '0',
19
  `target_page_id` int(11) NOT NULL DEFAULT '0',
20
  `redirect_type` int(11) NOT NULL DEFAULT '301',
21
  `anchor` varchar(255){TABLE_COLLATION} NOT NULL DEFAULT '0',
22
  `extern` varchar(255){TABLE_COLLATION} NOT NULL DEFAULT '',
23
  PRIMARY KEY (`section_id`)
24
){TABLE_ENGINE};
25
-- EndOfFile
branches/2.8.x/wb/modules/menu_link/info.php
1
<?php
2
/**
3
 *
4
 * @category        modules
5
 * @package         Menu Link
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: http://svn.websitebaker2.org/branches/2.8.x/wb/modules/wysiwyg/modify.php $
15
 * @lastmodified    $Date: 2011-01-11 20:29:52 +0100 (Di, 11 Jan 2011) $
16
 *
17
 */
18

  
19

  
20
/* History:
21
2.8 - June 2009
22
- Improved the pagelist (thorn)
23
- Added different redirect types 301 or 302 (thorn)
24
- Set platform version 2.8
25

  
26
2.7 - 24. Jan. 2008 - doc
27
- added language support, changed platform to 2.7
28

  
29
2.6.1.1 - 16. Jan. 2008 - thorn
30
- added table mod_menu_link
31
- added install.php, delete.php, add.php
32
- changed wb/index.php: redirect if page is menu_link
33
- removed special-handling of menu_link in: admin/pages/settings2.php
34

  
35
*/
36

  
37
$module_directory = 'menu_link';
38
$module_name = 'Menu Link';
39
$module_function = 'page';
40
$module_version = '2.8';
41
$module_platform = '2.8.x';
42
$module_author = 'Ryan Djurovich, thorn';
43
$module_license = 'GNU General Public License';
44
$module_description = 'This module allows you to insert a link into the menu.';
45

  
46
?>
1
<?php
2
/**
3
 *
4
 * @category        modules
5
 * @package         Menu Link
6
 * @author          WebsiteBaker Project
7
 * @copyright       2004-2009, Ryan Djurovich
8
 * @copyright       2009-2013, WebsiteBaker 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: http://svn.websitebaker2.org/branches/2.8.x/wb/modules/wysiwyg/modify.php $
15
 * @lastmodified    $Date: 2011-01-11 20:29:52 +0100 (Di, 11 Jan 2011) $
16
 *
17
 */
18

  
19

  
20
/* History:
21
2.8 - June 2009
22
- Improved the pagelist (thorn)
23
- Added different redirect types 301 or 302 (thorn)
24
- Set platform version 2.8
25

  
26
2.7 - 24. Jan. 2008 - doc
27
- added language support, changed platform to 2.7
28

  
29
2.6.1.1 - 16. Jan. 2008 - thorn
30
- added table mod_menu_link
31
- added install.php, delete.php, add.php
32
- changed wb/index.php: redirect if page is menu_link
33
- removed special-handling of menu_link in: admin/pages/settings2.php
34

  
35
*/
36

  
37
$module_directory = 'menu_link';
38
$module_name = 'Menu Link';
39
$module_function = 'page';
40
$module_version = '2.8.1';
41
$module_platform = '2.8.4';
42
$module_author = 'Ryan Djurovich, thorn';
43
$module_license = 'GNU General Public License';
44
$module_description = 'This module allows you to insert a link into the menu.';
branches/2.8.x/wb/modules/menu_link/install.php
4 4
 * @category        modules
5 5
 * @package         menu_link
6 6
 * @author          Ryan Djurovich, WebsiteBaker Project
7
 * @copyright       2009-2012, Website Baker Org. e.V.
8
 * @link			http://www.websitebaker2.org/
7
 * @copyright       2009-2013, WebsiteBaker Org. e.V.
8
 * @link            http://www.websitebaker2.org/
9 9
 * @license         http://www.gnu.org/licenses/gpl.html
10 10
 * @platform        WebsiteBaker 2.8.x
11 11
 * @requirements    PHP 5.2.2 and higher
12
 * @version      	$Id$
13
 * @filesource		$HeadURL$
12
 * @version         $Id$
13
 * @filesource      $HeadURL$
14 14
 * @lastmodified    $Date$
15 15
 *
16 16
 */
17 17

  
18
// Must include code to stop this file being access directly
19 18
/* -------------------------------------------------------- */
20
if(defined('WB_PATH') == false)
21
{
22
	// Stop this file being access directly
23
		die('<h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2>');
19
// Must include code to stop this file being accessed directly
20
if(!defined('WB_PATH')) {
21
	require_once(dirname(dirname(dirname(__FILE__))).'/framework/globalExceptionHandler.php');
22
	throw new IllegalFileException();
23
} else {
24
	$database = WbDatabase::getInstance();
25
	$sError = '';
26
	// Create table
27
	if(!$database->SqlImport(dirname(__FILE__).'/sql/mod_menu_link.sql','',false)){
28
		$sError = $database->get_error();
29
	}
24 30
}
25
/* -------------------------------------------------------- */
26

  
27
$table = TABLE_PREFIX ."mod_menu_link";
28
$database->query("DROP TABLE IF EXISTS `$table`");
29

  
30
$database->query("
31
	CREATE TABLE IF NOT EXISTS `$table` (
32
		`section_id` INT(11) NOT NULL DEFAULT '0',
33
		`page_id` INT(11) NOT NULL DEFAULT '0',
34
		`target_page_id` INT(11) NOT NULL DEFAULT '0',
35
		`redirect_type` INT NOT NULL DEFAULT '301',
36
		`anchor` VARCHAR(255) NOT NULL DEFAULT '0' ,
37
		`extern` VARCHAR(255) NOT NULL DEFAULT '' ,
38
		PRIMARY KEY (`section_id`)
39
	) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci
40
");
branches/2.8.x/wb/modules/menu_link/upgrade.php
4 4
 * @category        modules
5 5
 * @package         menu_link
6 6
 * @author          WebsiteBaker Project
7
 * @copyright       2009-2011, Website Baker Org. e.V.
7
 * @copyright       2009-2012, WebsiteBaker Org. e.V.
8 8
 * @link            http://www.websitebaker2.org/
9 9
 * @license         http://www.gnu.org/licenses/gpl.html
10 10
 * @platform        WebsiteBaker 2.8.x
......
14 14
 * @lastmodified    $Date$
15 15
 *
16 16
 */
17
// Must include code to stop this file being access directly
17

  
18 18
/* -------------------------------------------------------- */
19
if(defined('WB_PATH') == false)
20
{
21
	// Stop this file being access directly
22
		die('<head><title>Access denied</title></head><body><h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2></body></html>');
19
// Must include code to stop this file being accessed directly
20
if(!defined('WB_URL')) {
21
	require_once(dirname(dirname(dirname(__FILE__))).'/framework/globalExceptionHandler.php');
22
	throw new IllegalFileException();
23 23
}
24 24
/* -------------------------------------------------------- */
25 25

  
26
$msg = '';
27
$sTable = TABLE_PREFIX.'mod_menu_link';
28
if(($sOldType = $database->getTableEngine($sTable))) {
29
	if(('myisam' != strtolower($sOldType))) {
30
		if(!$database->query('ALTER TABLE `'.$sTable.'` Engine = \'MyISAM\' ')) {
31
			$msg = $database->get_error();
26
	function mod_menu_link_upgrade($bDebug=false) {
27
		global $OK ,$FAIL;
28
		$database=WbDatabase::getInstance();
29
		$msg = array();
30
		$callingScript = $_SERVER["SCRIPT_NAME"];
31
		// check if upgrade startet by upgrade-script to echo a message
32
		$tmp = 'upgrade-script.php';
33
		$globalStarted = substr_compare($callingScript, $tmp,(0-strlen($tmp)),strlen($tmp)) === 0;
34
// check for missing tables, if true stop the upgrade
35
		$aTable = array('mod_menu_link');
36
		$aPackage = UpgradeHelper::existsAllTables($aTable);
37
		if( sizeof($aPackage) > 0){
38
			$msg[] =  'TABLE '.implode(' missing! '.$FAIL.'<br />TABLE ',$aPackage).' missing! '.$FAIL;
39
			$msg[] = 'Menu_Link upgrade failed'." $FAIL";
40
			if($globalStarted) {
41
				echo '<strong>'.implode('<br />',$msg).'</strong><br />';
42
			}
43
			return ( ($globalStarted==true ) ? $globalStarted : $msg);
44
		} else {
45
			for($x=0; $x<sizeof($aTable);$x++) {
46
				if(($sOldType = $database->getTableEngine($database->TablePrefix.$aTable[$x]))) {
47
					if(('myisam' != strtolower($sOldType))) {
48
						if(!$database->query('ALTER TABLE `'.$database->TablePrefix.$aTable[$x].'` Engine = \'MyISAM\' ')) {
49
							$msg[] = $database->get_error();
50
						} else{
51
							$msg[] = 'TABLE `'.$database->TablePrefix.$aTable[$x].'` changed to Engine = \'MyISAM\''." $OK";
52
						}
53
					} else {
54
						$msg[] = 'TABLE `'.$database->TablePrefix.$aTable[$x].'` has Engine = \'MyISAM\''." $OK";
55
					}
56
				} else {
57
					$msg[] = $database->get_error();
58
				}
59
			}
60
// change table structure
61
			$sTable = $database->TablePrefix.'mod_menu_link';
62
			$sFieldName = 'redirect_type';
63
			$sDescription = "INT NOT NULL DEFAULT '301' AFTER `target_page_id`";
64
			if(!$database->field_modify($sTable,$sFieldName,$sDescription)) {
65
				$msg[] = ''.$database->get_error();
66
			} else {
67
				$msg[] = 'Field ( `redirect_type` ) description has been changed successfully'." $OK";
68
			}
69
// only for upgrade-script
70
			if($globalStarted) {
71
				if($bDebug) {
72
					echo '<strong>'.implode('<br />',$msg).'</strong><br />';
73
				}
74
			}
32 75
		}
76
		$msg[] = 'Menu_Link upgrade successfull finished ';
77
		if($globalStarted) {
78
			echo "<strong>Menu_Link upgrade successfull finished $OK</strong><br />";
79
		}
80
		return ( ($globalStarted==true ) ? $globalStarted : $msg);
33 81
	}
34
} else {
35
	$msg = $database->get_error();
82
// ------------------------------------
83

  
84
$bDebugModus = ((isset($bDebugModus)) ? $bDebugModus : false);
85
// Don't show the messages twice
86
if( is_array($msg = mod_menu_link_upgrade($bDebugModus))) {
87
	echo '<strong>'.implode('<br />',$msg).'</strong><br />';
36 88
}
89

  
37 90
// ------------------------------------
branches/2.8.x/wb/modules/form/install.php
4 4
 * @category        modules
5 5
 * @package         form
6 6
 * @author          WebsiteBaker Project
7
 * @copyright       2009-2011, Website Baker Org. e.V.
8
 * @link			http://www.websitebaker2.org/
7
 * @copyright       2009-2013, Website Baker Org. e.V.
8
 * @link            http://www.websitebaker2.org/
9 9
 * @license         http://www.gnu.org/licenses/gpl.html
10 10
 * @platform        WebsiteBaker 2.8.x
11 11
 * @requirements    PHP 5.2.2 and higher
12
 * @version      	$Id$
13
 * @filesource		$HeadURL$
12
 * @version         $Id$
13
 * @filesource      $HeadURL$
14 14
 * @lastmodified    $Date$
15 15
 *
16 16
 */
......
21 21
	throw new IllegalFileException();
22 22
} else {
23 23
// Create tables
24
	$sError = array();
24
	$aError = array();
25 25
	// Create table
26 26
	if(!$database->SqlImport(dirname(__FILE__).'/sql/form284db.sql','',false)){
27
		$sError[] = $database->get_error();
27
		$aError[] = $database->get_error();
28 28
	}
29 29
}
branches/2.8.x/wb/modules/form/sql/form284db.sql
37 37
  `footer` text{TABLE_COLLATION} NOT NULL,
38 38
  `email_to` text{TABLE_COLLATION} NOT NULL,
39 39
  `email_from` varchar(255){TABLE_COLLATION} NOT NULL DEFAULT '',
40
  `email_fromname` varchar(255){TABLE_COLLATION}) NOT NULL DEFAULT '',
40
  `email_fromname` varchar(255){TABLE_COLLATION} NOT NULL DEFAULT '',
41 41
  `email_subject` varchar(255){TABLE_COLLATION} NOT NULL DEFAULT '',
42 42
  `success_page` text{TABLE_COLLATION} NOT NULL,
43 43
  `success_email_to` text{TABLE_COLLATION} NOT NULL,

Also available in: Unified diff