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


PHP osc_enqueue_script函数代码示例

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


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

示例1: osc_meta_edit

function osc_meta_edit($catId = null, $item_id = null)
{
    osc_enqueue_script('php-date');
    echo '<div class="row">';
    FieldForm::meta_fields_input($catId, $item_id);
    echo '</div>';
}
开发者ID:oanav,项目名称:closetshare,代码行数:7,代码来源:functions.php

示例2: payment_pro_stripe_load_lib

function payment_pro_stripe_load_lib()
{
    if (Params::getParam('page') == 'custom' && Params::getParam('route') == 'payment-pro-checkout') {
        osc_register_script('payment-pro-stripe', 'https://checkout.stripe.com/v2/checkout.js', array('jquery'));
        osc_enqueue_script('payment-pro-stripe');
    }
}
开发者ID:michaelxizhou,项目名称:myeden69-original-backup,代码行数:7,代码来源:load.php

示例3: __construct

 function __construct()
 {
     parent::__construct();
     // check if is moderator and can enter to this page
     if ($this->isModerator()) {
         if (!in_array($this->page, osc_apply_filter('moderator_access', array('items', 'comments', 'media', 'login', 'admins', 'ajax', 'stats', '')))) {
             osc_add_flash_error_message(_m("You don't have enough permissions"), 'admin');
             $this->redirectTo(osc_admin_base_url());
         }
     }
     osc_run_hook('init_admin');
     $config_version = str_replace('.', '', OSCLASS_VERSION);
     $config_version = preg_replace('|-.*|', '', $config_version);
     if ($config_version > osc_get_preference('version')) {
         if (get_class($this) == 'CAdminTools') {
         } else {
             if (get_class($this) != 'CAdminUpgrade') {
                 $this->redirectTo(osc_admin_base_url(true) . '?page=upgrade');
             }
         }
     }
     // show donation successful
     if (Params::getParam('donation') == 'successful') {
         osc_add_flash_ok_message(_m('Thank you very much for your donation'), 'admin');
     }
     // enqueue scripts
     osc_enqueue_script('jquery');
     osc_enqueue_script('jquery-ui');
     osc_enqueue_script('admin-osc');
     osc_enqueue_script('admin-ui-osc');
 }
开发者ID:mylastof,项目名称:os-class,代码行数:31,代码来源:AdminSecBaseModel.php

示例4: payment_pro_blockchain_load_lib

function payment_pro_blockchain_load_lib()
{
    if (Params::getParam('page') == 'custom' && Params::getParam('route') == 'payment-pro-checkout') {
        osc_register_script('blockchain', 'https://blockchain.info/Resources/wallet/pay-now-button.js', array('jquery'));
        osc_enqueue_script('blockchain');
    }
}
开发者ID:michaelxizhou,项目名称:myeden69-original-backup,代码行数:7,代码来源:load.php

示例5: anr_load_scripts

function anr_load_scripts()
{
    $language = anr_get_option('language');
    $lang = "";
    if ($language) {
        $lang = "?hl={$language}";
    }
    osc_register_script('anr-google-recaptcha-script', "https://www.google.com/recaptcha/api.js{$lang}");
    osc_enqueue_script('anr-google-recaptcha-script');
}
开发者ID:bomvendador,项目名称:soroka_r,代码行数:10,代码来源:index.php

示例6: __construct

        function __construct()
        {
            parent::__construct();

            // check if is moderator and can enter to this page
            if( $this->isModerator() ) {
                if( !in_array($this->page, osc_apply_filter('moderator_access', array('items', 'comments', 'media', 'login', 'admins', 'ajax', 'stats',''))) ) {
                    osc_add_flash_error_message(_m("You don't have enough permissions"), 'admin');
                    $this->redirectTo(osc_admin_base_url());
                }
            }

            osc_run_hook( 'init_admin' );

            // check if exist a new version each day
            if( (time() - osc_last_version_check()) > (24 * 3600) ) {
                $data = osc_file_get_contents('http://osclass.org/latest_version_v1.php?callback=?');
                $data = preg_replace('|^\?\((.*?)\);$|', '$01', $data);
                $json = json_decode($data);
                if( $json->version > osc_version() ) {
                    osc_set_preference( 'update_core_json', $data );
                } else {
                    osc_set_preference( 'update_core_json', '' );
                }
                osc_set_preference( 'last_version_check', time() );
                osc_reset_preferences();
            }

            $config_version = str_replace('.', '', OSCLASS_VERSION);
            $config_version = preg_replace('|-.*|', '', $config_version);

            if( $config_version > osc_get_preference('version') ) {
                if(get_class($this) == 'CAdminTools') {
                } else {
                    if(get_class($this) != 'CAdminUpgrade' )
                        $this->redirectTo(osc_admin_base_url(true) . '?page=upgrade');
                }
            }

            // show donation successful
            if( Params::getParam('donation') == 'successful' ) {
                osc_add_flash_ok_message(_m('Thank you very much for your donation'), 'admin');
            }

            // enqueue scripts
            osc_enqueue_script('jquery');
            osc_enqueue_script('jquery-ui');
            osc_enqueue_script('admin-osc');
            osc_enqueue_script('admin-ui-osc');
        }
开发者ID:pombredanne,项目名称:ArcherSys,代码行数:50,代码来源:AdminSecBaseModel.php

示例7: payment_load_js

/**
 * Load payment's js library
 */
function payment_load_js()
{
    if (Params::getParam('page') == 'custom') {
        if (osc_get_preference('paypal_enabled', 'payment') == 1) {
            osc_register_script('paypal', 'https://www.paypalobjects.com/js/external/dg.js', array('jquery'));
            osc_enqueue_script('paypal');
        }
        if (osc_get_preference('blockchain_enabled', 'payment') == 1) {
            osc_register_script('blockchain', 'https://blockchain.info/Resources/wallet/pay-now-button.js', array('jquery'));
            osc_enqueue_script('blockchain');
        }
        if (osc_get_preference('braintree_enabled', 'payment') == 1) {
            //osc_register_script('braintree', 'https://blockchain.info/Resources/wallet/pay-now-button.js', array('jquery'));
        }
    }
}
开发者ID:syedfiraat4,项目名称:bikade.com,代码行数:19,代码来源:index.php

示例8: payment_load_lib

/**
 * Load payment's js library
 */
function payment_load_lib()
{
    if (Params::getParam('page') == 'custom') {
        osc_enqueue_style('payment-plugin', osc_base_url() . 'oc-content/plugins/' . osc_plugin_folder(__FILE__) . 'style.css');
        if (osc_get_preference('paypal_enabled', 'payment') == 1) {
            osc_register_script('paypal', 'https://www.paypalobjects.com/js/external/dg.js', array('jquery'));
            osc_enqueue_script('paypal');
        }
        if (osc_get_preference('blockchain_enabled', 'payment') == 1) {
            osc_register_script('blockchain', 'https://blockchain.info/Resources/wallet/pay-now-button.js', array('jquery'));
            osc_enqueue_script('blockchain');
        }
        if (osc_get_preference('stripe_enabled', 'payment') == 1) {
            osc_register_script('stripe', 'https://checkout.stripe.com/v2/checkout.js', array('jquery'));
            osc_enqueue_script('stripe');
        }
    }
}
开发者ID:virsoni,项目名称:plugin-payment,代码行数:21,代码来源:index.php

示例9: osc_add_hook

<?php

include 'frm.class/PopUserForm.php';
// meta tag robots
osc_add_hook('header', 'pop_nofollow_construct');
pop_add_body_class('register');
osc_enqueue_script('jquery-validate');
osc_enqueue_script('jquery-metadata');
osc_current_web_theme_path('header.php');
?>

<div class="form-container box">
    <div class="header">
        <h1><?php 
_e('Register', 'pop');
?>
</h1>
    </div>
    <div class="form-content form-horizontal">
        <form name="register" action="<?php 
echo osc_base_url(true);
?>
" method="post" >
            <input type="hidden" name="page" value="register" />
            <input type="hidden" name="action" value="register_post" />
            <ul id="error_list"></ul>
            <div class="control-group">
                <label class="control-label" for="name"><?php 
_e('Name', 'pop');
?>
</label>
开发者ID:oanav,项目名称:closetshare,代码行数:31,代码来源:user-register.php

示例10: osc_item_region

if (osc_item_region() !== '') {
    $location[] = osc_item_region();
}
if (osc_item_city() !== '') {
    $location[] = osc_item_city();
}
if (osc_item_city_area() !== '') {
    $location[] = osc_item_city_area();
}
// meta tag robots
osc_add_hook('header', 'pop_follow_construct');
pop_add_body_class('item');
osc_enqueue_script('jquery-validate');
osc_enqueue_script('jquery-bxslider');
osc_enqueue_style('jquery-bxslider-css', osc_current_web_theme_url('css/jquery.bxslider.css'));
osc_enqueue_script('imgLiquid-js');
View::newInstance()->_exportVariableToView('user', User::newInstance()->findByPrimaryKey(osc_item_user_id()));
?>

<?php 
osc_current_web_theme_path('header.php');
$class = '';
if (osc_count_item_resources() == 0) {
    $class = "no-image";
}
?>
<div class="container">
    <div class="row">
        <div class="col-sm-12 col-md-5">
            <div class="item-photos">
                <?php 
开发者ID:oanav,项目名称:closetshare,代码行数:31,代码来源:item.php

示例11: pop_admin_enqueue_assets

function pop_admin_enqueue_assets()
{
    if (Params::getParam('file') == 'oc-content/themes/pop/admin/color_settings.php' && Params::getParam('page') == 'appearance' && Params::getParam('action') == 'render') {
        osc_enqueue_style('pop_admin_css', osc_base_url() . 'oc-content/themes/pop/admin/css/admin.css');
        osc_enqueue_script('colorpicker');
        osc_enqueue_style('colorpicker', osc_assets_url('js/colorpicker/css/colorpicker.css'));
    }
}
开发者ID:michaelxizhou,项目名称:myeden69-original-backup,代码行数:8,代码来源:functions.php

示例12: osc_enqueue_script

 * Copyright 2014 Osclass
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
osc_enqueue_script('jquery-nested');
osc_enqueue_script('tabber');
$categories = __get('categories');
function addHelp()
{
    echo '<p>' . __('Add, edit or delete the categories or subcategories in which users can post listings. Reorder sections by dragging and dropping, or nest a subcategory in an expanded category. <strong>Be careful</strong>: If you delete a category, all listings associated will also be deleted!') . '</p>';
}
osc_add_hook('help_box', 'addHelp');
function customPageHeader()
{
    ?>
        <h1><?php 
    _e('Categories');
    ?>
            <a href="#" class="btn ico ico-32 ico-help float-right"></a>
            <a href="<?php 
    echo osc_admin_base_url(true);
开发者ID:mylastof,项目名称:os-class,代码行数:31,代码来源:index.php

示例13: osc_esc_js

';
    var fileBtnText     = '<?php 
echo osc_esc_js(__('Choose File', 'classified'));
?>
';
</script>

<?php 
osc_enqueue_style('style', osc_current_web_theme_url('style.css'));
//osc_enqueue_style('tabs', osc_current_web_theme_url('tabs.css'));
//osc_enqueue_style('jquery-ui-datepicker', osc_assets_url('css/jquery-ui/jquery-ui.css'));
osc_register_script('jquery', osc_current_web_theme_js_url('jquery.js'));
osc_enqueue_script('jquery');
osc_enqueue_script('jquery-ui');
osc_register_script('bootstrap-js', osc_base_url() . 'oc-content/themes/classified/bootstrap/bootstrap.min.js', 'jquery');
osc_enqueue_script('bootstrap-js');
osc_enqueue_script('tabber');
osc_enqueue_script('bootstrap-dialog');
osc_run_hook('header');
//FieldForm::i18n_datePicker();
?>


<?php 
/**
*   Custom Javascript from Theme Settings
*   Can be used for Chat or other JavaScript applications
*/
if (nc_osc_custom_javascript_enabled()) {
    echo nc_osc_get_custom_javascript();
}
开发者ID:Ashishr2,项目名称:Kathmandu,代码行数:31,代码来源:head.php

示例14: delete_user_js

 function delete_user_js()
 {
     $location = Rewrite::newInstance()->get_location();
     $section = Rewrite::newInstance()->get_section();
     if ($location === 'user' && in_array($section, array('dashboard', 'profile', 'alerts', 'change_email', 'change_username', 'change_password', 'items')) || Params::getParam('page') === 'custom' && Params::getParam('in_user_menu') == true) {
         osc_enqueue_script('delete-user-js');
     }
 }
开发者ID:syedfiraat4,项目名称:bikade.com,代码行数:8,代码来源:functions.php

示例15: osc_register_script

 *        MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *             GNU Affero General Public License for more details.
 *
 *      You should have received a copy of the GNU Affero General Public
 * License along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
osc_register_script('jquery-ad-gallery', osc_current_web_theme_js_url('jquery.ad-gallery.1.2.5.js'), array('jquery'));
osc_register_script('tabber', osc_current_web_theme_js_url('tabber-minimized.js'), array('jquery'));
osc_register_script('theme-global', osc_current_web_theme_js_url('global.js'), array('jquery'));
osc_register_script('theme-ui', osc_current_web_theme_js_url('ui.js'), array('jquery'));
osc_enqueue_script('jquery-ui');
osc_enqueue_script('tabber');
osc_enqueue_script('jquery-ad-gallery');
osc_enqueue_script('jquery-validate');
osc_enqueue_script('theme-global');
osc_enqueue_script('theme-ui');
osc_enqueue_style('style', osc_current_web_theme_styles_url('style.css'));
?>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />

<title><?php 
echo meta_title();
?>
</title>
<meta name="title" content="<?php 
echo meta_title();
?>
" />
<meta name="description" content="<?php 
echo meta_description();
?>
开发者ID:blairmain,项目名称:theme-realestate,代码行数:31,代码来源:head.php


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