• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP JFilterOutput类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中JFilterOutput的典型用法代码示例。如果您正苦于以下问题:PHP JFilterOutput类的具体用法?PHP JFilterOutput怎么用?PHP JFilterOutput使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了JFilterOutput类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: store

 public function store($updateNulls = true)
 {
     $date = JFactory::getDate();
     $user = JFactory::getUser();
     if ($this->id) {
         $this->modified_time = $date->toSql();
         $this->modified_user_id = $user->get('id');
     } else {
         if (!(int) $this->created_time) {
             $this->created_time = $date->toSql();
         }
         if (empty($this->created_user_id)) {
             $this->created_user_id = $user->get('id');
         }
     }
     $table = JTable::getInstance('Page', 'SppagebuilderTable');
     $alias = JFilterOutput::stringURLSafe($this->alias);
     if ($alias == '') {
         $alias = JFilterOutput::stringURLSafe($this->title);
     }
     $this->alias = $alias;
     if ($table->load(array('alias' => $alias)) && ($table->id != $this->id || $this->id == 0)) {
         $this->setError(JText::_('COM_SPPAGEBUILDER_ERROR_UNIQUE_ALIAS'));
         return false;
     }
     return parent::store($updateNulls);
 }
开发者ID:spikart,项目名称:spikart.com.ua,代码行数:27,代码来源:page.php


示例2: edit

 function edit()
 {
     $country_id = JRequest::getInt("country_id");
     $countries = $this->getModel("countries");
     $country = JTable::getInstance('country', 'jshop');
     $country->load($country_id);
     $first[] = JHTML::_('select.option', '0', _JSHOP_ORDERING_FIRST, 'ordering', 'name');
     $rows = array_merge($first, $countries->getAllCountries(0));
     $lists['order_countries'] = JHTML::_('select.genericlist', $rows, 'ordering', 'class="inputbox" size="1"', 'ordering', 'name', $country->ordering);
     $_lang = $this->getModel("languages");
     $languages = $_lang->getAllLanguages(1);
     $multilang = count($languages) > 1;
     $edit = $country_id ? $edit = 1 : ($edit = 0);
     JFilterOutput::objectHTMLSafe($country, ENT_QUOTES);
     $view = $this->getView("countries", 'html');
     $view->setLayout("edit");
     $view->assign('country', $country);
     $view->assign('lists', $lists);
     $view->assign('edit', $edit);
     $view->assign('languages', $languages);
     $view->assign('etemplatevar', '');
     $view->assign('multilang', $multilang);
     JPluginHelper::importPlugin('jshoppingadmin');
     $dispatcher = JDispatcher::getInstance();
     $dispatcher->trigger('onBeforeEditCountries', array(&$view));
     $view->displayEdit();
 }
开发者ID:ngogiangthanh,项目名称:damtvnewversion,代码行数:27,代码来源:countries.php


示例3: run

 function run($form, $actiondata)
 {
     $params = new JParameter($actiondata->params);
     $mainframe =& JFactory::getApplication();
     //save the data to db
     $db_save_details = $actiondata;
     $db_save_details->type = 'db_save';
     //create params
     $db_save_details_params = new JParameter('');
     $db_save_details_params->set('table_name', $mainframe->getCfg('dbprefix') . 'content');
     $db_save_details_params->set('model_id', 'Article');
     $db_save_details->params = $db_save_details_params->toString();
     //set data
     $user =& JFactory::getUser();
     $form->data['created_by'] = $user->id;
     $form->data['created'] = date("Y-m-d H:i:s");
     $form->data['catid'] = $params->get('catid', '');
     $form->data['sectionid'] = $params->get('sectionid', 0);
     $form->data['state'] = $params->get('state', 0);
     $form->data['title'] = $form->data[$params->get('title', '')];
     $form->data['fulltext'] = $form->data[$params->get('fulltext', '')];
     $form->data['introtext'] = isset($form->data[$params->get('introtext', '')]) ? $form->data[$params->get('introtext', '')] : '';
     $form->data['created_by_alias'] = $form->data[$params->get('created_by_alias', '')];
     //alias
     $form->data['alias'] = JFilterOutput::stringURLSafe($form->data['title']);
     $form->data['id'] = null;
     //$form->data['alias'] = null;
     $form->runAction($db_save_details);
 }
开发者ID:acculitx,项目名称:fleetmatrixsite,代码行数:29,代码来源:submit_article.php


示例4: edit

 function edit()
 {
     $db = JFactory::getDBO();
     $currency = JSFactory::getTable('currency', 'jshop');
     $currencies = JSFactory::getModel("currencies");
     $currency_id = JRequest::getInt('currency_id');
     $currency->load($currency_id);
     if ($currency->currency_value == 0) {
         $currency->currency_value = 1;
     }
     $first[] = JHTML::_('select.option', '0', _JSHOP_ORDERING_FIRST, 'currency_ordering', 'currency_name');
     $rows = array_merge($first, $currencies->getAllCurrencies());
     $lists['order_currencies'] = JHTML::_('select.genericlist', $rows, 'currency_ordering', 'class="inputbox" size="1"', 'currency_ordering', 'currency_name', $currency->currency_ordering);
     $edit = $currency_id ? $edit = 1 : ($edit = 0);
     JFilterOutput::objectHTMLSafe($currency, ENT_QUOTES);
     $view = $this->getView("currencies", 'html');
     $view->setLayout("edit");
     $view->assign('currency', $currency);
     $view->assign('lists', $lists);
     $view->assign('edit', $edit);
     $view->assign('etemplatevar', '');
     $dispatcher = JDispatcher::getInstance();
     $dispatcher->trigger('onBeforeEditCurrencies', array(&$view));
     $view->displayEdit();
 }
开发者ID:JexyRu,项目名称:jshop-updates,代码行数:25,代码来源:currencies.php


示例5: tranAlias

function tranAlias($easyset)
{
    // set translate language
    $SourceLan = $easyset->params->get('originLan');
    $ResultLan = $easyset->params->get('tranLlan', 'en');
    // get query
    $post = JRequest::get('post');
    if (!isset($post['jform']) || !isset($post['jform']['alias'])) {
        return;
    }
    $alias = $post['jform']['alias'];
    $title = $post['jform']['title'];
    $titleTmp = explode('::', $post['jform']['title']);
    if (!empty($titleTmp[1])) {
        $title = $titleTmp[0];
        $alias = JFilterOutput::stringURLSafe($titleTmp[1]);
    }
    if (trim($alias) == '') {
        $alias = AKHelper::_('lang.translate', $title, $SourceLan, $ResultLan);
        $alias = trim($alias);
        $alias = JFilterOutput::stringURLSafe($alias);
        $replace = array('aquot' => '', 'a39' => '', '--' => '-');
        $alias = strtr($alias, $replace);
        $alias = trim($alias, '-');
    }
    $post['jform']['alias'] = $alias;
    $post['jform']['title'] = $title;
    $input = JFactory::getApplication()->input;
    JRequest::setVar('jform', $post['jform'], 'method', true);
    $input->post->set('jform', $post['jform']);
    $input->request->set('jform', $post['jform']);
}
开发者ID:ForAEdesWeb,项目名称:AEW3,代码行数:32,代码来源:tranAlias.php


示例6: getBadgeAlias

function getBadgeAlias($id)
{
    $badge = FD::table('Badge');
    $badge->load($id);
    $alias = JFilterOutput::stringURLSafe($badge->alias);
    return $alias;
}
开发者ID:BetterBetterBetter,项目名称:B3App,代码行数:7,代码来源:common.php


示例7: check

 /**
  * Check data integrity
  *
  * @access public
  * @return boolean True on success
  */
 public function check()
 {
     if (empty($this->name)) {
         $this->setError(JText::_('ERROR NAME REQUIRED'));
         return false;
     }
     if (empty($this->alias)) {
         $this->alias = JFilterOutput::stringURLSafe($this->name);
     } else {
         $this->alias = JFilterOutput::stringURLSafe($this->alias);
     }
     // check if Position is unique
     // by checking: name+parent_id+sports_type_id+persontype
     if (!$this->id) {
         $db = JFactory::getDbo();
         $query = $db->getQuery(true);
         $query->select('name');
         $query->from('#__joomleague_position');
         $query->where('name =' . $db->Quote($this->name));
         $query->where('parent_id = ' . $db->Quote($this->parent_id));
         $query->where('sports_type_id = ' . $db->Quote($this->sports_type_id));
         $query->where('persontype = ' . $db->Quote($this->persontype));
         $db->setQuery($query);
         $result = $db->loadColumn();
         if ($result) {
             $app = JFactory::getApplication()->enqueueMessage('EventType already exists', 'warning');
             return false;
         }
     }
     return true;
 }
开发者ID:hfmprs,项目名称:JoomLeague,代码行数:37,代码来源:position.php


示例8: displayDefault

 function displayDefault()
 {
     global $mainframe;
     //Load pane behavior
     jimport('joomla.html.pane');
     //initialise variables
     $document =& JFactory::getDocument();
     $user =& JFactory::getUser();
     JHTML::_('behavior.tooltip');
     //get vars
     $cid = JRequest::getVar('cid');
     //create the toolbar
     if ($cid) {
         JToolBarHelper::title(JText::_('HG_EDIT_AD_TYPE'), 'adtypeedit');
     } else {
         JToolBarHelper::title(JText::_('HG_ADD_AD_TYPE'), 'adtypeadd');
     }
     JToolBarHelper::apply();
     JToolBarHelper::save();
     JToolBarHelper::cancel();
     //Get data from the model
     $model =& $this->getModel();
     $row =& $this->get('Type');
     // fail if checked out not by 'me'
     if ($row->id) {
         if ($model->isCheckedOut($user->get('id'))) {
             JError::raiseWarning('SOME_ERROR_CODE', $row->name . ' ' . JText::_('HG_EDITED_BY_ANOTHER_ADMIN'));
             $mainframe->redirect('index.php?option=com_hotelguide&view=adtypes');
         }
     }
     //clean data
     JFilterOutput::objectHTMLSafe($row, ENT_QUOTES);
     //assign data to template
     $this->assignRef('row', $row);
 }
开发者ID:raulrotundo,项目名称:jpmoser_guide,代码行数:35,代码来源:view.html.php


示例9: edit

 function edit()
 {
     $db = JFactory::getDBO();
     $man_id = JRequest::getInt("man_id");
     $manufacturer = JSFactory::getTable('manufacturer', 'jshop');
     $manufacturer->load($man_id);
     $edit = $man_id ? 1 : 0;
     if (!$man_id) {
         $manufacturer->manufacturer_publish = 1;
     }
     $_lang = JSFactory::getModel("languages");
     $languages = $_lang->getAllLanguages(1);
     $multilang = count($languages) > 1;
     $nofilter = array();
     JFilterOutput::objectHTMLSafe($manufacturer, ENT_QUOTES, $nofilter);
     $view = $this->getView("manufacturer", 'html');
     $view->setLayout("edit");
     $view->assign('manufacturer', $manufacturer);
     $view->assign('edit', $edit);
     $view->assign('languages', $languages);
     $view->assign('etemplatevar', '');
     $view->assign('multilang', $multilang);
     $dispatcher = JDispatcher::getInstance();
     $dispatcher->trigger('onBeforeEditManufacturers', array(&$view));
     $view->displayEdit();
 }
开发者ID:JexyRu,项目名称:jshop-updates,代码行数:26,代码来源:manufacturers.php


示例10: onContentPrepare

 function onContentPrepare($context, &$article, &$params, $limitstart = 1)
 {
     preg_match_all($this->regex, $article->text, $results, PREG_PATTERN_ORDER);
     //var_dump($results);
     if (count($results[0]) > 0) {
         for ($i = 0; $i < count($results[0]); $i++) {
             $subArray = array();
             $subArray = explode("|", $results[1][$i]);
             //var_dump($subArray);
             $contactId = $subArray[0] == '' || $subArray[0] == NULL ? 0 : $subArray[0];
             if (isset($subArray[1])) {
                 $itemId = $subArray[1] == '' || $subArray[1] == NULL ? 0 : $subArray[1];
                 //echo $itemId;
             }
             $itemId = isset($itemId) ? '&Itemid=' . $itemId : NULL;
             // Get Contact Details from Contact Component
             $query = 'SELECT * FROM #__contact_details' . ' WHERE id = ' . $contactId . ' AND published = 1';
             $contactInfo = $this->_getObject($query);
             // Set contact form link
             if (isset($contactInfo->email_to)) {
                 $contactFormLink = 'index.php?option=com_contact&view=contact&id=' . $contactId . $itemId . '&tmpl=component';
                 $contactFormLink = JFilterOutput::ampReplace($contactFormLink);
                 $contactFormOutput = '<iframe id="contact-form" onload="setIframeHeight(this.id)" src="' . $contactFormLink . '" scrolling="no" style="border:none;width:100%;"></iframe>';
                 $script = 'function setIframeHeight( iframeId ){var ifDoc, ifRef = document.getElementById( iframeId );try{ifDoc = ifRef.contentWindow.document.documentElement;}catch( e ){try{ifDoc = ifRef.contentDocument.documentElement;}catch(ee){}}if( ifDoc ){ifRef.height = 1;ifRef.height = ifDoc.scrollHeight;}}';
                 $doc =& JFactory::getDocument();
                 $doc->addScriptDeclaration($script);
                 $article->text = preg_replace($this->regex, $contactFormOutput, $article->text, 1);
             }
         }
     }
     return true;
 }
开发者ID:freaqzilla,项目名称:joomla-site,代码行数:32,代码来源:masters_articles_contact_form.php


示例11: _fixOldAlias

 private function _fixOldAlias($tablename = "content")
 {
     require_once dirname(__FILE__) . DS . 'output.php';
     $db =& JFactory::getDBO();
     $query = $db->getQuery(true);
     // $query = "SELECT id, title FROM #__$tablename;";
     $query->select('id, title');
     $query->from($db->quoteName("#__{$tablename}"));
     $db->setQuery($query);
     $rows = $db->loadAssocList();
     // If found any rows
     if (!empty($rows) && count($rows)) {
         foreach ($rows as $row) {
             $id = (int) $row["id"];
             $alias = JFilterOutput::stringURLSafe($row["title"]);
             // $query	= "UPDATE #__$tablename SET alias='$alias' WHERE id=$id;";
             $query = $db->getQuery(true);
             $query->update($db->quoteName("#__{$tablename}"));
             $query->set('alias=' . $db->quote($alias));
             $query->where('id=' . $db->quote($id));
             $db->setQuery($query);
             $result = $db->query();
         }
     }
 }
开发者ID:tristanbailey,项目名称:vinaora-vietalias,代码行数:25,代码来源:vinaora_vietalias.php


示例12: importImage

 /**
  * Takes an image file, moves the file and adds database entry
  * @param the verified REAL name of the local file including path
  * @param name of file according to user/browser or just the name excluding path
  * @param desired category
  * @param title of image, if empty will be created from $name
  * @param description of image, if empty will remain empty
  * @return returns true if successfull otherwise returns an ImageUploadError
  */
 function importImage($tmpName, $name, $cat, $title = '', $desc = '')
 {
     global $rsgConfig;
     $database =& JFactory::getDBO();
     $my =& JFactory::getUser();
     $destination = fileUtils::move_uploadedFile_to_orignalDir($tmpName, $name);
     if (is_a($destination, imageUploadError)) {
         return $destination;
     }
     $parts = pathinfo($destination);
     $newName = $parts['basename'];
     // fill $title if empty
     if ($title == '') {
         $title = substr($parts['basename'], 0, -(strlen($parts['extension']) + ($parts['extension'] == '' ? 0 : 1)));
     }
     // determine ordering
     $database->setQuery("SELECT COUNT(1) FROM #__rsgallery2_files WHERE gallery_id = '{$cat}'");
     $ordering = $database->loadResult() + 1;
     //Store image details in database
     $alias = mysql_real_escape_string(JFilterOutput::stringURLSafe($title));
     $desc = mysql_real_escape_string($desc);
     $title = mysql_real_escape_string($title);
     $database->setQuery("INSERT INTO #__rsgallery2_files" . " (title, name, descr, gallery_id, date, ordering, userid, alias) VALUES" . " ('{$title}', '{$newName}', '{$desc}', '{$cat}', now(), '{$ordering}', '{$my->id}', '{$alias}')");
     if (!$database->query()) {
         audioUtils::deleteAudio($parts['basename']);
         return new imageUploadError($parts['basename'], $database->stderr(true));
     }
     return true;
 }
开发者ID:realityking,项目名称:rsgallery2,代码行数:38,代码来源:audio.utils.php


示例13: filterTitle

 public function filterTitle(&$alias)
 {
     if ($alias == "") {
         $alias = JRequest::getString("refField_title");
     }
     $alias = JFilterOutput::stringURLSafe($alias);
 }
开发者ID:jmangarret,项目名称:webtuagencia24,代码行数:7,代码来源:menu.php


示例14: edit

 function edit()
 {
     $jshopConfig = JSFactory::getConfig();
     $shipping_id = JRequest::getInt("shipping_id");
     $shipping = JTable::getInstance('shippingMethod', 'jshop');
     $shipping->load($shipping_id);
     $edit = $shipping_id ? $edit = 1 : ($edit = 0);
     $_lang = $this->getModel("languages");
     $languages = $_lang->getAllLanguages(1);
     $multilang = count($languages) > 1;
     $_payments = $this->getModel("payments");
     $list_payments = $_payments->getAllPaymentMethods(0);
     $lists['payments'] = JHTML::_('select.genericlist', $list_payments, 'listpayments[]', 'class="inputbox" size="10" multiple = "multiple"', 'payment_id', 'name', $shipping->getPayments());
     $nofilter = array();
     JFilterOutput::objectHTMLSafe($shipping, ENT_QUOTES, $nofilter);
     $view = $this->getView("shippings", 'html');
     $view->setLayout("edit");
     $view->assign('shipping', $shipping);
     $view->assign('edit', $edit);
     $view->assign('languages', $languages);
     $view->assign('multilang', $multilang);
     $view->assign('lists', $lists);
     $view->assign('config', $jshopConfig);
     $view->assign('etemplatevar', '');
     JPluginHelper::importPlugin('jshoppingadmin');
     $dispatcher = JDispatcher::getInstance();
     $dispatcher->trigger('onBeforeEditShippings', array(&$view));
     $view->displayEdit();
 }
开发者ID:Tommar,项目名称:vino2,代码行数:29,代码来源:shippings.php


示例15: check

 /**
  * Overloaded check method to ensure data integrity
  *
  * @access public
  * @return boolean True on success
  * @since 1.0
  */
 function check()
 {
     if (empty($this->name)) {
         $this->setError(JText::_('NAME REQUIRED'));
         return false;
     }
     // add default middle size name
     if (empty($this->middle_name)) {
         $parts = explode(" ", $this->name);
         $this->middle_name = substr($parts[0], 0, 20);
     }
     // add default short size name
     if (empty($this->short_name)) {
         $parts = explode(" ", $this->name);
         $this->short_name = substr($parts[0], 0, 2);
     }
     // setting alias
     if (empty($this->alias)) {
         $this->alias = JFilterOutput::stringURLSafe($this->name);
     } else {
         $this->alias = JFilterOutput::stringURLSafe($this->alias);
         // make sure the user didn't modify it to something illegal...
     }
     return true;
 }
开发者ID:santas156,项目名称:joomleague-2-komplettpaket,代码行数:32,代码来源:team.php


示例16: renderComments

 /**
  * Render comments and respond form html.
  *
  * @param AppView $view The view the comments are rendered on
  * @param Item $item The item whos comments are rendered
  *
  * @return string The html output
  *
  * @since 2.0
  */
 public function renderComments($view, $item)
 {
     if ($item->getApplication()->isCommentsEnabled()) {
         // get application params
         $params = $this->app->parameter->create($item->getApplication()->getParams()->get('global.comments.'));
         if ($params->get('twitter_enable') && !function_exists('curl_init')) {
             $this->app->error->raiseWarning(500, JText::_('To use Twitter, CURL needs to be enabled in your php settings.'));
             $params->set('twitter_enable', false);
         }
         // get active author
         $active_author = $this->activeAuthor();
         // filter author output
         JFilterOutput::objectHTMLSafe($active_author, ENT_QUOTES, array('app', 'application'));
         // get comment content from session
         $content = $this->app->system->session->get('com_zoo.comment.content');
         $params->set('content', $content);
         // get comments and build tree
         $approved = $item->canManageComments() ? Comment::STATE_UNAPPROVED : Comment::STATE_APPROVED;
         $comments = $item->getCommentTree($approved);
         // build captcha
         $captcha = false;
         if ($plugin = $params->get('captcha', false) and (!$params->get('captcha_guest_only', 0) or !$this->app->user->get()->id)) {
             $captcha = JCaptcha::getInstance($plugin);
         }
         // filter redirect url
         $view->set('redirect', htmlspecialchars(JUri::getInstance()->toString()));
         if ($item->isCommentsEnabled() || count($comments) - 1) {
             // create comments html
             return $view->partial('comments', compact('item', 'active_author', 'comments', 'params', 'captcha'));
         }
     }
     return null;
 }
开发者ID:JBZoo,项目名称:Zoo-Changelog,代码行数:43,代码来源:comment.php


示例17: createMenuItem

 /**
  * Generates a menu item based on given data.
  *
  * @param   array  $data  Data to insert to the menu item.
  *
  * @return null
  */
 private static function createMenuItem($data)
 {
     $count = count(self::$data);
     $defaults = array('id' => $count, 'menutype' => 'testmenu', 'title' => '', 'alias' => isset($data['title']) ? JFilterOutput::stringURLSafe($data['title']) : '', 'route' => isset($data['title']) ? JFilterOutput::stringURLSafe($data['title']) : '', 'link' => JUri::buildQuery($data['query']), 'type' => 'component', 'level' => '1', 'language' => '*', 'access' => '1', 'params' => '{}', 'home' => '0', 'component_id' => '1000', 'parent_id' => '0', 'component' => 'com_monitor', 'tree' => isset($data['id']) ? array($data['id']) : array($count), 'query' => array('option' => 'com_monitor'));
     $obj = (object) array_merge($defaults, $data);
     self::$data[$obj->id] = $obj;
 }
开发者ID:Harmageddon,项目名称:com_monitor,代码行数:14,代码来源:menu.php


示例18: edit

 function edit()
 {
     $value_id = JRequest::getInt("value_id");
     $attr_id = JRequest::getInt("attr_id");
     $jshopConfig = JSFactory::getConfig();
     $db = JFactory::getDBO();
     $attributValue = JTable::getInstance('attributValue', 'jshop');
     $attributValue->load($value_id);
     $_lang = $this->getModel("languages");
     $languages = $_lang->getAllLanguages(1);
     $multilang = count($languages) > 1;
     JFilterOutput::objectHTMLSafe($attributValue, ENT_QUOTES);
     $view = $this->getView("attributesvalues", 'html');
     $view->setLayout("edit");
     $view->assign('attributValue', $attributValue);
     $view->assign('attr_id', $attr_id);
     $view->assign('config', $jshopConfig);
     $view->assign('languages', $languages);
     $view->assign('multilang', $multilang);
     $view->assign('etemplatevar', '');
     JPluginHelper::importPlugin('jshoppingadmin');
     $dispatcher = JDispatcher::getInstance();
     $dispatcher->trigger('onBeforeEditAtributesValues', array(&$view));
     $view->displayEdit();
 }
开发者ID:Tommar,项目名称:vino2,代码行数:25,代码来源:attributesvalues.php


示例19: display

 function display($tpl = null)
 {
     global $option, $mainframe, $layout;
     // get data
     $model =& $this->getModel();
     $product = $model->getDetail();
     $images = $model->getImages();
     $relative = $model->getRelative();
     $titleCatName = JFilterOutput::stringURLSafe($product->category);
     $titleCatName = str_replace(' ', '-', strtolower(trim($titleCatName)));
     $title = JFilterOutput::stringURLSafe($product->name);
     $title = str_replace(' ', '-', strtolower($title));
     $product->link = JRoute::_('index.php?option=' . $option . '&view=detail&id=' . $product->id . ':' . $title);
     $document =& JFactory::getDocument();
     $document->addScript('components/com_products/js/jquery-1.3.2.js');
     $document->addScript('components/com_products/js/colorbox/jquery.colorbox.js');
     $document->addStyleSheet('components/com_products/js/colorbox/colorbox.css');
     $document->addScriptDeclaration('if($===jQuery){jQuery.noConflict();} jQuery(document).ready(function(){ jQuery("a[rel=\'product_image\']").colorbox({current: "Ảnh {current} / {total}"}); });');
     $titleSEO = '';
     if ($product->name) {
         $titleSEO = $product->name;
         if ($product->category) {
             $titleSEO = $product->name . ' | ' . $product->category;
         }
     }
     $document->setTitle($titleSEO . ' | ' . $mainframe->getCfg('sitename'));
     $app =& JFactory::getApplication();
     $pathway = $app->getPathway();
     $pathway->addItem($product->name);
     $this->assignRef('relative', $relative);
     $this->assignRef('images', $images);
     $this->assignRef('product', $product);
     $this->assignRef('titleCatName', $titleCatName);
     parent::display($tpl);
 }
开发者ID:geilin,项目名称:jooomlashop,代码行数:35,代码来源:view.html.php


示例20: _getRequest

 protected function _getRequest($hash = 'default', $mask = 0)
 {
     if ($hash == 'post') {
         $post = JRequest::get('post');
         // fix up special html fields
         $text = JRequest::getVar('text', '', 'post', 'string', JREQUEST_ALLOWRAW);
         // Clean text for xhtml transitional compliance
         $text = str_replace('<br>', '<br />', $text);
         // Search for the {readmore} tag and split the text up accordingly.
         $pattern = '#<hr\\s+id=("|\')system-readmore("|\')\\s*\\/*>#i';
         $tagPos = preg_match($pattern, $text);
         if ($tagPos == 0) {
             $post['introtext'] = $text;
             $post['fulltext'] = "";
         } else {
             list($post['introtext'], $post['fulltext']) = preg_split($pattern, $text, 2);
         }
         if (empty($post['alias'])) {
             $post['alias'] = $post['name'];
         }
         $post['alias'] = JFilterOutput::stringURLSafe($post['alias']);
         return $post;
     }
     return parent::_getRequest($hash, $mask);
 }
开发者ID:janssit,项目名称:www.alu-andries.be,代码行数:25,代码来源:item.php



注:本文中的JFilterOutput类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP JFolder类代码示例发布时间:2022-05-23
下一篇:
PHP JFilterInput类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap