本文整理汇总了PHP中img函数的典型用法代码示例。如果您正苦于以下问题:PHP img函数的具体用法?PHP img怎么用?PHP img使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了img函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: input
public function input($fieldKey, $fieldData)
{
$inputTaget = $this->CI->form->protection($fieldKey) . '-select-picasa';
$value = $fieldData->value ? $fieldData->value : '';
$photo = $this->CI->picasa->parkornCache($fieldData->value);
// exit('call me here');
if ($photo && isset($photo->src)) {
$img = img($this->CI->picasa->thumb($photo->src, 110), FALSE, 'width=110');
} else {
$img = null;
}
// if( isset($fieldData->user) && $fieldData->user ){
// $script.= " user = '".$fieldData->user."';";
// }
// if( isset($fieldData->album) && $fieldData->album ){
// $script.= "picasa.album = '".$fieldData->album."';";
// }
$input = '<div class="pcs-imgs" name="' . $this->CI->form->protection($fieldKey) . '" ' . (isset($fieldData->user) && $fieldData->user ? 'user="' . $fieldData->user . '"' : null) . (isset($fieldData->album) && $fieldData->album ? 'albumid="' . $fieldData->album . '"' : null) . '>' . '<input type="text" class="uniform" style="display: none;" value=\'' . $value . '\' name="' . $this->CI->form->protection($fieldKey) . '">' . '<span class="img" name="select-img" style="-moz-user-select: none;" ' . ($photo && isset($photo->src) ? 'photoid=' . $photo->id : '') . '>' . ($value == '' ? 'Choose File' : $img) . '</span>' . '</div>';
$script = '';
$script .= "" . 'picasa.inputname = $("input[type=text][name=' . $this->CI->form->protection($fieldKey) . ']");';
if ($this->CI->template && $script) {
$this->CI->template->add_js_ready($script);
}
return $input;
}
开发者ID:quanict,项目名称:parkornleather,代码行数:25,代码来源:picasa.php
示例2: uploads
function uploads($config)
{
$this->load->library('upload', $config);
// підключаєм бібліотеку загрузки файлів
unset($config);
// чистим переміну
if ($this->upload->do_upload()) {
// функція загрузки файлів
$upload_data = $this->upload->data();
// масив даних
$add['title'] = $this->input->post('title');
$add['file_name'] = $upload_data['file_name'];
// назва в бд
$add['date'] = date("Y-m-d");
$this->db->insert('photos', $add);
// запис в бд
$config = array('image_library' => 'gd2', 'source_image' => $upload_data['full_path'], 'new_image' => APPPATH . '../uploads/img/photos/thumbs', 'create_thumb' => TRUE, 'maintain_ratio' => TRUE, 'width' => '80', 'heigth' => '80');
$this->load->library('image_lib', $config);
$this->image_lib->resize();
$this->load->helper('html');
$data['img'] = img('uploads/img/photos/thumbs/' . $upload_data['raw_name'] . '_thumb' . $upload_data['file_ext']);
$data['success'] = '<p class="text-success">Файл успішно завантажений</p>';
} else {
$upload_error = $this->upload->display_errors('<p class="text-danger">', '</p>');
// вивід помилок
$data['error'] = $upload_error;
// передаєм помилку
}
return $data;
}
开发者ID:BeerMan88,项目名称:codeigniter,代码行数:30,代码来源:upload_model.php
示例3: jqdatag
function jqdatag()
{
$grid = $this->defgrid();
$param['grids'][] = $grid->deploy();
//Funciones que ejecutan los botones
$bodyscript = $this->bodyscript($param['grids'][0]['gridname']);
$readyLayout = $grid->readyLayout2(216, 135, $param['grids'][0]['gridname']);
$WpAdic = "\n\t\t<tr><td><div class=\"anexos\">\n\t\t\t<table cellpadding='0' cellspacing='0'>\n\t\t\t\t<tr>\n\t\t\t\t\t<td style='vertical-align:top;'><div class='botones'><a style='width:94px;text-align:left;vertical-align:top;' href='#' id='gmarcas'>" . img(array('src' => "images/tux1.png", 'height' => 15, 'alt' => 'Crear Marcas', 'title' => 'Crear Marcas', 'border' => '0')) . "+Marcas</a></div></td>\n\t\t\t\t\t<td style='vertical-align:top;'><div class='botones'><a style='width:94px;text-align:left;vertical-align:top;' href='#' id='gunidad'>" . img(array('src' => "images/unidad.gif", 'height' => 15, 'alt' => 'Crear Unidades', 'title' => 'Crear Unidades', 'border' => '0')) . "+Unidad</a></div></td>\n\t\t\t\t</tr>\n\t\t\t\t<tr>\n\t\t\t\t\t<td style='vertical-align:top;'><div class='botones'><a style='width:94px;text-align:left;vertical-align:top;' href='#' id='hinactivo'>" . img(array('src' => "images/basura.png", 'height' => 15, 'alt' => 'Mostrar/Ocultar Inactivos', 'title' => 'Mostrar/Ocultar Inactivos', 'border' => '0')) . "Inactivos</a></div></td>\n\t\t\t\t\t<td style='vertical-align:top;'><div class='botones'><a style='width:94px;text-align:left;vertical-align:top;' href='#' id='bbarras' >" . img(array('src' => "images/barcode.png", 'height' => 15, 'alt' => 'Barras Adicionales', 'title' => 'Barras Adicionales', 'border' => '0')) . "Barras</a></div></td>\n\t\t\t\t</tr>\n\t\t\t\t<tr>\n\t\t\t\t\t<td style='vertical-align:top;' colspan='2'><div class='botones'><a style='width:190px;text-align:left;vertical-align:top;' href='#' id='subica'>" . img(array('src' => "images/ojo.png", 'height' => 15, 'alt' => 'Ubicaciones', 'title' => 'Ubicaciones', 'border' => '0')) . "Ubicaciones</a></div></td>\n\t\t\t\t</tr>";
if ($this->datasis->traevalor('SUNDECOP') == 'S') {
$WpAdic .= "\n\t\t\t\t<tr>\n\t\t\t\t\t<td style='vertical-align:top;'><div class='botones'><a style='width:94px;text-align:left;vertical-align:top;' href='#' id='sundecop'>" . img(array('src' => "images/sundecop.jpeg", 'height' => 15, 'alt' => 'Parametros SUNDECOP', 'title' => 'Parametros SUNDECOP', 'border' => '0')) . "SuNdeCoP</a></div></td>\n\t\t\t\t\t<td style='vertical-align:top;'><div class='botones'><a style='width:94px;text-align:left;vertical-align:top;' href='#' id='bpactivo'>" . img(array('src' => "images/lab.png", 'height' => 15, 'alt' => 'Crear Unidades', 'title' => 'Crear Unidades', 'border' => '0')) . "P.Activo</a></div></td>\n\t\t\t\t</tr>\n\t\t\t";
}
$WpAdic .= "\n\t\t\t</table>\n\t\t\t</div>\n\t\t</td></tr>\n\n\t\t";
$grid->setWpAdicional($WpAdic);
$WestPanel = $grid->deploywestp();
$adic = array(array('id' => 'fedita', 'title' => 'Agregar/Editar Registro'), array('id' => 'fborra', 'title' => 'Eliminar registro'), array('id' => 'fshow', 'title' => 'Varios'));
$SouthPanel = $grid->SouthPanel($this->datasis->traevalor('TITULO1'), $adic);
$link2 = site_url('inventario/sinv/recalcular');
$funciones = $this->funciones($param['grids'][0]['gridname']);
//Panel Central y Sur
$centerpanel = $grid->centerpanel($id = 'radicional', $param['grids'][0]['gridname']);
$param['script'] = script('sinvmaes.js');
$param['WestPanel'] = $WestPanel;
$param['funciones'] = $funciones;
$param['readyLayout'] = $readyLayout;
$param['centerpanel'] = $centerpanel;
$param['SouthPanel'] = $SouthPanel;
$param['listados'] = $this->datasis->listados('SINV', 'JQ');
$param['otros'] = $this->datasis->otros('SINV', 'JQ');
$param['temas'] = array('proteo', 'darkness', 'anexos');
$param['bodyscript'] = $bodyscript;
$param['tabs'] = false;
$param['encabeza'] = $this->titp;
$this->load->view('jqgrid/crud2', $param);
}
开发者ID:codethics,项目名称:proteoerp,代码行数:34,代码来源:sinv.php
示例4: filter
public function filter()
{
$string = '%' . $this->input->post('string') . '%';
$a = array();
if ($string) {
$a = User::find('all', array('conditions' => array('nombre LIKE ? OR apellido LIKE ? OR usuario LIKE ?', $string, $string, $string)));
} else {
$a = User::find('all');
}
$this->table->set_heading('Usuario', 'Nombre', 'Apellido', 'Teléfono', 'Celular', 'Email', 'Dirección', 'Acciones');
foreach ($a as $al) {
$this->table->add_row($al->usuario, $al->nombre, $al->apellido, $al->telefono, $al->celular, $al->email, $al->direccion, anchor('usuarios/ver/' . $al->id, img('static/img/icon/doc_lines.png'), 'class="tipwe" title="Ver detalles de usuario"') . ' ' . anchor('usuarios/editar/' . $al->id, img('static/img/icon/pencil.png'), 'class="tipwe" title="Editar usuario"') . ' ' . anchor('usuarios/eliminar/' . $al->id, img('static/img/icon/trash.png'), 'class="tipwe eliminar" title="Eliminar usuario"'));
}
echo $this->table->generate();
$config['base_url'] = site_url('usuarios/index');
$config['total_rows'] = User::count();
$config['per_page'] = '10';
$config['num_links'] = '10';
$config['first_link'] = '← primero';
$config['last_link'] = 'último →';
$this->load->library('pagination', $config);
echo '<div class="pagination">';
echo $this->pagination->create_links();
echo '</div>';
}
开发者ID:ricardocasares,项目名称:Cobros,代码行数:25,代码来源:usuarios.php
示例5: testpayapl
function testpayapl($mt, $type)
{
require 'cpaypal.php';
$requete = construit_url_paypal();
// Construit les options de base
// La fonction urlencode permet d'encoder au format URL les espaces, slash, deux points, etc.)
$requete = $requete . "&METHOD=SetExpressCheckout" . "&CANCELURL=" . urlencode(site_url('../achat/cancel')) . "&RETURNURL=" . urlencode(site_url('../achat/retour')) . "&AMT=" . $mt . "" . "&CURRENCYCODE=EUR" . "&DESC=" . urlencode($type) . "&LOCALECODE=FR" . "&HDRIMG=" . urlencode(img('logo.jpg', 'Logo du labo'));
$ch = curl_init($requete);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
// Retourne directement le transfert sous forme de chaîne de la valeur retournée par curl_exec() au lieu de l'afficher directement.
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// On lance l'exécution de la requête URL et on récupère le résultat dans une variable
$resultat_paypal = curl_exec($ch);
// S'il y a une erreur, on affiche "Erreur", suivi du détail de l'erreur.
if (!$resultat_paypal) {
echo "<p>Erreur</p><p>" . curl_error($ch) . "</p>";
} else {
$liste_param_paypal = recup_param_paypal($resultat_paypal);
// Lance notre fonction qui dispatche le résultat obtenu en un array
// Si la requête a été traitée avec succès
if ($liste_param_paypal['ACK'] == 'Success') {
// Redirige le visiteur sur le site de PayPal
header("Location: https://www.paypal.com/webscr&cmd=_express-checkout&token=" . $liste_param_paypal['TOKEN']);
exit;
} else {
echo "<p>Erreur de communication avec le serveur PayPal.<br />" . $liste_param_paypal['L_SHORTMESSAGE0'] . "<br />" . $liste_param_paypal['L_LONGMESSAGE0'] . "</p>";
}
}
// On ferme notre session cURL.
curl_close($ch);
}
开发者ID:namcreditlabo,项目名称:namcredit,代码行数:31,代码来源:payme.php
示例6: informNotifications
/**
* Grabs all new notifications and adds them to the sender's inform queue.
*
* This method gets called by dashboard's hooks file to display new
* notifications on every pageload.
*
* @since 2.0.18
* @access public
*
* @param Gdn_Controller $Sender The object calling this method.
*/
public static function informNotifications($Sender)
{
$Session = Gdn::session();
if (!$Session->isValid()) {
return;
}
$ActivityModel = new ActivityModel();
// Get five pending notifications.
$Where = array('NotifyUserID' => Gdn::session()->UserID, 'Notified' => ActivityModel::SENT_PENDING);
// If we're in the middle of a visit only get very recent notifications.
$Where['DateUpdated >'] = Gdn_Format::toDateTime(strtotime('-5 minutes'));
$Activities = $ActivityModel->getWhere($Where, 0, 5)->resultArray();
$ActivityIDs = array_column($Activities, 'ActivityID');
$ActivityModel->setNotified($ActivityIDs);
$Sender->EventArguments['Activities'] =& $Activities;
$Sender->fireEvent('InformNotifications');
foreach ($Activities as $Activity) {
if ($Activity['Photo']) {
$UserPhoto = anchor(img($Activity['Photo'], array('class' => 'ProfilePhotoMedium')), $Activity['Url'], 'Icon');
} else {
$UserPhoto = '';
}
$Excerpt = Gdn_Format::plainText($Activity['Story']);
$ActivityClass = ' Activity-' . $Activity['ActivityType'];
$Sender->informMessage($UserPhoto . Wrap($Activity['Headline'], 'div', array('class' => 'Title')) . Wrap($Excerpt, 'div', array('class' => 'Excerpt')), 'Dismissable AutoDismiss' . $ActivityClass . ($UserPhoto == '' ? '' : ' HasIcon'));
}
}
开发者ID:austins,项目名称:vanilla,代码行数:38,代码来源:class.notificationscontroller.php
示例7: dstat_index
function dstat_index()
{
$img = img();
$html = "<H1>{APP_POSTFIX} {statistics}</H1><br>\n<div style='text-align:right;float:right'>" . imgtootltip("refresh-24.png", "{refresh}", "postfix_refresh_services()") . "</div>\n<div id='dstat_postfix_div'>\n{$img}\n</div>";
$tpl = new templates();
echo $tpl->_ENGINE_parse_body($html);
}
开发者ID:BillTheBest,项目名称:1.6.x,代码行数:7,代码来源:dstat.postfix.php
示例8: product_listing_single
function product_listing_single($product)
{
$ci =& get_instance();
$ci->load->model('store_model');
$defaultImage = $ci->store_model->getProductImage($product->products_id);
echo '<div class="col-md-3 col-sm-';
echo '<div class="product-listing-image">';
echo '<a href="' . base_url() . 'product/detail/' . $product->products_id . '">';
$prop = array('class' => 'img-responsive', 'src' => 'files/store/' . $defaultImage);
echo img($prop);
echo "</a>";
if ($product->products_title != '') {
echo '<h2 class="product-listing-title">';
echo '<a href="' . base_url() . 'product/detail/' . $product->products_id . '">';
echo $product->products_title;
echo '</a>';
echo "</h2>";
}
if ($ci->config->item('show_price') && $product->products_price) {
echo '<div class="product-listing-price">';
echo '$' . number_format($product->products_price, 2, '.', ',');
echo '</div>';
}
if ($product->products_desc != '') {
echo "<p>";
echo $product->products_desc;
echo "</p>";
}
echo "<p>";
echo '<a class="btn btn-primary btn-outline btn-block" href="' . base_url() . 'product/detail/' . $product->products_id . '">View</a>';
echo "</p>";
echo '</div>';
echo '</div>';
}
开发者ID:sherdog,项目名称:cvsi,代码行数:34,代码来源:store_helper.php
示例9: filters
public function filters($offset = 0)
{
$string = '%' . $this->input->post('concepto') . '%';
$ciclo = '%' . $this->input->post('ciclo') . '%';
$condiciones = '';
$valores = array();
if ($string != '%%') {
$condiciones .= " concepto LIKE ?";
$valores['concepto'] = $string;
}
if ($ciclo != '%%') {
$condiciones .= " ciclo_lectivo LIKE ?";
$valores['ciclo_lectivo'] = $ciclo;
}
$conditions = array_merge(array($condiciones), $valores);
$config['base_url'] = site_url('conceptos/index');
$config['total_rows'] = Concept::count(array('conditions' => $conditions));
$config['per_page'] = '10';
$config['num_links'] = '10';
$config['first_link'] = '← primero';
$config['last_link'] = 'último →';
$this->load->library('pagination', $config);
$conceptos = Concept::all(array('conditions' => $conditions, 'limit' => $config['per_page'], 'offset' => $offset));
$this->table->set_heading('Orden', 'Concepto', 'Pagos Parciales', 'Ciclo Lectivo', 'Acciones');
foreach ($conceptos as $concepto) {
$this->table->add_row($concepto->id, $concepto->concepto, $concepto->pago_parcial ? 'Si' : 'No', $concepto->ciclo_lectivo, anchor('conceptos/ver/' . $concepto->id, img('static/img/icon/doc_lines.png'), 'class="tipwe" title="Ver detalles"') . ' ' . anchor('conceptos/editar/' . $concepto->id, img('static/img/icon/pencil.png'), 'class="tipwe" title="Editar"') . ' ' . anchor('conceptos/eliminar/' . $concepto->id, img('static/img/icon/trash.png'), 'class="tipwe eliminar" title="Eliminar"'));
}
echo $this->table->generate();
echo '<div class="pagination">';
echo $this->pagination->create_links();
echo '</div>';
}
开发者ID:ricardocasares,项目名称:Cobros,代码行数:32,代码来源:conceptos.php
示例10: image_thumb_local
function image_thumb_local($image_path, $height, $width, $crop = FALSE, $ratio = FALSE)
{
// Get the CodeIgniter super object
$CI =& get_instance();
$ext = strchr($image_path, '.');
$file_name = substr(basename($image_path), 0, -strlen($ext));
// Path to image thumbnail
$image_thumb = dirname($image_path) . '/' . $file_name . '_' . $height . '_' . $width . $ext;
if (!file_exists($image_thumb)) {
// LOAD LIBRARY
$CI->load->library('image_lib');
// CONFIGURE IMAGE LIBRARY
$config['image_library'] = 'gd2';
$config['source_image'] = $image_path;
$config['new_image'] = $image_thumb;
$config['maintain_ratio'] = $ratio;
$config['height'] = $height;
$config['width'] = $width;
$CI->image_lib->initialize($config);
if ($crop) {
$CI->image_lib->crop();
} else {
$CI->image_lib->resize();
}
$CI->image_lib->clear();
}
return '<img src="' . local_img_url() . $image_thumb . '" />';
return img($image_thumb);
}
开发者ID:Ankitj13,项目名称:sss,代码行数:29,代码来源:image_helper.php
示例11: index
public function index()
{
$data = array();
$data['error'] = '';
$data['output'] = '';
if (isset($_FILES['userfile'])) {
$this->upload->initialize(array('upload_path' => './assets/', 'allowed_types' => 'png|jpg|gif', 'max_size' => '5000', 'max_width' => '3000', 'max_height' => '3000'));
if ($this->upload->do_upload()) {
$data_upload = $this->upload->data();
$this->image_lib->initialize(array('image_library' => 'gd2', 'source_image' => './assets/' . $data_upload['file_name'], 'maintain_ratio' => false, 'create_thumb' => true, 'quality' => '20%', 'width' => 240, 'height' => 172));
if ($this->image_lib->resize()) {
$output = '<h4>Thumb - hasil Resize</h4>';
$output .= img('./assets/' . $data_upload['raw_name'] . '_thumb' . $data_upload['file_ext']);
$output .= '<h4 style="margin-top: 30px">Gambar Original</h4>';
$output .= img('./assets/' . $data_upload['file_name']);
$data['output'] = $output;
} else {
$data['error'] = $this->image_lib->display_errors();
}
} else {
$data['error'] = $this->upload->display_errors();
}
}
$this->load->view('welcome_message', $data);
}
开发者ID:dodyriatmaji,项目名称:Manajemen-FIle,代码行数:25,代码来源:Welcome.php
示例12: smarty_function_img
function smarty_function_img($params, $template)
{
$CI =& get_instance();
$CI->load->helper('html');
$attr = array();
$src = get_default($params, 'src');
$class = get_default($params, 'class');
$alt = get_default($params, 'alt');
$title = get_default($params, 'title');
$width = get_default($params, 'width');
$height = get_default($params, 'height');
if ($src != '') {
$attr['src'] = $src;
}
if ($class != '') {
$attr['class'] = $class;
}
if ($alt != '') {
$attr['alt'] = $alt;
}
if ($title != '') {
$attr['title'] = $title;
}
if ($width != '') {
$attr['width'] = $width;
}
if ($height != '') {
$attr['height'] = $height;
}
return img($attr);
}
开发者ID:zhaoshengloveqingqing,项目名称:Ci,代码行数:31,代码来源:function.img.php
示例13: filters
public function filters()
{
$string = '%' . $this->input->post('provincia') . '%';
$c = $this->input->post('country_id');
if ($string != '%%' && $c > 0) {
$provincias = State::find('all', array('conditions' => array('country_id = ? AND provincia LIKE ?', $c, $string)));
} elseif ($string != '%%') {
$provincias = State::find('all', array('conditions' => array('provincia LIKE ?', $string)));
} elseif ($c != '0') {
$provincias = State::find('all', array('conditions' => array('country_id = ?', $c)));
} else {
$provincias = State::find('all');
}
$this->table->set_heading('Orden', 'País', 'Provincia', 'Acciones');
foreach ($provincias as $pro) {
$this->table->add_row($pro->id, $pro->country->pais, $pro->provincia, anchor('provincias/editar/' . $pro->id, img('static/img/icon/pencil.png'), 'class="tipwe" title="Editar"') . ' ' . anchor('provincias/eliminar/' . $pro->id, img('static/img/icon/trash.png'), 'class="tipwe eliminar" title="Eliminar"'));
}
echo $this->table->generate();
$config['base_url'] = site_url('provincias/index');
$config['total_rows'] = State::count();
$config['per_page'] = '10';
$config['num_links'] = '10';
$config['first_link'] = '← primero';
$config['last_link'] = 'último →';
$this->load->library('pagination', $config);
echo '<div class="pagination">';
echo $this->pagination->create_links();
echo '</div>';
}
开发者ID:ricardocasares,项目名称:Cobros,代码行数:29,代码来源:provincias.php
示例14: jqdatag
function jqdatag()
{
$grid = $this->defgrid();
$param['grids'][] = $grid->deploy();
//Funciones que ejecutan los botones
$bodyscript = $this->bodyscript($param['grids'][0]['gridname']);
$WpAdic = "\n\t\t<tr><td><div class=\"anexos\">\n\t\t\t<table cellpadding='0' cellspacing='0'>\n\t\t\t\t<tr>\n\t\t\t\t\t<td style='vertical-align:top;'><div class='botones'><a style='width:94px;text-align:left;vertical-align:top;' href='#' id='gtipo'>" . img(array('src' => "images/tux1.png", 'height' => 15, 'alt' => 'Tipos de Edificacion', 'title' => 'Tipo de Edificacion', 'border' => '0')) . " Tipos</a></div></td>\n\t\t\t\t\t<td style='vertical-align:top;'><div class='botones'><a style='width:94px;text-align:left;vertical-align:top;' href='#' id='gusos'>" . img(array('src' => "images/unidad.gif", 'height' => 15, 'alt' => 'Usos de las areas', 'title' => 'Usos de los locales', 'border' => '0')) . " Usos</a></div></td>\n\t\t\t\t</tr>\n\t\t\t\t<tr>\n\t\t\t\t\t<td style='vertical-align:top;' colspan='2'><div class='botones'><a style='width:190px;text-align:left;vertical-align:top;' href='#' id='gubica'>" . img(array('src' => "images/basura.png", 'height' => 15, 'alt' => 'Mostrar/Ocultar Inactivos', 'title' => 'Mostrar/Ocultar Inactivos', 'border' => '0')) . " Areas</a></div></td>\n\t\t\t\t</tr>\n\t\t\t</table>\n\t\t\t</div>\n\t\t</td></tr>\n\n\t\t";
$grid->setWpAdicional($WpAdic);
//Botones Panel Izq
//$grid->wbotonadd(array("id"=>"edocta", "img"=>"images/pdf_logo.gif", "alt" => "Formato PDF", "label"=>"Ejemplo"));
$WestPanel = $grid->deploywestp();
$adic = array(array('id' => 'fedita', 'title' => 'Agregar/Editar Registro'), array('id' => 'fshow', 'title' => 'Mostrar Registro'), array('id' => 'fborra', 'title' => 'Eliminar Registro'));
$SouthPanel = $grid->SouthPanel($this->datasis->traevalor('TITULO1'), $adic);
$param['WestPanel'] = $WestPanel;
//$param['EastPanel'] = $EastPanel;
$param['SouthPanel'] = $SouthPanel;
$param['listados'] = $this->datasis->listados('EDIF', 'JQ');
$param['otros'] = $this->datasis->otros('EDIF', 'JQ');
$param['temas'] = array('proteo', 'darkness', 'anexos1');
$param['bodyscript'] = $bodyscript;
$param['tabs'] = false;
$param['encabeza'] = $this->titp;
$param['tamano'] = $this->datasis->getintramenu(substr($this->url, 0, -1));
$this->load->view('jqgrid/crud2', $param);
}
开发者ID:codethics,项目名称:proteoerp,代码行数:25,代码来源:edif.php
示例15: post_image
function post_image($image, $date, $title = '')
{
$title = str_replace(array('"', '\''), '', $title);
$image = $image != '' ? 'post/image/160/120/' . $image : 'assets/img/default-post.png';
$img_properties = array('src' => $image, 'alt' => $title, 'width' => '160', 'height' => '120', 'class' => 'float_left post-image');
return img($img_properties);
}
开发者ID:navruzm,项目名称:navruz.net,代码行数:7,代码来源:post_helper.php
示例16: index
public function index()
{
$offset = $this->general->get_offset();
$limit = $this->general->get_limit();
$total = $this->user_model->count_all();
$xdata['action'] = 'user/search' . get_query_string();
$xdata['action_delete'] = 'user/delete' . get_query_string();
$xdata['add_btn'] = anchor('user/add', '<span class="glyphicon glyphicon-plus"></span> Tambah', array('class' => 'btn btn-success btn-sm'));
$xdata['delete_btn'] = '<button id="delete-btn" class="btn btn-danger btn-sm"><span class="glyphicon glyphicon-trash"></span> Delete Checked</button>';
$this->table->set_template(tbl_tmp());
$head_data = array('kode' => 'Kode', 'nama' => 'Fullname', 'level_nama' => 'Level', 'ip_login' => 'IP', 'user_agent' => 'User Agent', 'date_login' => 'Date', 'status_nama' => 'Status');
$heading[] = form_checkbox(array('id' => 'selectAll', 'value' => 1));
$heading[] = '#';
foreach ($head_data as $r => $value) {
$heading[] = anchor('user' . get_query_string(array('order_column' => "{$r}", 'order_type' => $this->general->order_type($r))), "{$value} " . $this->general->order_icon("{$r}"));
}
$heading[] = 'Action';
$this->table->set_heading($heading);
$result = $this->user_model->get()->result();
$i = 1 + $offset;
foreach ($result as $r) {
$this->table->add_row(array('data' => form_checkbox(array('name' => 'check[]', 'value' => $r->id)), 'width' => '10px'), $i++, anchor('user/edit/' . $r->id . get_query_string(), $r->kode), array('data' => img(array('src' => get_user_photo($r->photo), 'class' => 'img-circle img-table')) . ' ' . $r->nama, 'width' => '200'), $r->level_nama, $r->ip_login, $r->user_agent, $r->date_login, '<label class="label label-' . ($r->status_kode == 'ON' ? 'success' : 'danger') . '">' . $r->status_nama . '</label>', anchor('user/edit/' . $r->id . get_query_string(), 'Edit') . " | " . anchor('user/delete/' . $r->id . get_query_string(), 'Delete', array('onclick' => "return confirm('you sure')")) . " | " . anchor('user_event?user=' . $r->kode, 'Event'));
}
$xdata['table'] = $this->table->generate();
$xdata['total'] = page_total($offset, $limit, $total);
$config = pag_tmp();
$config['base_url'] = "user" . get_query_string(null, 'offset');
$config['total_rows'] = $total;
$config['per_page'] = $limit;
$this->pagination->initialize($config);
$xdata['pagination'] = $this->pagination->create_links();
$data['content'] = $this->load->view('user_list', $xdata, true);
$this->load->view('template', $data);
}
开发者ID:adamprasetia,项目名称:mod,代码行数:34,代码来源:User.php
示例17: index
function index($offset = null)
{
$voters = $this->Boter->select_all();
$config['base_url'] = site_url('admin/voters/index');
$config['total_rows'] = count($voters);
$config['per_page'] = HALALAN_PER_PAGE;
$config['uri_segment'] = 4;
$config['num_links'] = 5;
$config['first_link'] = img('public/images/go-first.png');
$config['last_link'] = img('public/images/go-last.png');
$config['prev_link'] = img('public/images/go-previous.png');
$config['next_link'] = img('public/images/go-next.png');
$this->pagination->initialize($config);
$data['links'] = $this->pagination->create_links();
if ($offset == null) {
$offset = 0;
}
$limit = $config['per_page'];
$data['offset'] = $offset;
$data['limit'] = $limit;
$data['total_rows'] = $config['total_rows'];
$data['voters'] = $this->Boter->select_all_for_pagination($limit, $offset);
$admin['username'] = $this->admin['username'];
$admin['title'] = e('admin_voters_title');
$admin['body'] = $this->load->view('admin/voters', $data, TRUE);
$this->load->view('admin', $admin);
}
开发者ID:nicefirework,项目名称:halalan,代码行数:27,代码来源:voters.php
示例18: _createWidget
/**
* Create widget
*
*/
private function _createWidget()
{
$session = new Gamesession_delegate($this->gamesession->getId());
$session->load();
//TODO: Actual image generation
$this->_widget = img(self::WIDGET_PATH_PREFIX . $session->hash);
}
开发者ID:GothamGazette,项目名称:Maze,代码行数:11,代码来源:complete_level.php
示例19: filters
public function filters($offset = 0)
{
$string = '%' . $this->input->post('nivel') . '%';
$condiciones = '';
$valores = array();
if ($string != '%%') {
$condiciones .= " nivel LIKE ?";
$valores['nivel'] = $string;
}
$conditions = array_merge(array($condiciones), $valores);
$config['base_url'] = site_url('niveles/index');
$config['total_rows'] = Level::count(array('conditions' => $conditions));
$config['per_page'] = '10';
$config['num_links'] = '10';
$config['first_link'] = '← primero';
$config['last_link'] = 'último →';
$this->load->library('pagination', $config);
$niveles = Level::all(array('conditions' => $conditions, 'limit' => $config['per_page'], 'offset' => $offset));
$this->table->set_heading('Orden', 'Nivel', 'Acciones');
foreach ($niveles as $nivel) {
$this->table->add_row($nivel->id, $nivel->nivel, anchor('niveles/editar/' . $nivel->id, img('static/img/icon/pencil.png'), 'class="tipwe" title="Editar"') . ' ' . anchor('niveles/eliminar/' . $nivel->id, img('static/img/icon/trash.png'), 'class="tipwe eliminar" title="Eliminar"'));
}
echo $this->table->generate();
echo '<div class="pagination">';
echo $this->pagination->create_links();
echo '</div>';
}
开发者ID:ricardocasares,项目名称:Cobros,代码行数:27,代码来源:niveles.php
示例20: dstat_index
function dstat_index()
{
$page = CurrentPageName();
$img = img();
$html = "<H1>{cpu_usage} & System</H1><br>\n<table style='width:100%'>\n<tr>\n\t<td valign='top'>\n\t" . RoundedLightWhite(imgtootltip("refresh-32.png", "{refresh}", "cpu_refresh_services()")) . "<br>\n\t" . RoundedLightWhite(imgtootltip('32-charts-plus.png', '{top_ressources}', "TopRessourcesCPUGraph()")) . "</td>\n<td valign='top'><div id='dstat_cpu_div'>\n{$img}\n</div>\n</td>\n</tr>\n</table>";
$tpl = new templates();
echo $tpl->_ENGINE_parse_body($html);
}
开发者ID:brucewu16899,项目名称:artica,代码行数:8,代码来源:dstat.cpu.php
注:本文中的img函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论