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


PHP Subscriber::newInstance方法代码示例

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


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

示例1: nc_osc_install

}
*/
if (!SellerRatings::newInstance()->checkTable()) {
    SellerRatings::newInstance()->import('sql/seller_ratings.sql');
}
if (!WatchList::newInstance()->checkTable()) {
    WatchList::newInstance()->import('sql/watchlist.sql');
}
if (!UniqueCounter::newInstance()->checkTable()) {
    UniqueCounter::newInstance()->import('sql/unique-counter.sql');
}
if (!PaidAds::newInstance()->checkTable()) {
    PaidAds::newInstance()->import('sql/paid-ads.sql');
}
if (!Subscriber::newInstance()->checkTable()) {
    Subscriber::newInstance()->import('sql/subscriber.sql');
}
/**
classified DATABASE FUNCTION
*/
function nc_osc_install()
{
    //ncdb::newInstance();
}
function nc_osc_uninstall()
{
    hello();
}
osc_add_hook('theme_activate', 'nc_osc_install');
osc_add_hook('theme_delete', 'nc_osc_uninstall');
function nc_install_user_pic_db()
开发者ID:jhalendra,项目名称:classmandu,代码行数:31,代码来源:functions.php

示例2: nc_osc_install

* INSTALLING DATABASES
*/
if (!SellerRatings::newInstance()->checkTable()) {
    SellerRatings::newInstance()->import('sql/seller_ratings.sql');
}
if (!WatchList::newInstance()->checkTable()) {
    WatchList::newInstance()->import('sql/watchlist.sql');
}
if (!PaidAds::newInstance()->checkTable()) {
    PaidAds::newInstance()->import('sql/paid-ads.sql');
}
if (!Subscriber::newInstance()->checkTable()) {
    Subscriber::newInstance()->import('sql/subscriber.sql');
}
if (!ProfilePicture::newInstance()->checkTable()) {
    Subscriber::newInstance()->import('sql/ppicture.sql');
}
if (!UniqueCounter::newInstance()->checkTable()) {
    UniqueCounter::newInstance()->import('sql/unique-counter.sql');
}
/**
*   Function to run while installing theme
*/
function nc_osc_install()
{
    //ncdb::newInstance();
}
/**
*   Function to run while uninstalling theme
*/
function nc_osc_uninstall()
开发者ID:Ashishr2,项目名称:Kathmandu,代码行数:31,代码来源:functions.php

示例3: switch

<?php

/**
 * Classified Ajax Subscription page
 *
 * @package Osclass
 * @subpackage Classified
 */
require_once '../../../oc-load.php';
require_once 'dao-class/subscriber.class.php';
require_once 'includes/helpers.php';
if (isset($_POST['submit_type'])) {
    $settings = $_POST['submit_type'];
    switch ($settings) {
        case 'subscribe_user':
            $email = Params::getParam('subs_email');
            if (Subscriber::newInstance()->checkEmail($email)) {
                echo "Already Subscribed";
            } else {
                Subscriber::newInstance()->SubscribeUser($email);
                echo "Email Subscribed.";
            }
            break;
    }
}
开发者ID:Ashishr2,项目名称:Kathmandu,代码行数:25,代码来源:ajax-subscribe.php

示例4: osc_set_preference

     osc_set_preference('paypal_password', $paypal_password, 'classified');
     osc_set_preference('paypal_signature', $paypal_signature, 'classified');
     osc_set_preference('paypal_server_rest', $paypal_server_rest, 'classified');
     osc_set_preference('paypal_server_classic', $paypal_server_classic, 'classified');
     osc_set_preference('paypal_client_id', $paypal_client_id, 'classified');
     osc_set_preference('paypal_secret', $paypal_secret, 'classified');
     osc_set_preference('paypal_status', $paypal_status, 'classified');
     osc_set_preference('paypal_server', $paypal_server, 'classified');
     break;
 case 'send_newsletter':
     $subject = Params::getParam('newsletter_subject');
     $message = Params::getParam('newsletter_message');
     //$message = stripslashes($message) ;
     $message = str_replace('src="../', 'src="' . osc_base_url() . '/', $message);
     $recipients = array();
     $recipients = Subscriber::newInstance()->listAll();
     foreach ($recipients as $user) {
         $params = array('subject' => $subject, 'to' => $user['subs_email'], 'to_name' => osc_page_title(), 'body' => $message, 'alt_body' => strip_tags($message), 'add_bcc' => '', 'from' => 'donotreply@' . osc_get_domain());
         osc_sendMail($params);
         //osc_add_flash_ok_message(__($user['subs_email'], 'nepcoders'),'admin');
     }
     break;
 case 'payment_info':
     $publish_fee_check = Params::getParam('publish_fee_check');
     $publish_cost = Params::getParam('publish_cost');
     $premium_fee_check = Params::getParam('premium_fee_check');
     $premium_cost = Params::getParam('premium_cost');
     $premium_days = Params::getParam('premium_days');
     $default_currency = Params::getParam('default_currency');
     osc_set_preference('publish_fee_check', $publish_fee_check, 'classified');
     osc_set_preference('publish_cost', $publish_cost, 'classified');
开发者ID:Ashishr2,项目名称:Kathmandu,代码行数:31,代码来源:jquery-submit.php


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