<style type="text/css"> table th {background:#222; color:#fff; font-weight:normal; text-align:center;} table td {border:1px solid #ccc;} table td input {width:115px !important;} </style> <span class="on_close two">close-2</span> <?php echo form::open_multipart("edit_showroom/bulk_edit?pid={$this->pid}", array('class' => 'custom_ajaxForm')); ?> <div id="common_tool_header" class="buttons"> <button type="submit" class="jade_positive" accesskey="enter">Save Changes</button> <div id="common_title">Bulk Edit Showroom Items</div> </div> <div class="common_full_panel"> <div class="common_half_left" style="width:620px; height:400px; overflow:auto; background:#fff"> </div> <div class="common_half_right" style="width:110px;"> <br/><br/><b>Category</b> <div id="category_wrapper"> <?php echo $categories; ?> </div> </div>
<span class="on_close two"><?php echo $js_rel_command; ?> </span> <?php echo form::open_multipart("tool/css/{$name_id}/{$tool->id}", array('class' => 'ajaxForm', 'rel' => 'no_disable')); ?> <div style="padding:5px;"> <div style="padding-top:10px; float:right;"> Add Class: <input type="text" name="attributes" value="<?php echo $tool->attributes; ?> "> <button type="submit" name="save_css" class="jade_positive">Save</button> <button type="submit" name="save_template" class="jade_positive" value="true">Save as Template</button> </div> Tool: <em><?php echo $toolname; ?> </em> - Type: <em><?php echo $tool->type; ?> </em> - View: <em><?php echo $tool->view; ?> </em></small> <?php if (!empty($theme_sass)) {
{ with(document.options) { for(var i=0; i<elements.length; i++) { if(elements[i].type=='checkbox' && elements[i].name=='active_overlays[]') { elements[i].checked = false; } } } } </script> <hr> <div> <h2>Upload New Overlay</h2> <?php echo form::open_multipart('admin/emboss/new_overlay'); echo access::csrf_form_field(); echo form::upload(array('name' => 'overlay', 'style' => 'margin: .5em 0 .5em 0')); echo form::submit(array('name' => 'Upload', 'style' => 'display:block; float:none'), 'Upload'); ?> </form> </div> <hr> <div> <?php echo form::open('admin/emboss/update', array('name' => 'options')); echo access::csrf_form_field(); ?> <h2>Available Overlays</h2> <table style="margin:.5em 0 .5em 0"> <tr>
<?php /** * Venue edit * * @package Venues * @author Antti Qvickström * @copyright (c) 2010 Antti Qvickström * @license http://www.opensource.org/licenses/mit-license.php MIT license */ ?> <?php echo form::open_multipart(); ?> <fieldset> <legend><?php echo __('Basic information'); ?> </legend> <ul> <?php echo form::dropdown_wrap('venue_category_id', $form, $values, '', __('Category'), $errors); ?> <?php echo form::input_wrap(array('name' => 'name', 'maxlength' => 100), $values, '', __('Name'), $errors); ?>
<span class="on_close"><?php echo $js_rel_command; ?> </span> <?php echo form::open_multipart("edit_navigation/settings?pid={$navigation->id}", array('class' => 'ajaxForm')); ?> <div id="common_tool_header" class="buttons"> <button type="submit" name="add_item" class="jade_positive" accesskey="enter">Save Settings</button> <div id="common_title">Edit Navigation Settings</div> </div> <div class="fieldsets"> <b>List Name</b> <input type="text" name="name" value="<?php echo $navigation->name; ?> " maxlength="100" style="width:350px"> <p style="line-height:1.6em"> A List Name displays at the top of your Navigation list between <b><h2 class="navigation_title"> </h2></b> tags. <br> <br>Customize the look by editing this tool's CSS file. Look for the "navigation_title" class =). </p> </div> </form>
<span class="on_close two">close-2</span> <?php echo form::open_multipart("edit_showroom/edit/{$item->id}", array('class' => 'custom_ajaxForm')); ?> <input type="hidden" name="images" value="<?php echo $item->images; ?> "> <div id="common_tool_header" class="buttons"> <button type="submit" class="jade_positive" accesskey="enter"> Save Changes</button> <div id="common_title">Edit Showroom item</div> </div> <div class="common_left_panel"> <ul id="showroom_toggle" class="ui-tabs-nav"> <li><a href="#" rel="params" class="selected"><b>Attributes</b></span></a><li> <li><a href="#" rel="images"><b>Images</b></span></a><li> <li><a href="#" rel="intro"><b>Introduction</b></span></a><li> <li><a href="#" rel="desc"><b>Main Description</b></span></a><li> </ul> </div> <div class="common_main_panel"> <div id="params" class="toggle fieldsets"> <b>Item Name</b> <br><input type="text" name="name" value="<?php echo $item->name;
public function blockfields($id = null) { $idorigin = $id; if ($id != null) { settype($id, 'integer'); } if ($id === 0 and $idorigin != 'LOOK') { return NULL; } $msg = null; $types = new fpp_fieldtype_Model($this->meta); $types->SetPkID($id); $types->AddAttributes('NameModel', get_class($this)); $types->AddAttributes('Primary', $this->_FirstPrimary); $fields =& $types->fields; $this->_apply_php($types); $arrayWhere = null; $select = null; $arrayTables[] = $this->_Table; $first = null; $items = $this->show; $OneToMany = array(); //construccion de qu campos se van a mostrar if ($items == "AUTO") { $items = array(); foreach ($this->meta as $fieldname => $props) { $items[] = $fieldname; } } //cargando las propiedades de cada campo $OTMSelect = array(); foreach ($items as $fieldname) { if ($first == null) { $first = $fieldname; } $object = $fields->{$fieldname}; $db_field = "{$this->_Table}.{$fieldname}"; if ($object->typefield != 'OneToMany') { $select[] = $db_field; } else { $OTMSelect[] = $fieldname; } $titles[$fieldname] = $this->_File_i18n == null ? $object->verbose : Kohana::lang($this->_File_i18n . '.' . $object->verbose); $choice[$fieldname] = $object->choices; } if ($this->_AddField != null) { foreach ($this->_AddField as $data) { $table = $data['table']; $db_field = "{$table}.{$data['field']}"; $select[] = $db_field; $arrayTables[$table] = $table; } } //si es post , grabara los cambios if (request::method() == 'post' and $this->_OnlyRead == FALSE) { $save = $this->save; if ($save == 'AUTO') { $save = array(); foreach ($this->meta as $fieldname => $props) { $save[] = $fieldname; } } $input = Input::instance(); foreach ($save as $field) { $foreach_typefield =& $types->fields->{$field}->typefield; if ($types->fields->{$field}->typefield == 'CheckField' and @$_POST[$field] == '') { $_POST[$field] = FALSE; } if ($foreach_typefield == 'PasswordField') { $_POST[$field] = fpp::cryptme($_POST[$field]); } if ($input->post($field) !== null and $types->fields->{$field}->typefield != 'OneToMany' and $types->fields->{$field}->typefield != 'TabularModel') { $inp = $input->post($field); $tmp_inp = $inp; if ($types->fields->{$field}->post_exec != null and request::method() == 'post') { $value = $input->post($field); eval($types->fields->{$field}->post_exec . ';'); $inp = $value; } $update_fields[$field] = $inp; } //Preparando los Uno a muchos, y muchos a muchos if ($types->fields->{$field}->typefield == 'OneToMany' or $types->fields->{$field}->typefield == 'TabularModel') { $modtable = substr($types->fields->{$field}->model, 4); $metaOTM = fpp::GetOTM($modtable, $this->_Table); $metaOTM['fieldhtml'] = $input->post($field); $metaOTM['pk'] = $field; $OneToMany[$field] = $metaOTM; $this->db->delete($modtable, array($metaOTM['primary'] => $id)); } } /**/ if ($this->_AddKeyField != null) { foreach ($this->_AddKeyField as $field => $FValue) { $update_fields[$field] = $FValue; } } if (isset($_FILES)) { foreach ($_FILES as $key => $value) { // Checking Files (Upload Only Images) $this->file_type = $_FILES[$key]['type']; if (!($this->file_type != 'image/jpg' && $this->file_type != 'image/x-png' && $this->file_type != 'image/pjpeg' && $this->file_type != 'image/jpeg' && $this->file_type != 'image/gif' && $this->file_type != 'video/avi' && $this->file_type != 'video/msvideo' && $this->file_type != 'video/x-msvideo' && $this->file_type != 'image/png')) { //Execute IF statment try { $retupload = upload::save($_FILES[$key]); } catch (Exception $e) { echo Kohana::debug('Error: ' . "\n" . $e->getMessage() . "\n"); die; } $retupload = explode('upload/', $retupload); if (count($retupload) > 1) { $retupload = $retupload[1]; $update_fields[$key] = $retupload; $value = $retupload; if ($types->fields->{$key}->post_exec != null and request::method() == 'post') { eval($types->fields->{$key}->post_exec . ';'); } } } } } if ($id != null) { try { $status = $this->db->update($this->_Table, $update_fields, array($first => $id)); } catch (Exception $e) { echo Kohana::debug('Error: ' . "\n" . $e->getMessage() . "\n"); die; } } else { try { $status = $this->db->insert($this->_Table, $update_fields); $id = $status->insert_id(); } catch (Exception $e) { echo Kohana::debug('Error: ' . "\n" . $e->getMessage() . "\n"); die; } } if (@$_SESSION['PKID'] != "" and @$_GET['AJAX_NO_LOAD'] == TRUE) { $_SESSION['PKID_OTM'] = $id; } if (is_array($OneToMany)) { foreach ($OneToMany as $valueOTM) { if (is_array($valueOTM['fieldhtml'])) { foreach ($valueOTM['fieldhtml'] as $value) { $arrOTMnew = array($valueOTM['primary'] => $id, $valueOTM['secondary'] => $value); $this->db->insert($valueOTM['table'], $arrOTMnew); } } } } $this->_Response = TRUE; $msg = fpp::fppmsg('Guardo Correctamente'); } if ($id != null or $idorigin == 'LOOK') { //Inicializacion del query (construccion & carga) $strinTables = implode(',', $arrayTables); $select = implode(',', $select); $query = $this->db->select($select)->from($strinTables)->limit(1, 0); if (is_array($arrayWhere)) { $stringWhere = implode(' AND ', $arrayWhere); $query = $query->where($stringWhere); } if ($idorigin != 'LOOK') { $wherearray[] = "{$first} = {$id}"; } if ($this->_AddKeyField != null) { foreach ($this->_AddKeyField as $Fkey => $FValue) { $wherearray[] = "{$Fkey} = {$FValue}"; } } if ($this->_FilterActive != null) { foreach ($this->_FilterActiveByInfo as $filter => $value) { $wherearray[] = "{$this->_Table}.{$filter} = {$value}"; } } $where_string = implode(' AND ', $wherearray); $query = $query->where($where_string); try { $rows = $query->get(); } catch (Exception $e) { echo Kohana::debug('Error: ' . "\n" . $e->getMessage() . "\n"); die; } //escribiendo los campos de acuerdo a sus propiedades $data = new StdClass(); $types->base_uri = $this->base_uri; $valid_count = FALSE; foreach ($rows as $row) { foreach ($OTMSelect as $nameOTM) { $row->{$nameOTM} = 'null'; } foreach ($row as $name => $value) { $valid_count = TRUE; if ($this->_OnlyRead == TRUE) { $data->{$name} = $value; } else { $types->field_value = $value; // Si el campo es un "OneToMany" if ($types->fields->{$name}->typefield == 'OneToMany' or $types->fields->{$name}->typefield == 'TabularModel') { if (@$OneToMany[$name]['table'] == '') { $modtable = substr($types->fields->{$name}->model, 4); $OneToMany[$name] = fpp::GetOTM($modtable, $this->_Table); } $OTMArr = null; // Tomo el campo primario y secundario $OTMdb_field = $OneToMany[$name]['secondary']; $OTMdb_pk = $OneToMany[$name]['primary']; $valuelistOTM = null; try { $valuelistOTM = $this->db->from($OneToMany[$name]['table'])->select($OTMdb_field)->where(array($OTMdb_pk => $id))->get(); } catch (Exception $e) { echo Kohana::debug('Error: ' . "\n" . $e->getMessage() . "\n"); die; } foreach ($valuelistOTM as $rowOTM) { $OTMArr[] = $rowOTM->{$OTMdb_field}; } $types->field_value = $OTMArr; } $types->field_name = $name; $arrayorder[$name] = $types->ObjectField($name); } } foreach ($this->meta as $fieldname => $props) { $data->{$fieldname} = $arrayorder[$fieldname]; } } } else { foreach ($items as $name) { $valid_count = TRUE; $types->field_name = $name; $types->field_value = NULL; $data->{$name} = $types->ObjectField($name); } } //VIRTUAL if ($this->virtual != null) { $dirf = dirname(__FILE__); include_once $dirf . '/types/' . $this->virtual . '.php'; $data->virtualfield = new $this->virtual(); $data->virtualfield->id_table = $id; $titles['virtualfield'] = $data->virtualfield->title; } if ($this->virtualclone != null) { $dirf = dirname(__FILE__); include_once $dirf . '/types/' . $this->virtualclone . '.php'; $data->virtualfieldc = new $this->virtualclone(); $data->virtualfieldc->id_table = $id; $titles['virtualfieldc'] = $data->virtualfieldc->title; } //VIRTUAL if ($valid_count == FALSE) { return NULL; } $this->retfields = $data; //Setting Ajax $form = null; $attrform = null; if (@$_GET['AJAX_NO_LOAD'] == TRUE) { $form .= '<script>$(document).ready(function(){$(".FORM_AJAX").submit(function(){ return post_ajax(this); })});</script>'; $attrform = array("class" => 'FORM_AJAX'); } $urlform = NULL; if ($id > 0) { $this->uri = URI::Instance(); $urlform = str_replace("add", "edit/" . $id, $this->uri); } $form .= form::open_multipart($urlform, $attrform); if ($this->GetFieldAjax != NULL) { $FAjax = $this->GetFieldAjax; return $data->{$FAjax}; } $view_info = $this->_TabView == TRUE ? 'tabmodel' : 'info'; $str = View::factory($this->templatedir . $view_info)->set('msg', $msg)->set('data', $data)->set('form', $form)->set('only_read', $this->_OnlyRead)->set('titles', $titles)->set('tblname', $this->_Table)->render(); return $str; }
<?php echo form::open_multipart("utada/settings", array('class' => 'custom_ajaxForm')); ?> <div id="common_tool_header" class="buttons"> <button type="submit" name="edit_text" class="jade_positive">Save Changes</button> <div id="common_title">Configure +Jade Settings</div> </div> Serve Full Page Cache: <select name="serve_page_cache"> <option value="yes">Yes</option> <?php if (!Kohana::config('core.serve_page_cache')) { echo '<option value="no" selected="selected">No</option>'; } else { echo '<option value="no">No</option>'; } ?> </select> <br/>Non protected pages are <b>always<b/> fully cached. This option is whether or not we want to serve them. <br/><br/> <a href="/get/utada/clear_all_cache">Clear All Page Cache.</a> <br/>Clear the page cache files of EVERY site. (each site can clear its page cache separately via site/settings. <br/><br/>
<html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <?php echo $head; ?> <?php Event::run('s7n.admin.theme.head'); ?> </head> <body> <div id="dialog" style="display: none;">Möchten Sie diese Seite inklusive der Unterseiten wirklich löschen?</div> <div id="uploader" style="display: none;"> <?php echo form::open_multipart("admin/upload/save", array('id' => 'imageuploadform', "target" => "uploadiframe")); ?> <?php echo form::upload('picture'); ?> <?php echo form::close(); ?> <iframe id="uploadiframe" name="uploadiframe" src="#" style="display:none;"></iframe> <div id="uploadmessage"></div> </div> <div id="logoProgress"></div> <div id="header"> S7Nadmin <div class="info">
<span class="on_close"><?php echo $js_rel_command; ?> </span> <?php echo form::open_multipart("edit_text/add?pid={$item->id}", array('class' => 'ajaxForm')); ?> <div id="common_tool_header" class="buttons"> <button type="submit" name="edit_text" class="jade_positive">Save Changes</button> <div id="common_title">Edit Text</div> </div> <textarea name="body" class="render_html"><?php echo $item->body; ?> </textarea> </form>
<span class="on_close two">close-2</span> <?php echo form::open_multipart("edit_showroom/add_item/{$tool_id}", array('class' => 'ajaxForm')); ?> <input type="hidden" name="images" value="<?php echo $item->images; ?> "> <div id="common_tool_header" class="buttons"> <button type="submit" class="jade_positive" accesskey="enter">Add Item</button> <div id="common_title">Add New Showroom Item</div> </div> <div class="common_left_panel"> <ul id="showroom_toggle" class="ui-tabs-nav"> <li><a href="#" rel="params" class="selected"><b>Attributes</b></span></a><li> <li><a href="#" rel="images"><b>Images</b></span></a><li> <li><a href="#" rel="intro"><b>Introduction</b></span></a><li> <li><a href="#" rel="desc"><b>Main Description</b></span></a><li> </ul> </div> <div class="common_main_panel"> <div id="params" class="toggle fieldsets"> <b>Item Name</b> <br><input type="text" name="name" rel="text_req" maxlength="50" style="width:275px"> <br>
<? /** *@package Base **/ ?> <?php defined('SYSPATH') or die('No direct access allowed.'); ?> <h2><?php echo Kohana::lang('gallery.add_image'); ?> </h2> <? base::errors($errors); ?> <? echo form::open_multipart(NULL, array('class' => 'glForms'),array('redirect' => $form['redirect'])); echo form::label('image', Kohana::lang('gallery.select_image')); echo form::upload(array('name' => 'image'), $form['image']); echo '<br />'; echo form::label('submit', ' '); echo form::submit('submit', Kohana::lang('gallery.add_image'),'class=button'); echo '<br />'; echo form::close(); ?>
<h2 class="pad">Add a new Project</h2> <?php echo form::open_multipart(null, array('method' => 'post', 'class' => 'project-form')); ?> <fieldset class="project-type"> <legend>Project Type</legend> <?php foreach ($project_types as $type_id => $type_name) { ?> <label><input type="radio" name="project[project_type_id]" value="<?php echo $type_id; ?> " /> <?php echo $type_name; ?> </label> <?php } ?> </fieldset> <?php echo form::open_fieldset(array('class' => 'required-info')); ?> <?php echo form::legend('Project Info'); ?>
private function __videos() { $html = form::open_multipart(); $html .= form::upload(array("name" => "video"), 'path/to/local/file') . '<br/>'; $html .= form::label('title', 'Title'); $html .= form::input(array("name" => "title", "class" => "fullWidth")); $html .= form::submit(array("value" => "upload", "class" => "submit")); $html .= form::close(); return $html; }
<span class="on_close"><?php echo $js_rel_command; ?> </span> <?php echo form::open_multipart("edit_calendar/edit/{$item->id}", array('class' => 'ajaxForm')); ?> <div id="common_tool_header" class="buttons"> <button type="submit" name="edit_item" class="jade_positive">Save Changes</button> <div id="common_title">Edit Calendar Event</div> </div> <ul class="common_tabs_x ui-tabs-nav"> <li><a href="#calendar_title" class="selected"><b>Date and Title</b></span></a><li> <li><a href="#calendar_desc"><b>Description</b></span></a><li> </ul> <div class="common_full_panel"> <div id="calendar_title" class="toggle fieldsets"> <b>Title</b> <br><input type="text" name="title" value="<?php echo $item->title; ?> " rel="text_req" style="width:300px"> </div>