本文整理汇总了PHP中heading函数的典型用法代码示例。如果您正苦于以下问题:PHP heading函数的具体用法?PHP heading怎么用?PHP heading使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了heading函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: wol
function wol()
{
if (!extension_loaded('sockets')) {
show_error('La extension "sockets" no esta cargada, debe cargarla para poder usar estas opciones');
}
$this->load->library('rapyd');
$this->rapyd->load('dataform');
$form = new DataForm('supervisor/monitoreo/wol/process');
$form->mac = new inputField('Dirección MAC', 'mac');
$form->mac->append('Ejemplo: 00:01:02:03:04:05');
$form->mac->rule = 'required|mac';
$form->mac->maxlength = 17;
$form->mac->size = 20;
$form->submit('btnsubmit', 'Enviar');
$form->build_form();
if ($form->on_success()) {
$mac = $form->mac->newValue;
$rt = $this->_wol($mac);
if (!$rt) {
$form->error_string = $this->error;
$form->build_form();
$salida = $form->output . br();
} else {
$salida = $form->output . br() . 'Señal enviada satisfactoriamente';
}
} else {
$salida = $form->output;
}
$this->rapyd->jquery[] = '$(".inputnum").numeric(".");';
$data['content'] = $salida;
$data['title'] = heading('Envio de señal de encendido por LAN');
$data['head'] = $this->rapyd->get_head();
$this->load->view('view_ventanas', $data);
}
示例2: testTimesAdded
public function testTimesAdded()
{
echo '<h3>Checking Times</h3>';
$sql = 'SELECT `flighttime`
FROM ' . TABLE_PREFIX . 'pireps
WHERE `accepted`=' . PIREP_ACCEPTED;
$results = DB::get_results($sql);
$this->added_time = 0;
foreach ($results as $row) {
$this->added_time = Util::AddTime($this->added_time, $row->flighttime);
}
heading('Time added, all PIREPS at once');
$this->assertNotEqual(0, $this->added_time);
heading('Time added, pilot by pilot');
// Now calculate by PIREP
$allpilots = PilotData::GetAllPilots();
$total = 0;
foreach ($allpilots as $pilot) {
$p_hours = PilotData::getPilotHours($pilot->pilotid);
$total = Util::AddTime($total, $p_hours);
}
$this->assertNotEqual(0, $total);
heading('Comparing pilot to pilot vs all PIREPS');
$this->assertEqual($total, $this->added_time);
heading('Compare to STAT total hours');
StatsData::UpdateTotalHours();
$this->assertEqual($total, StatsData::TotalHours());
echo '<br />';
}
示例3: predict
function predict($opponentCode)
{
$this->data['ResultsHeading'] = heading("Results", 2, 'class="text-center bg-danger"');
//---- get PIT overall average and get PIT last 5 games average
//Our Team
$ourCode = "PIT";
$steelersStandings = $this->teams->getFromCode($ourCode);
$overallAvg = $steelersStandings->Pct1;
//----end get PIT overall average and last 5 games
$this->load->model('scores');
$lastFive = $this->scores->getAvgLast5($ourCode);
///--------Predict our points
$avgAgainstOpponent = $this->scores->getAvgLast5Opponent($ourCode, $opponentCode);
if ($avgAgainstOpponent == 0) {
$pointsUs = (0.7 * $overallAvg + 0.2 * $lastFive) / 0.9;
} else {
$pointsUs = 0.7 * $overallAvg + 0.2 * $lastFive + 0.1 * $avgAgainstOpponent;
}
$ourTeam = array('TeamName' => $ourCode, 'AveragePts' => $pointsUs);
$this->data['OurTeamArray'] = $ourTeam;
///---------end Prediction for Our Team
/////------------Predict Opponent points
$opponentStandings = $this->teams->getFromCode($opponentCode);
$overallOpponentAvg = $opponentStandings->Pct1;
$lastFiveOpponent = $this->scores->getAvgLast5($opponentCode);
//different when standings updated
$avgAgainstUs = $this->scores->getAvgLast5Opponent($opponentCode, $ourCode);
if ($avgAgainstUs == 0) {
$pointsOpponent = (0.7 * $overallOpponentAvg + 0.2 * $lastFiveOpponent) / 0.9;
} else {
$pointsOpponent = 0.7 * $overallOpponentAvg + 0.2 * $lastFiveOpponent + 0.1 * $avgAgainstUs;
}
$opponent = array('TeamName' => $opponentCode, 'AveragePts' => $pointsOpponent);
$this->data['OpponentArray'] = $opponent;
}
示例4: filteredgrid
function filteredgrid()
{
$this->pi18n->cargar('i18n', 'dataedit');
$this->rapyd->load('datafilter', 'datagrid');
$this->rapyd->uri->keep_persistence();
$this->pi18n->msj('rifci', 'RIF o C.I.');
$filter = new DataFilter('Filtro', 'i18n');
$filter->modulo = new inputField('Módulo', 'modulo');
$filter->modulo->size = 20;
$filter->buttons('reset', 'search');
$filter->build();
$uri = anchor('supervisor/i18n/dataedit/modify/<#id#>', '<#id#>');
$grid = new DataGrid('Internacionalización');
$grid->order_by('id', 'asc');
$grid->per_page = 20;
$grid->column_orderby('ID', $uri, 'id');
$grid->column_orderby('Modulo', 'modulo', 'modulo');
$grid->column_orderby('Método', 'metodo', 'metodo');
$grid->column_orderby('País', 'pais', 'pais');
$grid->column_orderby('Campo', 'campo', 'campo');
$grid->add('supervisor/i18n/dataedit/create');
$grid->build();
$data['content'] = $filter->output . $grid->output;
$data['content'] .= $this->pi18n->fallas();
$data['title'] = heading('Internacionalización');
$data['head'] = $this->rapyd->get_head();
$this->load->view('view_ventanas', $data);
}
示例5: dataedit
function dataedit()
{
$this->rapyd->load('dataedit');
$this->rapyd->uri->keep_persistence();
$edit = new DataEdit('Cheque emitido', 'bmov');
$status = $edit->_status;
if ($status != 'show') {
show_error('Error de parámetros');
}
$edit->back_url = site_url('finanzas/conforch/filteredgrid');
$edit->fecha = new DateonlyField('Fecha', 'fecha', 'd/m/Y');
$edit->fecha->insertValue = date('Y-m-d');
$edit->benefi = new inputField('A nombre de', "benefi");
$edit->benefi->group = 'Detalle del cheque';
$edit->banco = new inputField("Del Banco", "banco");
$edit->banco->group = 'Detalle del cheque';
$edit->numcuent = new inputField("Número Cuenta", "numcuent");
$edit->numcuent->in = 'banco';
$edit->numcuent->group = 'Detalle del cheque';
$edit->numero = new inputField("Número de cheque", "numero");
$edit->numero->group = 'Detalle del cheque';
$edit->monto = new inputField("Por un Monto de", "monto");
$edit->monto->group = 'Detalle del cheque';
$edit->nombre = new inputField('Proveedor', 'nombre');
$edit->concepto = new inputField("Por Concepto", "concepto");
$edit->anulado = new inputField("Anulado", "anulado");
$edit->buttons('back');
$edit->build();
$data['content'] = $edit->output;
$data['title'] = heading('Consulta de Cheques');
$data['head'] = $this->rapyd->get_head();
$this->load->view('view_ventanas', $data);
}
示例6: filteredgrid
function filteredgrid()
{
$this->rapyd->uri->keep_persistence();
$this->rapyd->load('datafilter', 'datagrid');
$filter = new DataFilter('', 'gpt_pro');
$filter->parr = new inputField('Parámetro', 'parr');
$filter->parr->rule = 'trim|required';
$filter->parr->clause = '';
//$filter->submit = new submitField('Buscar', 'submitbtn');
//$filter->submit->in='parr';
$filter->buttons('reset', 'search');
$filter->build();
$uri = anchor($this->url . 'dataedit/show/<raencode><#id_pro#></raencode>', '<#nom_pro#>', 'target="framedetrepo" onclick="$(\'#cajafiltro\').hide();"');
//$uri = anchor($this->url.'dataedit/show/<raencode><#id_pro#></raencode>','<#nom_pro#>');
$grid = new DataGrid('Especialidades farmaceuticas');
if (strlen($filter->parr->newValue) > 0) {
$dbparr = $this->db->escape($filter->parr->newValue);
$grid->db->where('MATCH(nom_pro,pres_pro,lab_pro,gen_pro,mono_pro) AGAINST (' . $dbparr . ')');
}
$grid->order_by('nom_pro');
$grid->per_page = 15;
$grid->column_orderby('Nombre', $uri, 'nom_pro', 'align="left"');
$grid->column_orderby('Presentación', 'pres_pro', 'pres_pro', 'align="left"');
$grid->column_orderby('Laboratorio', 'lab_pro', 'lab_pro', 'align="left"');
//$grid->column_orderby('Cod. Pro','cod_pro','cod_pro','align="left"');
//$grid->column_orderby('Gen. Pro','gen_pro','gen_pro','align="left"');
$grid->build();
$data['filtro'] = $filter->output . $grid->output;
$data['content'] = '<script type="text/javascript"> $(function(){ $("#cajafiltro").show(); }); </script>';
//$data['content'].= $acti->output;
$data['content'] .= '<IFRAME src="' . site_url('farmacia/gpt_pro/dummy') . '" width="100%" height="500" scrolling="auto" frameborder="0" name="framedetrepo">iframe no son soportados</IFRAME>';
$data['head'] = $this->rapyd->get_head() . script('jquery.js') . script('jquery.highlight.js');
$data['title'] = heading($this->titp);
$this->load->view('view_ventanas', $data);
}
示例7: dataedit
function dataedit()
{
$this->rapyd->load('dataedit');
$edit = new DataEdit($this->tits, 'edifubica');
$edit->back_url = site_url($this->url . 'filteredgrid');
$edit->post_process('insert', '_post_insert');
$edit->post_process('update', '_post_update');
$edit->post_process('delete', '_post_delete');
$edit->pre_process('insert', '_pre_insert');
$edit->pre_process('update', '_pre_update');
$edit->pre_process('delete', '_pre_delete');
$edit->id_edif = new dropdownField('Edificación', 'id_edif');
$edit->id_edif->option('', 'Seleccionar');
$edit->id_edif->options('SELECT id,TRIM(nombre) AS nombre FROM edif ORDER BY nombre');
$edit->id_edif->rule = 'max_length[11]';
$edit->descripcion = new inputField('Descripción', 'descripcion');
$edit->descripcion->rule = 'max_length[50]';
$edit->descripcion->size = 52;
$edit->descripcion->maxlength = 50;
$edit->buttons('modify', 'save', 'undo', 'delete', 'back', 'add');
$edit->build();
$data['content'] = $edit->output;
$data['head'] = $this->rapyd->get_head();
$data['title'] = heading($this->tits);
$this->load->view('view_ventanas', $data);
}
示例8: database
/**
* database function.
*
* @access public
* @return void
*/
public function database()
{
$this->output->enable_profiler(true);
$this->load->database();
$this->load->dbutil();
$this->load->dbforge();
$data['title'] = $this->system_model->get('app_name');
$data['breadcrumbs'] = array(array('data' => anchor('/', $this->system_model->get('app_name')), 'mode' => 'unavailable'), array('data' => anchor('install', ucfirst(lang('install'))), 'mode' => 'unavailable'), array('data' => anchor('install/database', ucfirst(lang('install') . ' ' . lang('database'))), 'mode' => 'current'));
$html = heading(ucfirst(lang('install')) . ' ' . lang('database'), 1);
$current = $this->migration->current();
if (is_null($current)) {
$html .= div($this->migration->error_string(), 'alert-box error');
} else {
$html .= div('Klubb database version: ' . $current, 'alert-box success');
}
$tables = $this->db->list_tables();
foreach ($tables as $table) {
$fields = $this->db->list_fields($table);
array_unshift($fields, strong('Fält:'));
$fields = ul($fields, array('class' => 'inline-list'));
$html .= div(heading('Tabell: ' . $table, 4) . $fields, 'radius panel');
}
$data['html'] = $html;
$this->system_model->view('template', $data);
}
示例9: index
function index()
{
$this->rapyd->load('dataform');
$filter = new dataForm('buscador/index/procesar');
$filter->valor = new inputField('Valor', 'valor');
$filter->valor->rule = 'required';
$filter->valor->size = 20;
$filter->submit('btnsubmit', 'Buscar');
$filter->build_form();
$sal = '';
if ($filter->on_success()) {
$this->load->library('table');
$this->table->set_heading('Tabla', 'Campo', 'Coincidencias');
$valor = $this->db->escape($filter->valor->newValue);
$tables = $this->db->list_tables();
foreach ($tables as $table) {
$fields = $this->db->list_fields($table);
foreach ($fields as $field) {
$mSQL = "SELECT COUNT(*) AS cana FROM `{$table}` WHERE `" . $field . "` = {$valor}";
$cana = $this->datasis->dameval($mSQL);
if ($cana > 0) {
$this->table->add_row($table, $field, $cana);
}
}
}
$sal = $this->table->generate();
}
$data['content'] = $filter->output . $sal;
$data['title'] = heading('Busca un valor en toda la base de datos');
$data['head'] = $this->rapyd->get_head();
$this->load->view('view_ventanas', $data);
}
示例10: filteredgrid
function filteredgrid()
{
$this->rapyd->load('dataform', 'datagrid');
$this->load->library('encrypt');
$filter = new DataForm('ejecutasql/filteredgrid/process');
$filter->sql = new textareaField('', 'sql');
$filter->sql->cols = 90;
$filter->sql->rows = 9;
$filter->sql->rule = 'required';
$filter->submit('btnsubmit', 'Ejecutar');
$filter->build_form();
$salida = '';
if ($filter->on_success()) {
$data = array();
$mSQL = $filter->sql->value;
$link = @mysql_connect($this->db->hostname, $this->db->username, $this->db->password) or die('Error de coneccion');
mysql_select_db($this->db->database, $link) or die('Base de datos no seleccionable');
$result = mysql_query($mSQL, $link);
if (!$result) {
$salida = mysql_errno($link) . ": " . mysql_error($link);
} else {
if (is_resource($result)) {
$num_rows = mysql_num_rows($result);
$afectados = 0;
} elseif (is_bool($result)) {
$num_rows = 0;
$afectados = mysql_affected_rows();
} else {
$num_rows = 0;
$afectados = 0;
}
if ($num_rows > 0) {
$colunas = mysql_num_fields($result);
while ($row = mysql_fetch_assoc($result)) {
$data[] = $row;
}
$grid = new DataGrid("Filas : {$num_rows}, Columnas : {$colunas} ,Afectados :{$afectados}", $data);
$grid->per_page = 100000;
foreach ($data[0] as $campos => $value) {
$grid->column($campos, $campos);
}
$grid->build();
$salida = $grid->output;
if (stristr($mSQL, 'SELECT')) {
$mSQL2 = $this->encrypt->encode($mSQL);
$salida .= "<form action='/../../proteoerp/xlsauto/repoauto2/'; method='post'>\n \t\t\t\t\t\t<input size='100' type='hidden' name='mSQL' value='{$mSQL2}'>\n \t\t\t\t\t\t<input type='submit' value='Descargar a Excel' name='boton'/>\n \t\t\t\t\t\t</form>";
}
} elseif ($afectados > 0) {
$salida = "Filas afectadas {$afectados}";
} else {
$salida = 'Esta consulta no genero resultados';
}
}
}
$data['content'] = $filter->output . $salida;
$data['title'] = heading('Consulta SQL');
$data['head'] = $this->rapyd->get_head();
$this->load->view('view_ventanas', $data);
}
示例11: heading_nb_level2
function heading_nb_level2($l1tag, $l1url, $l2tag, $l2url)
{
global $site, $siteuri;
echo "<a href='{$siteuri}'>";
heading($site . " < " . $l1tag . " < " . $l2tag);
nb_top();
nb_level2($l1tag, $l1url, $l2tag, $l2url);
}
示例12: print_logr
function print_logr()
{
global $env, $logr;
if ($env == 'test') {
heading('Log');
print_r($logr);
}
}
示例13: index
function index()
{
$this->rapyd->load('dataform', 'datatable', 'datagrid');
$this->load->library('table');
$base_process_uri = $this->rapyd->uri->implode_uri("base_uri", "gfid", "orderby");
$filter = new DataForm($this->rapyd->uri->add_clause($base_process_uri, "search"));
$filter->title('Elija una tabla');
$filter->attributes = array('onsubmit' => 'is_loaded()');
$filter->tabla = new dropdownField("Tabla", "tabla");
$filter->tabla->option("pers", "Personal");
$filter->tabla->option("nomina", "Nomina");
$filter->tabla->option("sprv", "Proveedores");
$filter->tabla->option("abonotros", "Abono Otros");
$filter->tabla->clause = "";
//$filter->obra = new dropdownField("Obra", "depto");
//$filter->obra->db_name='depto';
//$filter->obra->clause="where";
//$filter->obra->option(" ","Todos");
//$filter->obra->options("SELECT depto, descrip FROM dpto ORDER BY depto ");
//$filter->obra->operator="=";
//$filter->status = new dropdownField("Status","status");
//$filter->status->option("","Todos");
//$filter->status->option("A","Activos");
//$filter->status->option("I","Inactivos");
//$filter->status->style='width:100px';
$filter->submit('btnsubmit', 'Descargar');
$filter->build_form();
if ($this->rapyd->uri->is_set("search")) {
$table = $filter->tabla->newValue;
$mSQL = "DESCRIBE {$table}";
$query = $this->db->query($mSQL);
if ($query->num_rows() > 0) {
foreach ($query->result_array() as $row) {
$data[] = $row;
}
}
function ractivo($field)
{
$data2 = array('name' => 'campos[]', 'id' => 'c' . $field, 'value' => $field, 'checked' => FALSE, 'style' => 'margin:5px');
$retorna = form_checkbox($data2);
return $retorna;
}
$grid = new DataGrid("Resultados", $data);
$grid->use_function('ractivo', 'ucwords');
$grid->column('Campos', '<ucwords><#Field#></ucwords>');
$grid->column('Mostrar', "<ractivo><#Field#></ractivo>", 'align="center"');
$grid->build();
$tabla = $grid->output;
$filter->build_form();
$conten = $filter->output . form_open("nomina/rpers/crear/{$table}") . $tabla . form_submit('mysubmit', 'Generar') . form_close();
} else {
$conten = $filter->output;
}
$data['content'] = $conten;
$data['title'] = heading('Reporte');
$data["head"] = script("jquery.js") . $this->rapyd->get_head();
$this->load->view('view_ventanas', $data);
}
示例14: index
function index()
{
$data = array();
$data['header'] = '';
$data['content'] = $this->load->view('view_verificador', $data, true);
$data['footer'] = '';
$data['script'] = script('jquery-min.js');
$data['script'] .= phpscript('nformat.js');
$data['script'] .= script('jquery.bootgrid.min.js');
$data['style'] = style('jquery.bootgrid.min.css');
$data['panel'] = '';
$data['title'] = heading('Verificador de precios');
$this->load->view('view_ventanasjq', $data);
/*
// Filter grid
$this->rapyd->load('datafilter','datagrid');
$filter = new DataFilter('Consulta de Precios', 'sinv');
$filter->Descripcion = new inputField('Descripcion','decrip');
$filter->clave->rule ='max_length[50]';
$filter->clave->size =7;
$filter->clave->maxlength =5;
$filter->marca = new inputField('Marca','marca');
$filter->marca->rule ='max_length[30]';
$filter->marca->size =32;
$filter->marca->maxlength =30;
$filter->buttons('reset', 'search');
$filter->build();
$uri = anchor($this->url.'dataedit/show/<raencode><#id#></raencode>','<#id#>');
$grid = new DataGrid('');
$grid->db->select('codigo', 'descrip','unidad','base1','precio1-base1 iva','precio1');
$grid->db->order_by('codigo');
$grid->db->order_by('codigo');
$grid->per_page = 40;
$grid->column_orderby('Código' ,'codigo' ,'codigo', 'align="left"');
$grid->column_orderby('Descripcion' ,'nombre' ,'descrip', 'align="left"');
$grid->column_orderby('Medida' ,'unidad' ,'unidad', 'align="left"');
$grid->column_orderby('Precio' ,'base1' ,'base1', 'align="right"');
$grid->column_orderby('I.V.A.' ,'iva' ,'iva', 'align="right"');
$grid->column_orderby('Precio de Venta' ,'precio1' ,'precio1', 'align="right"');
$grid->add($this->url.'dataedit/create');
$grid->build();
$data['filtro'] = $filter->output;
$data['content'] = $grid->output;
$data['head'] = $this->rapyd->get_head().script('jquery.min.js');
$data['title'] = heading($this->titp);
$this->load->view('view_ventanas', $data);
*/
}
示例15: testFindSchedules
public function testFindSchedules()
{
heading('findSchedules');
$data = SchedulesData::findSchedules(array());
$this->assertNotEqual($data, false);
heading('Find disabled schedules');
$data = SchedulesData::findSchedules(array('s.enabled' => 0));
$this->assertNotEqual($data, false);
}