Beispiel #1
0
 public static function lang($constant, $autoreturn = true)
 {
     return Oraculum_Text::t('LANG_' . strtoupper($constant), $autoreturn);
 }
Beispiel #2
0
function plural($palavra)
{
    return Oraculum_Text::plural($palavra);
}
Beispiel #3
0
<div id="content">
    <em>Oraculum Framework :: <?php 
echo $_SERVER['SERVER_NAME'];
?>
</em>
<p>
<?php 
/*
	Abaixo ocorre a mesma coisa que no inicio,
	e' carregado o modulo Oraculum_Text
*/
Oraculum::Load('Text');
?>
<br />
<?php 
echo Oraculum_Text::saudacao();
?>
 nobre desenvolvedor!<br />
Voc&ecirc; est&aacute; agora sendo apresentado a uma aplica&ccedil;&atilde;o modelo,
desenvolvida inteiramente com o Oraculum Framework para que voc&ecirc; possa
entender de forma uma forma mais simples poss&iacute;vel o seu funcionamento.<br /><br />
Sinta-se &agrave; vontade para explorar os c&oacute;digos e fazer altera&ccedil;&otilde;es
para se familiarizar com este novo ambiente de desenvolvimento.<br /><br />

Qualquer d&uacute;vida acesse o site oficial do projeto e entre em contato:<br />
<a href="http://oraculumframework.org/" target="_blank">
http://oraculumframework.org/</a><br /><br />

Oraculum Framework<br />
<em>Um novo conceito em desenvolvimento Web</em>
</p>
Beispiel #4
0
 public function generate()
 {
     if (sizeof($this->_table) > 0) {
         foreach ($this->_table as $reg) {
             $id = NULL;
             if (is_object($reg)) {
                 $reg = $reg->getFieldList();
             }
             if (is_array($reg)) {
                 if (is_null($this->_grid)) {
                     $this->_grid .= '<table class="' . $this->_tableclass . '">';
                     $this->_grid .= '<thead>';
                     $this->_grid .= '<tr>';
                     if (sizeof($this->_headers) > 0) {
                         foreach ($this->_headers as $header) {
                             $this->_grid .= '<th>';
                             $this->_grid .= $header;
                             $this->_grid .= '</th>';
                         }
                     } else {
                         foreach ($reg as $field => $value) {
                             $this->_grid .= '<th>';
                             $this->_grid .= ucwords($field);
                             $this->_grid .= '</th>';
                         }
                     }
                     if ($this->_showactions) {
                         $this->_grid .= '<th>';
                         $this->_grid .= $this->_actionstitle;
                         $this->_grid .= '</th>';
                     }
                     $this->_grid .= '</tr>';
                     $this->_grid .= '</thead>';
                     $this->_grid .= '<tbody>';
                 }
                 $this->_grid .= '<tr>';
                 if (sizeof($this->_fields) > 0) {
                     if ($this->_base64id) {
                         $id = base64_encode($reg[$this->_keyfield]);
                     } else {
                         $id = $reg[$this->_keyfield];
                     }
                     foreach ($this->_fields as $field) {
                         //$id=(is_null($id))?$reg[$field]:$id;
                         $this->_grid .= '<td>';
                         if (in_array($field, $this->_dtfields)) {
                             if (method_exists('Oraculum_Text', 'data')) {
                                 $reg[$field] = Oraculum_Text::datahora($reg[$field]);
                             }
                         }
                         $this->_grid .= $reg[$field];
                         $this->_grid .= '</td>';
                     }
                 } else {
                     if ($this->_base64id) {
                         $id = base64_encode($reg[$this->_keyfield]);
                     } else {
                         $id = $reg[$this->_keyfield];
                     }
                     foreach ($reg as $field => $value) {
                         $id = is_null($id) ? $this->_base64id ? base64_encode($value) : $value : $id;
                         $this->_grid .= '<td>';
                         $this->_grid .= $value;
                         $this->_grid .= '</td>';
                     }
                 }
                 if ($this->_showactions) {
                     $this->_grid .= '<td>';
                     if (in_array('update', $this->_actions)) {
                         $this->_grid .= '<a href="' . str_replace('%id%', $id, $this->_updateurl) . '" class="' . $this->_updateclass . '" ' . $this->_aditionalupdatelink . '>' . $this->_updatelabel . '</a> ';
                     }
                     if (in_array('delete', $this->_actions)) {
                         $this->_grid .= '<a href="' . str_replace('%id%', $id, $this->_deleteurl) . '" class="' . $this->_deleteclass . '" ' . $this->_aditionaldeletelink . '>' . $this->_deletelabel . '</a>';
                     }
                     $this->_grid .= str_replace('%id%', $id, $this->_adicionalactionhtml);
                     $this->_grid .= '</td>';
                 }
                 $this->_grid .= '</tr>';
             }
         }
         $this->_grid .= '</tbody>';
         $this->_grid .= '</table>';
     } else {
         $this->_grid = $this->_norecordsfound;
     }
     return $this->_grid;
 }