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


PHP FD::import方法代码示例

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


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

示例1: defined

<?php

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('fields:/user/cover/ajax');
class SocialFieldsGroupCover extends SocialFieldsUserCover
{
    public function upload()
    {
        // Get the ajax library
        $ajax = FD::ajax();
        $tmp = JRequest::getVar($this->inputName, '', 'FILES');
        $file = array();
        foreach ($tmp as $k => $v) {
            $file[$k] = $v['file'];
        }
        if (!isset($file['tmp_name']) || empty($file['tmp_name'])) {
            return $ajax->reject(JText::_('PLG_FIELDS_COVER_VALIDATION_INVALID_IMAGE'));
        }
        // Get user access
        $access = FD::access($this->uid, SOCIAL_TYPE_CLUSTERS);
        // Check if the filesize is too large
开发者ID:knigherrant,项目名称:decopatio,代码行数:31,代码来源:ajax.php

示例2: defined

<?php

/**
* @package      EasySocial
* @copyright    Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license      GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('fields:/user/datetime/datetime');
class SocialFieldsEventDatetime extends SocialFieldsUserDatetime
{
}
开发者ID:knigherrant,项目名称:decopatio,代码行数:17,代码来源:datetime.php

示例3: defined

<?php

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
// Extend from user boolean
FD::import('fields:/user/boolean/boolean');
class SocialFieldsGroupBoolean extends SocialFieldsUserBoolean
{
}
开发者ID:knigherrant,项目名称:decopatio,代码行数:18,代码来源:boolean.php

示例4: defined

<?php

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('fields:/user/multitextbox/multitextbox');
class SocialFieldsEventMultitextbox extends SocialFieldsUserMultitextbox
{
}
开发者ID:knigherrant,项目名称:decopatio,代码行数:17,代码来源:multitextbox.php

示例5: defined

<?php

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('admin:/includes/group/group');
class SocialUserAppStory extends SocialAppItem
{
    /**
     * event onLiked on story
     *
     * @since	1.0
     * @access	public
     * @param	object	$params		A standard object with key / value binding.
     *
     * @return	none
     */
    public function onAfterLikeSave(&$likes)
    {
        if (!$likes->type) {
            return;
        }
        // Set the default element.
开发者ID:knigherrant,项目名称:decopatio,代码行数:31,代码来源:story.php

示例6: defined

<?php

/**
* @package      EasySocial
* @copyright    Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license      GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('admin:/includes/fields/dependencies');
FD::import('fields:/event/permalink/helper');
class SocialFieldsEventPermalink extends SocialFieldItem
{
    /**
     * Displays the field for creation.
     *
     * @author  Jason Rey <jasonrey@stackideas.com>
     * @since   1.3
     * @access  public
     * @param   array                   $post       The posted data.
     * @param   SocialTableStepSession  $session    The session table.
     * @return  string                              The html codes for this field.
     */
    public function onRegister(&$post, &$session)
    {
        $value = !empty($post[$this->inputName]) ? $post[$this->inputName] : '';
        $error = $session->getErrors($this->inputName);
开发者ID:knigherrant,项目名称:decopatio,代码行数:31,代码来源:permalink.php

示例7: defined

<?php

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
// Include the fields library
FD::import('admin:/includes/fields/dependencies');
// Include helper lib
require_once dirname(__FILE__) . '/helper.php';
/**
 * Processes ajax calls for the Joomla_Email field.
 *
 * @since	1.0
 * @author	Jason Rey <jasonrey@stackideas.com>
 */
class SocialFieldsUserJoomla_Email extends SocialFieldItem
{
    /**
     * Determines if the email address is valid.
     *
     * @since	1.0
     * @access	public
     */
开发者ID:knigherrant,项目名称:decopatio,代码行数:31,代码来源:ajax.php

示例8: defined

<?php

/**
* @package      EasySocial
* @copyright    Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license      GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('admin:/includes/maintenance/dependencies');
class SocialMaintenanceScriptFixPrivacyState extends SocialMaintenanceScript
{
    public static $title = 'Fix privacy state column';
    public static $description = 'Update privacy state column to be published by default.';
    public function main()
    {
        $db = FD::db();
        $sql = $db->sql();
        // Update all privacy column for the `state` to be published
        $sql->update('#__social_privacy')->set('state', 1)->set('core', 1);
        $db->setQuery($sql);
        $db->query();
        return true;
    }
}
开发者ID:knigherrant,项目名称:decopatio,代码行数:29,代码来源:FixPrivacyState.php

示例9: defined

<?php

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('fields:/user/file/file');
/**
 * Field application for File
 *
 * @since	1.0
 * @author	Jason Rey <jasonrey@stackideas.com>
 */
class SocialFieldsGroupFile extends SocialFieldsUserFile
{
}
开发者ID:knigherrant,项目名称:decopatio,代码行数:23,代码来源:file.php

示例10: defined

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
// Include the fields library
FD::import('admin:/includes/fields/dependencies');
// Include helper file.
FD::import('fields:/user/joomla_username/helper');
/**
 * Processes ajax calls for the Joomla_Username field.
 *
 * @since	1.0
 * @author	Jason Rey <jasonrey@stackideas.com>
 */
class SocialFieldsUserJoomla_Username extends SocialFieldItem
{
    /**
     * Validates the username.
     *
     * @since	1.0
     * @access	public
     * @param	null
     * @return	JSON	A jsong encoded string.
开发者ID:ppantilla,项目名称:bbninja,代码行数:30,代码来源:ajax.php

示例11: defined

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
// Include the fields library
FD::import('admin:/includes/fields/dependencies');
// Include helper file.
FD::import('fields:/user/permalink/helper');
/**
 * Field application for Gender
 *
 * @since	1.0
 * @author	Jason Rey <jasonrey@stackideas.com>
 */
class SocialFieldsUserPermalink extends SocialFieldItem
{
    /**
     * Saves the permalink
     *
     * @since	1.0
     * @access	public
     * @param	string
     * @return
开发者ID:ppantilla,项目名称:bbninja,代码行数:30,代码来源:permalink.php

示例12: defined

<?php

/**
* @package      EasySocial
* @copyright    Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license      GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
// Include helper file.
FD::import('fields:/user/address/helper');
/**
 * Profile view for Notes app.
 *
 * @since   1.0
 * @access  public
 */
class AddressFieldWidgetsProfile
{
    public function profileHeaderB($key, $user, $field)
    {
        // Get the data
        $data = $field->data;
        if (!$data) {
            return;
        }
        $my = FD::user();
开发者ID:knigherrant,项目名称:decopatio,代码行数:31,代码来源:view.html.php

示例13: defined

<?php

/**
* @package      EasySocial
* @copyright    Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license      GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('admin:/includes/location/provider');
class SocialLocationProvidersPlaces extends SocialLocationProviders
{
    protected $queries = array('location' => '', 'radius' => 800, 'key' => '', 'query' => '', 'keyword' => '');
    public function __construct()
    {
        $key = FD::config()->get('location.places.api');
        if (empty($key)) {
            return $this->setError(JText::_('COM_EASYSOCIAL_LOCATION_PROVIDERS_PLACES_MISSING_APIKEY'));
        }
        $this->setQuery('key', $key);
    }
    public function setCoordinates($lat, $lng)
    {
        return $this->setQuery('location', $lat . ',' . $lng);
    }
    public function setSearch($search = '')
    {
开发者ID:knigherrant,项目名称:decopatio,代码行数:31,代码来源:places.php

示例14: defined

<?php

/**
* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
FD::import('admin:/includes/themes/themes');
class SocialRepostHelperStream
{
    private $title = null;
    private $content = null;
    public function __construct($uid, $group, $element)
    {
        $stream = FD::stream();
        $data = $stream->getItem($uid);
        $item = $data[0];
        $this->title = $item->title;
        $this->content = $item->content;
        if (isset($item->preview) && $item->preview) {
            $this->content = $item->preview;
        }
    }
    public function getTitle()
    {
开发者ID:knigherrant,项目名称:decopatio,代码行数:31,代码来源:stream.php

示例15: defined

* @package		EasySocial
* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* EasySocial is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/
defined('_JEXEC') or die('Unauthorized Access');
// Load triggers for fields.
FD::import('admin:/includes/fields/triggers');
// Load handlers for triggers
FD::import('admin:/includes/fields/handlers');
// Load apps dependencies.
FD::import('admin:/includes/apps/apps');
/**
 * Responsible to manage the field items including
 * event triggers.
 *
 * @since	1.0
 * @author	Mark Lee <mark@stackideas.com>
 */
class SocialFields
{
    /**
     * The triggerer object for fields.
     * @var	SocialFieldTriggers
     */
    private $triggerer = null;
    /**
开发者ID:BetterBetterBetter,项目名称:B3App,代码行数:31,代码来源:fields.php


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