Multi language
Simple Ajax mode
No HTML, no JavaScript
URL rewriting
Mail sending
Sitemap - RSS - Web service
 


Loading
 


Framework PHP

Framework PHP


Home Home


Documentation Documentation

Download Download


Contact Contact


 
HelpHelp

Quick start Quick start


Help videos Help videos


Tutorials Tutorials


Wiki Wiki
Issue Tracker Issue Tracker
Eclipse PHP Eclipse PHP


 
LanguagesLanguages




 
SupportSupport

 
CompatibilitiesCompatibilities




 
ComponentsComponents

jQuery
CkEditor

 
Tutorial TableTutorials > Tutorial Table


Tutorial 1 : Simple Table
<?php
class Table01 extends Page {
    public function 
InitializeComponent() {
        
parent::$PAGE_TITLE "Tutorial : Simple Table";
        
        
$this->render = new Table();
        
$this->render->setBorder(1);
        
$this->render->addRowColumns("row1 col1""row1 col2");
        
$this->render->addRowColumns("row2 col1""row2 col2");
        
$this->render->addRowColumns("row2 col1""row3 col2");
    }
}
?>


Tutorial 2 : Complex Table
<?php
class Table02 extends Page {
    public function 
InitializeComponent() {
        
parent::$PAGE_TITLE "Tutorial : Complex Table";
        
        
$this->render = new Table();
        
$this->render->setBorder(1);
        
        
$row1 $this->render->addRowColumns("1-1+2""1-3""1-4");
        
$row1->setColumnColspan(12);
        
        
$this->render->addRowColumns("2-1""2-2""2-3""2-4");
        
        
$row3 $this->render->addRowColumns("3-1""3-2"
                                            
"3-3""3-4");
        
$row3->setColumnRowspan(32);
        
        
$this->render->addRowColumns("4-1""4-2""4-4");
    }
}
?>


Tutorial 3 : Complex Table with style
<?php
class Table03 extends Page {
    public function 
InitializeComponent() {
        
parent::$PAGE_TITLE "Tutorial : Complex Table 
                                with style"
;
        
        
$this->render = new Table();
        
$this->render->setBorder(1)->setWidth("200px");
        
        
$row1 = new RowTable(RowTable::ALIGN_CENTER);
        
$row1->add("1-1+2")->add("1-3")->add("1-4");
        
$row1->setColumnColspan(12);
        
$this->render->addRow($row1);
        
        
$row2 = new RowTable(RowTable::ALIGN_CENTER"50px");
        
$row2->add("2-1")->add("2-2")->add("2-3")->add("2-4");
        
$this->render->addRow($row2);
        
        
$row3 $this->render->addRowColumns("3-1""3-2"
                                            
"3-3""3-4");
        
$row3->setColumnRowspan(32);
        
$row3->setColumnStyle(2"background-color: red;");
        
        
$this->render->addRowColumns("4-1""4-2""4-4");
    }
}
?>


Tutorial 4 : Advance Table
<?php
class Table04 extends Page {
    public function 
InitializeComponent() {
        
parent::$PAGE_TITLE "Tutorial : Advance Table";
        
        
$this->render = new Table();
        
$this->render->setId("users_table_04");
        
$this->render->activateAdvanceTable();
        
$this->render->setWidth(400);
        
        
$header $this->render->addRowColumns("Name""Login""Email");
        
$header->setHeaderClass(0);
        
        
$this->render->addRowColumns("Toto""toto""toto@toto.com");
        
$this->render->addRowColumns("Tata""tata""tata@tata.com");
        
$this->render->addRowColumns("Titi""titi""titi@titi.com");
        
$this->render->addRowColumns("Aaaa""aaaa""aaaa@aaaa.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
    }
}
?>


Tutorial 5 : Advance Tablewith more properties
<?php
class Table05 extends Page {
    public function 
InitializeComponent() {
        
parent::$PAGE_TITLE "Tutorial : Advance Table
                                with more properties"
;
        
        
$this->render = new Table();
        
$this->render->setId("users_table_05");
        
$this->render->activateAdvanceTable();
        
$this->render->setWidth(500);
        
        
$this->render->activateSort(1);
        
$this->render->activateSearch();
        
$this->render->activatePagination(10);
        
$this->render->activateAdvanceTableInfo();
        
        
$header $this->render->addRowColumns("Name""Login""Email");
        
$header->setHeaderClass(0);
        
        
$this->render->addRowColumns("Toto""toto""toto@toto.com");
        
$this->render->addRowColumns("Tata""tata""tata@tata.com");
        
$this->render->addRowColumns("Titi""titi""titi@titi.com");
        
$this->render->addRowColumns("Aaaa""aaaa""aaaa@aaaa.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
        
$this->render->addRowColumns("Zzzz""zzzz""zzzz@zzzz.com");
    }
}
?>



Share




Copyright © 2009-2012 WebSite-PHP Framework PHP
Home Documentation Download Quick start Tutorials Wiki Issue Tracker
Site created with framework WebSite-PHP