<?php

/**
 * @package AppBuilderAPI
 * @subpackage examples
 * @author Vitaliy Pitvalo <*****@*****.**>
 * @copyright Copyright (c) 2011, ekreative
 * @version 1.0
 */
include '../api/api.php';
$screen = new AppBuilderAPIListScreen('AppBuilderAPIImageItem');
$screen->addChild(new AppBuilderAPIImageItem('http://fred-test-images-resized.s3.amazonaws.com/21454_Icon.jpeg'));
echo AppBuilderAPI::getScreenResponse($screen);
<?php

include '../api/api.php';
$apps = array(array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1378, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/21454_Icon.jpeg'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1378, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/21454_Icon.jpeg'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1378, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/21454_Icon.jpeg'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'), array('id' => 1386, 'icon' => 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'));
$screen = new AppBuilderAPIAppsScreen('Home', 4);
$screen->setAppsBackground('components/com_appbuilder/assets/images/appbuilder/appscreen-bg.jpg');
$screen->addHomeChild(new AppBuilderAPIIconItem(1386, 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'));
$screen->addHomeChild(new AppBuilderAPIIconItem(1386, 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'));
$screen->addHomeChild(new AppBuilderAPIIconItem(1386, 'http://fred-test-images-resized.s3.amazonaws.com/23362_Icon.png'));
foreach ($apps as $app) {
    $screen->addChild($link = new AppBuilderAPIIconItem($app['id'], $app['icon']));
    $link->setAppLink($app['id']);
}
$screen->addChild($lisnk = new AppBuilderAPIIconItem('sasda', 'http://fred-test-images-resized.s3.amazonaws.com/21454_Icon.jpeg'));
$lisnk->setAppLink(23442);
$data = AppBuilderAPI::getElementAsHTMLObj($screen);
?>
<html>
	<head>
		<style>
			table tr td{
				border: 1px solid coral;
			}
			table{
				float: left;
				border: 3px solid aqua;
			}
			
			
			
		</style>
<?php

/**
 * @package AppBuilderAPI
 * @subpackage examples
 * @author Vitaliy Pitvalo <*****@*****.**>
 * @copyright Copyright (c) 2011, ekreative
 * @version 1.0
 */
include '../api/api.php';
$tab = new AppBuilderAPITab('tab');
$tab->setScreenLink($screen = new AppBuilderAPIListScreen('Home', 4));
$screen->setAppsBackground('components/com_appbuilder/assets/images/appbuilder/appscreen-bg.jpg');
echo AppBuilderAPI::getScreenResponse($tab);
 public function processPostdata()
 {
     $rowData = array();
     $this->getParams();
     $this->getDocKey();
     $fields = JRequest::getVar('columnscache', serialize(array()));
     $fields = unserialize($fields);
     $mainscreen = new AppBuilderAPIListScreen(JRequest::getVar('title'));
     $mainscreen = new AppBuilderAPIListScreen(JRequest::getVar('title'));
     if ($this->docKey) {
         $this->includeZend();
         $this->getSpreadsheetAdapter();
         if (is_array($fields)) {
             foreach ($fields as $value) {
                 $val = JRequest::getVar($value, false);
                 if (is_string($val)) {
                     $rowData[$value] = $val;
                 }
                 if ($value == 'date') {
                     $rowData[$value] = gmdate('d-m-Y H:i:s');
                 }
             }
         }
         if ($this->insertRow($rowData)) {
             $mainscreen->addChild(new AppBuilderAPITextItem('Success'));
         } else {
             $mainscreen->addChild(new AppBuilderAPITextItem('Error, while adding'));
         }
     } else {
         $mainscreen->addChild(new AppBuilderAPITextItem('Error..'));
     }
     return AppBuilderAPI::getScreenAsObj($mainscreen);
 }
<?php

include '../api/api.php';
$app = new AppBuilderAPIApp();
$tab = new AppBuilderAPITab('Home');
$screen = new AppBuilderAPIListScreen('Home');
$screen->addChild(new AppBuilderAPITextItem('some text of this first screen'));
$tab->setScreenLink($screen);
$app->addTab($tab);
$tab = new AppBuilderAPITab('Tab 2');
$screen = new AppBuilderAPIListScreen('Tab 2');
$screen->addChild(new AppBuilderAPITextItem('some text of this second screen'));
$tab->setScreenLink($screen);
$app->addTab($tab);
$tab = new AppBuilderAPITab('Tab 3');
$screen = new AppBuilderAPIListScreen('Tab 3');
$screen->addChild(new AppBuilderAPITextItem('some text of this third screen'));
$tab->setScreenLink($screen);
$app->addTab($tab);
echo AppBuilderAPI::getScreenResponse($app);