当前位置: 首页>>代码示例>>PHP>>正文


PHP EB::getToken方法代码示例

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


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

示例1: __construct

 public function __construct()
 {
     $this->config = EB::config();
     $this->doc = JFactory::getDocument();
     // If environment is set to production, change to static.
     $environment = $this->config->get('easyblog_environment');
     if ($environment == 'production') {
         $environment = 'static';
     }
     $this->namespace = 'EASYBLOG';
     $this->shortName = 'eb';
     $this->environment = $environment;
     $this->mode = $this->config->get('easyblog_mode');
     $this->version = (string) EB::getLocalVersion();
     $this->baseUrl = EB::getBaseUrl();
     $this->token = EB::getToken();
     $this->inline = $this->config->get('inline_configuration');
     $this->enableCdn = $this->config->get('enable_cdn');
     $this->ajaxUrl = JURI::base() . '?option=com_easyblog';
     // If we should use http://site.com/index.php for the ajax calls, we need to append it here
     if ($this->config->get('ajax_use_index')) {
         $this->ajaxUrl = JURI::base() . 'index.php?option=com_easyblog';
     }
     parent::__construct();
 }
开发者ID:knigherrant,项目名称:decopatio,代码行数:25,代码来源:configuration.php

示例2: __construct

 public function __construct()
 {
     $this->config = EB::config();
     $this->doc = JFactory::getDocument();
     // If environment is set to production, change to static.
     $environment = $this->config->get('easyblog_environment');
     if ($environment == 'production') {
         $environment = 'static';
     }
     $this->namespace = 'EASYBLOG';
     $this->shortName = 'eb';
     $this->environment = $environment;
     $this->mode = $this->config->get('easyblog_mode');
     $this->version = (string) EB::getLocalVersion();
     $this->baseUrl = EB::getBaseUrl();
     $this->token = EB::getToken();
     $this->inline = $this->config->get('inline_configuration');
     $this->enableCdn = $this->config->get('enable_cdn');
     parent::__construct();
 }
开发者ID:BetterBetterBetter,项目名称:B3App,代码行数:20,代码来源:configuration.php

示例3: renderFolder

 /**
  * Renders a folder contents in Media manager
  *
  * @since	5.0
  * @access	public
  * @param	string
  * @return
  */
 public static function renderFolder($uri)
 {
     $my = JFactory::getUser();
     $user = EB::user();
     // Get the place data
     $place = self::getPlace($uri);
     // Determines if this is a local type or other remote sources
     $type = self::getSourceType($place->id);
     $currentEditor = $user->getEditor();
     $mm = new self($type);
     $folder = $mm->getItems($uri);
     $config = EB::config();
     $useIndex = $config->get('ajax_use_index');
     // Set the upload url
     $session = JFactory::getSession();
     $uploadUrl = JURI::base();
     if ($useIndex) {
         $uploadUrl .= 'index.php';
     }
     $uploadUrl .= '?option=com_easyblog&task=media.upload&tmpl=component&lang=en&key=' . $folder->key . '&sessionid=' . $session->getId() . '&' . EB::getToken() . '=1';
     // Set the id's for dropzones and browse button
     $browseButtonId = 'eb-mm-folder-browse-' . $folder->key;
     $dropElementId = 'eb-mm-folder-drop-' . $folder->key;
     $template = EB::template();
     $template->set('currentEditor', $currentEditor);
     $template->set('uploadUrl', $uploadUrl);
     $template->set('browseButtonId', $browseButtonId);
     $template->set('dropElementId', $dropElementId);
     $template->set('place', $place);
     $template->set('folder', $folder);
     $html = $template->output('site/mediamanager/folder');
     return $html;
 }
开发者ID:knigherrant,项目名称:decopatio,代码行数:41,代码来源:mediamanager.php

示例4: save

 /**
  * Saves the google auto posting settings
  *
  * @since	4.0
  * @access	public
  * @param	string
  * @return
  */
 public function save()
 {
     // Check for request forgeries
     EB::checkToken();
     // Get the client id
     $post = $this->input->getArray('post');
     unset($post['task']);
     unset($post['option']);
     unset($post[EB::getToken()]);
     // Get the model so that we can store the settings
     $model = EB::model('Settings');
     $model->save($post);
     // Redirect the user
     EB::info()->set(JText::_('COM_EASYBLOG_AUTOPOSTING_TWITTER_SAVE_SUCCESS'), 'success');
     $this->app->redirect('index.php?option=com_easyblog&view=autoposting&layout=twitter');
 }
开发者ID:BetterBetterBetter,项目名称:B3App,代码行数:24,代码来源:twitter.php

示例5: save

 /**
  * Saves the google auto posting settings
  *
  * @since	4.0
  * @access	public
  * @param	string
  * @return
  */
 public function save()
 {
     // Check for request forgeries
     EB::checkToken();
     // Get the client id
     $post = $this->input->getArray('post');
     unset($post['task']);
     unset($post['option']);
     unset($post[EB::getToken()]);
     if (isset($post['integrations_facebook_page_id'])) {
         $pages = $post['integrations_facebook_page_id'];
         // We need to merge them to be comma separated values
         $post['integrations_facebook_page_id'] = implode(',', $pages);
     }
     if (isset($post['integrations_facebook_group_id'])) {
         $groups = $post['integrations_facebook_group_id'];
         // Merge the array into string values
         $post['integrations_facebook_group_id'] = implode(',', $groups);
     }
     // Get the model so that we can store the settings
     $model = EB::model('Settings');
     $model->save($post);
     // Redirect the user
     EB::info()->set(JText::_('COM_EASYBLOG_AUTOPOSTING_FACEBOOK_SAVE_SUCCESS'), 'success');
     $this->app->redirect('index.php?option=com_easyblog&view=autoposting&layout=facebook');
 }
开发者ID:knigherrant,项目名称:decopatio,代码行数:34,代码来源:facebook.php

示例6:

				<li data-quickpost-photo-tab-webcam data-quickpost-photo-tab data-type="webcam">
					<a href="#profile" role="tab" data-bp-toggle="tab"><?php 
echo JText::_('COM_EASYBLOG_QUICKPOST_PHOTO_TAKE_PHOTO');
?>
</a>
				</li>
		    </ul>
			<div class="eb-quick-photo-tab-content tab-content">

				<div class="tab-pane fade in active" id="home">

					<div id="dropzone" class="eb-quick-photo-uploader input-drop"
						data-photo-upload-container
						data-plupload
						data-plupload-url="<?php 
echo JRoute::_('index.php?option=com_easyblog&task=quickpost.uploadPhoto&tmpl=component&' . EB::getToken() . '=1');
?>
"
						data-plupload-max-file-size="<?php 
echo '10mb';
// TODO: Get from config
?>
"
						data-plupload-file-data-name="image">

						<span class="eb-plupload-btn">
							<div id="input-drop-container" data-plupload-browse-button data-plupload-drop-element>
								<i class="fa fa-photo"></i>
								<div><?php 
echo JText::_('COM_EASYBLOG_QUICKPOST_PHOTO_CLICK_TO_UPLOAD');
?>
开发者ID:knigherrant,项目名称:decopatio,代码行数:31,代码来源:form.photo.php


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