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

PHP oos_get_filename函数代码示例

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

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



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

示例1: create_plugin_instance

 function create_plugin_instance()
 {
     $aFilename = oos_get_filename();
     $aModules = oos_get_modules();
     if ($_GET['file'] != $aFilename['info_down_for_maintenance']) {
         MyOOS_CoreApi::redirect(oos_href_link($aModules['info'], $aFilename['info_down_for_maintenance'], '', 'NONSSL', true, false));
     }
     return true;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:9,代码来源:oos_event_down_for_maintenance.php


示例2: create_plugin_instance

 function create_plugin_instance()
 {
     if (!isset($_SESSION['customer_id'])) {
         $aFilename = oos_get_filename();
         $aModules = oos_get_modules();
         if ($_GET['mp'] != $aModules['user']) {
             $_SESSION['navigation']->set_snapshot();
             oos_redirect(oos_href_link($aModules['user'], $aFilename['login'], '', 'SSL'));
         }
     }
     return true;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:12,代码来源:oos_event_customer_must_login.php


示例3: create_plugin_instance

 function create_plugin_instance()
 {
     $aFilename = oos_get_filename();
     $aModules = oos_get_modules();
     if ($_GET['file'] != $aFilename['login'] && !isset($_SESSION['customer_id'])) {
         $cookie_url_array = parse_url((ENABLE_SSL == true ? OOS_HTTPS_SERVER : OOS_HTTP_SERVER) . substr(OOS_SHOP, 0, -1));
         $cookie_path = $cookie_url_array['path'];
         if (isset($_COOKIE['email_address']) && isset($_COOKIE['password'])) {
             // Get database information
             $dbconn =& oosDBGetConn();
             $oostable =& oosDBGetTables();
             $customerstable = $oostable['customers'];
             $sql = "SELECT customers_id, customers_gender, customers_firstname, customers_lastname,\n                         customers_password, customers_wishlist_link_id, customers_language,\n                         customers_vat_id_status, customers_email_address, customers_default_address_id,\n                         customers_max_order\n                  FROM {$customerstable}\n                  WHERE customers_login = '1'\n                  AND customers_email_address = '" . oos_db_input($_COOKIE['email_address']) . "'";
             $check_customer_result = $dbconn->Execute($sql);
             if ($check_customer_result->RecordCount()) {
                 $check_customer = $check_customer_result->fields;
                 if (oos_validate_password($_COOKIE['password'], $check_customer['customers_password'])) {
                     $address_booktable = $oostable['address_book'];
                     $sql = "SELECT entry_country_id, entry_zone_id\n                      FROM {$address_booktable}\n                      WHERE customers_id = '" . $check_customer['customers_id'] . "'\n                        AND address_book_id = '1'";
                     $check_country = $dbconn->GetRow($sql);
                     if ($check_customer['customers_language'] == '') {
                         $sLanguage = oos_var_prep_for_os($_SESSION['language']);
                         $customerstable = $oostable['customers'];
                         $dbconn->Execute("UPDATE {$customerstable}\n                                  SET customers_language = '" . oos_db_input($sLanguage) . "'\n                                  WHERE customers_id = '" . intval($check_customer['customers_id']) . "'");
                     }
                     $_SESSION['customer_wishlist_link_id'] = $check_customer['customers_wishlist_link_id'];
                     $_SESSION['customer_id'] = $check_customer['customers_id'];
                     $_SESSION['customer_default_address_id'] = $check_customer['customers_default_address_id'];
                     if (ACCOUNT_GENDER == '1') {
                         $_SESSION['customer_gender'] = $check_customer['customers_gender'];
                     }
                     $_SESSION['customer_first_name'] = $check_customer['customers_firstname'];
                     $_SESSION['customer_lastname'] = $check_customer['customers_lastname'];
                     $_SESSION['customer_max_order'] = $check_customer['customers_max_order'];
                     $_SESSION['customer_country_id'] = $check_country['entry_country_id'];
                     $_SESSION['customer_zone_id'] = $check_country['entry_zone_id'];
                     if (ACCOUNT_VAT_ID == '1') {
                         $_SESSION['customers_vat_id_status'] = $check_customer['customers_vat_id_status'];
                     }
                     $_SESSION['member']->restore_group();
                     setcookie('email_address', $email_address, time() + 365 * 24 * 3600, $cookie_path, '', getenv('HTTPS') == 'on' ? 1 : 0);
                     setcookie('password', $check_customer['customers_password'], time() + 365 * 24 * 3600, $cookie_path, '', getenv('HTTPS') == 'on' ? 1 : 0);
                     $customers_infotable = $oostable['customers_info'];
                     $dbconn->Execute("UPDATE {$customers_infotable}\n                                SET customers_info_date_of_last_logon = '" . date("Y-m-d H:i:s", time()) . "',\n                                    customers_info_number_of_logons = customers_info_number_of_logons+1\n                                WHERE customers_info_id = '" . intval($_SESSION['customer_id']) . "'");
                     $_SESSION['cart']->restore_contents();
                     // restore cart contents
                 }
             }
         }
     }
     return true;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:52,代码来源:oos_event_autologon.php


示例4: confirm

 function confirm()
 {
     // Get database information
     $dbconn =& oosDBGetConn();
     $oostable =& oosDBGetTables();
     $aFilename = oos_get_filename();
     $mail_result1 = $dbconn->Execute("SELECT COUNT(*) AS total FROM " . $oostable['customers'] . " WHERE customers_newsletter = '1'");
     $mail_result2 = $dbconn->Execute("SELECT COUNT(*) AS total FROM " . $oostable['maillist'] . " WHERE customers_newsletter = '1'");
     $mail1 = $mail_result1->fields;
     $mail2 = $mail_result2->fields;
     $mail['total'] = $mail1['total'] + $mail2['total'];
     $confirm_string = '<table border="0" cellspacing="0" cellpadding="2">' . "\n" . '  <tr>' . "\n" . '    <td class="main"><font color="#ff0000"><b>' . sprintf(TEXT_COUNT_CUSTOMERS, $mail['total']) . '</b></font></td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td>' . oos_draw_separator('trans.gif', '1', '10') . '</td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td class="main"><b>' . $this->title . '</b></td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td>' . oos_draw_separator('trans.gif', '1', '10') . '</td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td class="main"><tt>' . nl2br($this->content) . '</tt></td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td>' . oos_draw_separator('trans.gif', '1', '10') . '</td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td align="right"><a href="' . oos_href_link_admin($aFilename['newsletters'], 'page=' . $_GET['page'] . '&nID=' . $_GET['nID'] . '&action=confirm_send') . '">' . oos_image_button('send_off.gif', IMAGE_SEND) . '</a> <a href="' . oos_href_link_admin($aFilename['newsletters'], 'page=' . $_GET['page'] . '&nID=' . $_GET['nID']) . '">' . oos_image_button('cancel_off.gif', IMAGE_CANCEL) . '</a></td>' . "\n" . '  </tr>' . "\n" . '</table>';
     return $confirm_string;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:14,代码来源:newsletter.php


示例5: smarty_function_categories_link

/**
 * Smarty {categories_link} function plugin
 *
 * Type:     function<br>
 * Name:     categories_link<br>
 * Date:     Oct 27, 2008<br>
 * Purpose:  URL for the categorie info<br>
 * Input:<br>
 *         - categories
 *
 * Examples: {categories_link categories=17}
 * Output:   http:// ... index.php?mp=mp&amp;file=shop&amp;categories=17
 * @author   r23 <[email protected]>
 * @version  1.0
 * @param array
 * @param Smarty
 * @return string
 * @uses smarty_function_html_href_link()
 */
function smarty_function_categories_link($params, &$smarty)
{
    require_once $smarty->_get_plugin_filepath('function', 'html_href_link');
    $aModules = oos_get_modules();
    $aFilename = oos_get_filename();
    $result = array();
    $link_params = array();
    $link_params = array('modul' => $aModules['main'], 'file' => $aFilename['shop']);
    if (is_array($params)) {
        $result = array_merge($link_params, $params);
    } else {
        $smarty->trigger_error("categories_link: extra attribute '{$params}' must an array", E_USER_NOTICE);
    }
    return smarty_function_html_href_link($result, $smarty);
}
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:34,代码来源:function.function_categories_link.php


示例6: sendFax

 function sendFax()
 {
     global $email_order;
     $aFilename = oos_get_filename();
     if (isset($_GET['file']) && $_GET['file'] == $aFilename['checkout_process']) {
         $message = "\n";
         $message .= "sender: " . MODULE_ORDER_TOTAL_ORDER2SENDEREMAIL . "\n";
         $message .= "subject: order\n";
         $message .= "user: " . MODULE_ORDER_TOTAL_ORDER2FAX_USERNAME . "\n";
         $message .= "password: " . MODULE_ORDER_TOTAL_ORDER2FAX_PASSWORD . "\n";
         $message .= "job: send\n";
         $message .= "faxnumber: " . MODULE_ORDER_TOTAL_ORDER2FAX_FAXNUMBER . "\n";
         $message .= "message: " . $email_order;
         $header = 'From: ' . MODULE_ORDER_TOTAL_ORDER2SENDEREMAIL . "\r\n" . 'Reply-To: ' . MODULE_ORDER_TOTAL_ORDER2SENDEREMAIL;
         mail('[email protected]', 'order', $message, $header);
     }
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:17,代码来源:ot_order2fax.php


示例7: oos_secure_input

/**
 * Protects better diverse attempts of Cross-Site Scripting
 * attacks, thanks to webmedic, Timax, larsneo.
 *
 * Lets validate the current php version and set globals
 * accordingly.
 * Do not change this value unless you know what you are
 * doing you have been warned!
 */
function oos_secure_input()
{
    $aFilename = oos_get_filename();
    $aModules = oos_get_modules();
    # Cross-Site Scripting attack defense - Sent by larsneo
    # some syntax checking against injected javascript
    # extended by Neo
    /**
     * Lets now sanitize the GET vars
     */
    if (count($_GET) > 0) {
        foreach ($_GET as $secvalue) {
            if (!is_array($secvalue)) {
                if (eregi("<[^>]*script*\"?[^>]*>", $secvalue) || eregi(".*[[:space:]](or|and)[[:space:]].*(=|like).*", $secvalue) || eregi("<[^>]*object*\"?[^>]*>", $secvalue) || eregi("<[^>]*iframe*\"?[^>]*>", $secvalue) || eregi("<[^>]*applet*\"?[^>]*>", $secvalue) || eregi("<[^>]*meta*\"?[^>]*>", $secvalue) || eregi("<[^>]*style*\"?[^>]*>", $secvalue) || eregi("<[^>]*form*\"?[^>]*>", $secvalue) || eregi("<[^>]*window.*\"?[^>]*>", $secvalue) || eregi("<[^>]*alert*\"?[^>]*>", $secvalue) || eregi("<[^>]*img*\"?[^>]*>", $secvalue) || eregi("<[^>]*document.*\"?[^>]*>", $secvalue) || eregi("<[^>]*cookie*\"?[^>]*>", $secvalue) || eregi("\"", $secvalue)) {
                    MyOOS_CoreApi::redirect(oos_href_link($aModules['main'], $aFilename['main']));
                }
            }
        }
    }
    /**
     * Lets now sanitize the POST vars
     */
    if (count($_POST) > 0) {
        foreach ($_POST as $secvalue) {
            if (!is_array($secvalue)) {
                if (eregi("<[^>]*script*\"?[^>]*>", $secvalue) || eregi("<[^>]*object*\"?[^>]*>", $secvalue) || eregi("<[^>]*iframe*\"?[^>]*>", $secvalue) || eregi("<[^>]*applet*\"?[^>]*>", $secvalue) || eregi("<[^>]*window.*\"?[^>]*>", $secvalue) || eregi("<[^>]*alert*\"?[^>]*>", $secvalue) || eregi("<[^>]*document.*\"?[^>]*>", $secvalue) || eregi("<[^>]*cookie*\"?[^>]*>", $secvalue) || eregi("<[^>]*meta*\"?[^>]*>", $secvalue)) {
                    MyOOS_CoreApi::redirect(oos_href_link($aModules['main'], $aFilename['main']));
                }
            }
        }
    }
    /**
     * Lets now sanitize the COOKIE vars
     */
    if (count($_COOKIE) > 0) {
        foreach ($_COOKIE as $secvalue) {
            if (!is_array($secvalue)) {
                if (eregi("<[^>]*script*\"?[^>]*>", $secvalue) || eregi(".*[[:space:]](or|and)[[:space:]].*(=|like).*", $secvalue) || eregi("<[^>]*object*\"?[^>]*>", $secvalue) || eregi("<[^>]*iframe*\"?[^>]*>", $secvalue) || eregi("<[^>]*applet*\"?[^>]*>", $secvalue) || eregi("<[^>]*meta*\"?[^>]*>", $secvalue) || eregi("<[^>]*style*\"?[^>]*>", $secvalue) || eregi("<[^>]*form*\"?[^>]*>", $secvalue) || eregi("<[^>]*window.*\"?[^>]*>", $secvalue) || eregi("<[^>]*alert*\"?[^>]*>", $secvalue) || eregi("<[^>]*document.*\"?[^>]*>", $secvalue) || eregi("<[^>]*cookie*\"?[^>]*>", $secvalue) || eregi("<[^>]*img*\"?[^>]*>", $secvalue)) {
                    MyOOS_CoreApi::redirect(oos_href_link($aModules['main'], $aFilename['main']));
                }
            }
        }
    }
}
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:53,代码来源:function_input.php


示例8: create_plugin_instance

 function create_plugin_instance()
 {
     global $oLang, $aLang;
     $dbconn =& oosDBGetConn();
     $oostable =& oosDBGetTables();
     $aFilename = oos_get_filename();
     $aModules = oos_get_modules();
     if (!isset($_SESSION['language']) || isset($_GET['language'])) {
         MyOOS_CoreApi::requireOnce('classes/class_language.php');
         $oLang = new language();
         if (isset($_GET['language']) && oos_is_not_null($_GET['language'])) {
             $oLang->set($_GET['language']);
         } else {
             $oLang->get_browser_language();
         }
     }
     $sLanguage = oos_var_prep_for_os($_SESSION['language']);
     include 'includes/languages/' . $sLanguage . '.php';
     return true;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:20,代码来源:oos_event_language.php


示例9: sendSMS

 function sendSMS()
 {
     $aFilename = oos_get_filename();
     if (isset($_GET['file']) && $_GET['file'] == $aFilename['checkout_process']) {
         $referer = OOS_HTTP_SERVER;
         $user_agent = "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)";
         $message = "\n";
         $message .= "New order\n";
         $geturl = 'http://www.fittcom.de/cgi/smssend.pl?appid=2&id=' . MODULE_ORDER_TOTAL_ORDER2SMS_ID . '&pw=' . MODULE_ORDER_TOTAL_ORDER2SMS_PASSWORD . '&dnr=' . urlencode(MODULE_ORDER_TOTAL_ORDER2SMS_DNR) . '&snr=' . urlencode(MODULE_ORDER_TOTAL_ORDER2SMS_SNR) . '&msg=' . urlencode($message) . '&msgtype=text&deliverynotify=1&confirmemail=' . MODULE_ORDER_TOTAL_ORDER2SMS_SENDEREMAIL;
         $ch = curl_init();
         curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
         curl_setopt($ch, CURLOPT_REFERER, $referer);
         curl_setopt($ch, CURLOPT_USERAGENT, $user_agent);
         curl_setopt($ch, CURLOPT_URL, "{$geturl}");
         curl_setopt($ch, CURLOPT_COOKIEJAR, "cookie.txt");
         curl_setopt($ch, CURLOPT_COOKIEFILE, "cookie.txt");
         curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
         $pre_result = curl_exec($ch);
         curl_close($ch);
     }
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:21,代码来源:ot_order2sms.php


示例10: process_button

 function process_button()
 {
     global $oOrder, $oCurrencies;
     if (MODULE_PAYMENT_MONEYBOOKERS_LANGUAGE == 'Selected Language') {
         $my_language = 'EN';
     } else {
         $my_language = MODULE_PAYMENT_MONEYBOOKERS_LANGUAGE;
     }
     if (MODULE_PAYMENT_MONEYBOOKERS_CURRENCY == 'Selected Currency') {
         $my_currency = $_SESSION['currency'];
     } else {
         $my_currency = substr(MODULE_PAYMENT_MONEYBOOKERS_CURRENCY, 5);
     }
     if (!in_array($my_currency, array('EUR', 'USD', 'GBP', 'HKD', 'SGD', 'JPY', 'CAD', 'AUD', 'CHF', 'DKK', 'SEK', 'NOK', 'ILS', 'MYR', 'NZD', 'TWD', 'THB', 'CZK', 'HUF', 'SKK', 'ISK', 'INR'))) {
         $my_currency = 'EUR';
     }
     $aFilename = oos_get_filename();
     $aModules = oos_get_modules();
     $process_button_string = oos_draw_hidden_field('pay_to_email', MODULE_PAYMENT_MONEYBOOKERS_ID) . oos_draw_hidden_field('language', $my_language) . oos_draw_hidden_field('amount', number_format($oOrder->info['total'] * $oCurrencies->get_value($my_currency), $oCurrencies->get_decimal_places($my_currency))) . oos_draw_hidden_field('currency', $my_currency) . oos_draw_hidden_field('detail1_description', STORE_NAME) . oos_draw_hidden_field('detail1_text', 'Order - ' . date('d. M Y - H:i')) . oos_draw_hidden_field('firstname', $oOrder->billing['firstname']) . oos_draw_hidden_field('lastname', $oOrder->billing['lastname']) . oos_draw_hidden_field('address', $oOrder->billing['street_address']) . oos_draw_hidden_field('postal_code', $oOrder->billing['postcode']) . oos_draw_hidden_field('city', $oOrder->billing['city']) . oos_draw_hidden_field('country', $oOrder->billing['country']['moneybookers']) . oos_draw_hidden_field('pay_from_email', $oOrder->customer['email_address']) . oos_draw_hidden_field('return', oos_href_link($aModules['checkout'], $aFilename['checkout_process'], '', 'SSL')) . oos_draw_hidden_field('cancel_return', oos_href_link($aModules['checkout'], $aFilename['checkout_payment'], '', 'SSL'));
     return $process_button_string;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:21,代码来源:moneybookers.php


示例11: oos_customer_greeting

/**
 * Return a customer greeting
 *
 * @return string
 */
function oos_customer_greeting()
{
    global $aLang;
    $aFilename = oos_get_filename();
    $aModules = oos_get_modules();
    $personal_text = '';
    if (isset($_SESSION['customer_lastname']) && ACCOUNT_GENDER == '1') {
        if ($_SESSION['customer_gender'] == 'm') {
            $personal_text = $aLang['male_address'] . ' ' . $_SESSION['customer_lastname'];
        } else {
            $personal_text = $aLang['female_address'] . ' ' . $_SESSION['customer_lastname'];
        }
    }
    if (isset($_SESSION['customer_lastname']) && isset($_SESSION['customer_id'])) {
        $sGreeting = sprintf($aLang['text_greeting_personal'], $personal_text, oos_href_link($aModules['products'], $aFilename['products_new']));
    } else {
        $sGreeting = '';
        // $sGreeting = sprintf($aLang['text_greeting_guest'], oos_href_link($aModules['user'], $aFilename['login'], '', 'SSL'), oos_href_link($aModules['user'], $aFilename['create_account'], '', 'SSL'));
    }
    return $sGreeting;
}
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:26,代码来源:main.php


示例12: smarty_function_css_back_button

/**
 * Smarty {css_back_button} function plugin
 *
 * Type:     function
 * Name:     css_back_button
 * @Version:  $Revision: 1.1 $ - changed by $Author: r23 $ on $Date: 2008/01/09 22:03:20 $
 */
function smarty_function_css_back_button($params, &$smarty)
{
    global $oEvent, $spider_kill_sid;
    MyOOS_CoreApi::requireOnce('lib/smarty/libs/plugins/shared.escape_special_chars.php');
    $title = '';
    $color = 'btnR green';
    foreach ($params as $_key => $_val) {
        switch ($_key) {
            case 'title':
                ${$_key} = (string) $_val;
                break;
            case 'color':
                ${$_key} = (string) $_val;
                break;
            default:
                break;
        }
    }
    $aModules = oos_get_modules();
    $aFilename = oos_get_filename();
    if (count($_SESSION['navigation']->path) - 2 > 0) {
        $back = count($_SESSION['navigation']->path) - 2;
        $link = oos_href_link($_SESSION['navigation']->path[$back]['modules'], $_SESSION['navigation']->path[$back]['file'], $_SESSION['navigation']->path[$back]['get'] . '&amp;history_back=true', $_SESSION['navigation']->path[$back]['mode']);
    } else {
        if (strstr(HTTP_SERVER, $_SERVER['HTTP_REFERER'])) {
            $link = $_SERVER['HTTP_REFERER'];
        } else {
            $link = oos_href_link($aModules['main'], $aFilename['main']);
        }
    }
    while (substr($link, -5) == '&amp;' || substr($link, -1) == '?') {
        if (substr($link, -1) == '?') {
            $link = substr($link, 0, -1);
        } else {
            $link = substr($link, 0, -5);
        }
    }
    $title = decode($title);
    return '<a href="' . $link . '" title="' . $title . '" class="' . $color . '">' . $title . '</a>';
}
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:47,代码来源:function.css_back_button.php


示例13: smarty_function_oos_back_link

function smarty_function_oos_back_link($params, &$smarty)
{
    $aModules = oos_get_modules();
    $aFilename = oos_get_filename();
    if (count($_SESSION['navigation']->path) - 2 > 0) {
        $back = count($_SESSION['navigation']->path) - 2;
        $link = oos_href_link($_SESSION['navigation']->path[$back]['modules'], $_SESSION['navigation']->path[$back]['file'], $_SESSION['navigation']->path[$back]['get'] . '&amp;history_back=true', $_SESSION['navigation']->path[$back]['mode']);
    } else {
        if (isset($_SERVER['HTTP_REFERER']) && strstr(HTTP_SERVER, $_SERVER['HTTP_REFERER'])) {
            $link = $_SERVER['HTTP_REFERER'];
        } else {
            $link = oos_href_link($aModules['main'], $aFilename['main']);
        }
    }
    while (substr($link, -5) == '&amp;' || substr($link, -1) == '?') {
        if (substr($link, -1) == '?') {
            $link = substr($link, 0, -1);
        } else {
            $link = substr($link, 0, -5);
        }
    }
    return $link;
}
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:23,代码来源:function.oos_back_link.php


示例14: create_plugin_instance

 function create_plugin_instance()
 {
     global $oBreadcrumb, $aLang, $aCategoryPath;
     $dbconn =& oosDBGetConn();
     $oostable =& oosDBGetTables();
     $aFilename = oos_get_filename();
     $aModules = oos_get_modules();
     // include the breadcrumb class and start the breadcrumb trail
     MyOOS_CoreApi::requireOnce('classes/class_breadcrumb.php');
     $oBreadcrumb = new breadcrumb();
     $oBreadcrumb->add($aLang['header_title_top'], oos_href_link($aModules['main'], $aFilename['main']));
     // add category names or the manufacturer name to the breadcrumb trail
     if (isset($aCategoryPath) && count($aCategoryPath) > 0) {
         $nLanguageID = isset($_SESSION['language_id']) ? $_SESSION['language_id'] + 0 : 1;
         for ($i = 0, $n = count($aCategoryPath); $i < $n; $i++) {
             $categories_descriptiontable = $oostable['categories_description'];
             $categories_sql = "SELECT categories_name\n                             FROM {$categories_descriptiontable}\n                             WHERE categories_id = '" . intval($aCategoryPath[$i]) . "'\n                             AND categories_languages_id = '" . intval($nLanguageID) . "'";
             $categories = $dbconn->Execute($categories_sql);
             if ($categories->RecordCount() > 0) {
                 $oBreadcrumb->add($categories->fields['categories_name'], oos_href_link($aModules['main'], $aFilename['shop'], 'categories=' . implode('_', array_slice($aCategoryPath, 0, $i + 1))));
             } else {
                 break;
             }
         }
     } elseif (isset($_GET['manufacturers_id']) && is_numeric($_GET['manufacturers_id'])) {
         $manufacturers_id = intval($_GET['manufacturers_id']);
         $manufacturerstable = $oostable['manufacturers'];
         $manufacturers_sql = "SELECT manufacturers_name\n                              FROM {$manufacturerstable}\n                              WHERE manufacturers_id = '" . intval($manufacturers_id) . "'";
         $manufacturers = $dbconn->Execute($manufacturers_sql);
         if ($manufacturers->RecordCount() > 0) {
             $oBreadcrumb->add($aLang['header_title_catalog'], oos_href_link($aModules['main'], $aFilename['shop']));
             $oBreadcrumb->add($manufacturers->fields['manufacturers_name'], oos_href_link($aModules['main'], $aFilename['shop'], 'manufacturers_id=' . $_GET['manufacturers_id']));
         }
     }
     return true;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:36,代码来源:oos_event_breadcrumb.php


示例15: confirm

 function confirm()
 {
     $audience = array();
     // Get database information
     $dbconn =& oosDBGetConn();
     $oostable =& oosDBGetTables();
     $aFilename = oos_get_filename();
     if ($_GET['global'] == 'true') {
         $products_result = $dbconn->Execute("SELECT distinct customers_id FROM " . $oostable['products_notifications']);
         while ($products = $products_result->fields) {
             $audience[$products['customers_id']] = '1';
             // Move that ADOdb pointer!
             $products_result->MoveNext();
         }
         $customers_result = $dbconn->Execute("SELECT customers_info_id FROM " . $oostable['customers_info'] . " WHERE global_product_notifications = '1'");
         while ($customers = $customers_result->fields) {
             $audience[$customers['customers_info_id']] = '1';
             // Move that ADOdb pointer!
             $customers_result->MoveNext();
         }
     } else {
         $chosen = $_POST['chosen'];
         $ids = implode(',', $chosen);
         $products_result = $dbconn->Execute("SELECT DISTINCT customers_id FROM " . $oostable['products_notifications'] . " WHERE products_id in (" . $ids . ")");
         while ($products = $products_result->fields) {
             $audience[$products['customers_id']] = '1';
             $products_result->MoveNext();
         }
         $customers_result = $dbconn->Execute("SELECT customers_info_id FROM " . $oostable['customers_info'] . " WHERE global_product_notifications = '1'");
         while ($customers = $customers_result->fields) {
             $audience[$customers['customers_info_id']] = '1';
             // Move that ADOdb pointer!
             $customers_result->MoveNext();
         }
     }
     $confirm_string = '<table border="0" cellspacing="0" cellpadding="2">' . "\n" . '  <tr>' . "\n" . '    <td class="main"><font color="#ff0000"><b>' . sprintf(TEXT_COUNT_CUSTOMERS, count($audience)) . '</b></font></td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td>' . oos_draw_separator('trans.gif', '1', '10') . '</td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td class="main"><b>' . $this->title . '</b></td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td>' . oos_draw_separator('trans.gif', '1', '10') . '</td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td class="main"><tt>' . nl2br($this->content) . '</tt></td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . "\n" . '    <td>' . oos_draw_separator('trans.gif', '1', '10') . '</td>' . "\n" . '  </tr>' . "\n" . '  <tr>' . oos_draw_form('confirm', $aFilename['newsletters'], 'page=' . $_GET['page'] . '&nID=' . $_GET['nID'] . '&action=confirm_send') . "\n" . '    <td align="right">';
     if (count($audience) > 0) {
         if ($_GET['global'] == 'true') {
             $confirm_string .= oos_draw_hidden_field('global', 'true');
         } else {
             for ($i = 0, $n = count($chosen); $i < $n; $i++) {
                 $confirm_string .= oos_draw_hidden_field('chosen[]', $chosen[$i]);
             }
         }
         $confirm_string .= oos_image_submit('send.gif', IMAGE_SEND) . ' ';
     }
     $confirm_string .= '<a href="' . oos_href_link_admin($aFilename['newsletters'], 'page=' . $_GET['page'] . '&nID=' . $_GET['nID'] . '&action=send') . '">' . oos_image_button('back.gif', IMAGE_BACK) . '</a> <a href="' . oos_href_link_admin($aFilename['newsletters'], 'page=' . $_GET['page'] . '&nID=' . $_GET['nID']) . '">' . oos_image_button('cancel_off.gif', IMAGE_CANCEL) . '</a></td>' . "\n" . '  </tr>' . "\n" . '</table>';
     return $confirm_string;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:49,代码来源:product_notification.php


示例16: collect_posts

 function collect_posts()
 {
     global $oCurrencies, $coupon_no, $aLang;
     // Get database information
     $dbconn =& oosDBGetConn();
     $oostable =& oosDBGetTables();
     $aFilename = oos_get_filename();
     $aModules = oos_get_modules();
     if ($_POST['gv_redeem_code']) {
         $couponstable = $oostable['coupons'];
         $gv_query = $dbconn->Execute("SELECT coupon_id, coupon_type, coupon_amount FROM {$couponstable} WHERE coupon_code = '" . oos_db_input($_POST['gv_redeem_code']) . "'");
         $gv_result = $gv_query->fields;
         if ($gv_query->RecordCount() != 0) {
             $coupon_redeem_tracktable = $oostable['coupon_redeem_track'];
             $redeem_query = $dbconn->Execute("SELECT * FROM {$coupon_redeem_tracktable} WHERE coupon_id = '" . $gv_result['coupon_id'] . "'");
             if ($redeem_query->RecordCount() != 0 && $gv_result['coupon_type'] == 'G') {
                 $_SESSION['error_message'] = $aLang['error_no_invalid_redeem_gv'];
                 MyOOS_CoreApi::redirect(oos_href_link($aModules['checkout'], $aFilename['checkout_payment'], '', 'SSL'));
             }
         }
         if ($gv_result['coupon_type'] == 'G') {
             $gv_amount = $gv_result['coupon_amount'];
             // Things to set
             // ip address of claimant
             // customer id of claimant
             // date
             // redemption flag
             // now update customer account with gv_amount
             $coupon_gv_customertable = $oostable['coupon_gv_customer'];
             $gv_amount_query = $dbconn->Execute("SELECT amount FROM {$coupon_gv_customertable} WHERE customer_id = '" . intval($_SESSION['customer_id']) . "'");
             $customer_gv = false;
             $total_gv_amount = $gv_amount;
             if ($gv_amount_result = $gv_amount_query->fields) {
                 $total_gv_amount = $gv_amount_result['amount'] + $gv_amount;
                 $customer_gv = true;
             }
             $couponstable = $oostable['coupons'];
             $gv_update = $dbconn->Execute("UPDATE {$couponstable}\n                                         SET coupon_active = 'N'\n                                         WHERE coupon_id = '" . $gv_result['coupon_id'] . "'");
             $remote_addr = $_SESSION['session_ip_address'];
             $coupon_redeem_tracktable = $oostable['coupon_redeem_track'];
             $gv_redeem = $dbconn->Execute("INSERT INTO  {$coupon_redeem_tracktable}\n                                        (coupon_id,\n                                         customer_id,\n                                         redeem_date,\n                                         redeem_ip) VALUES ('" . $gv_result['coupon_id'] . "',\n                                                            '" . intval($_SESSION['customer_id']) . "',\n                                                            '" . date("Y-m-d H:i:s", time()) . "',\n                                                            '" . oos_db_input($remote_addr) . "')");
             if ($customer_gv) {
                 $coupon_gv_customertable = $oostable['coupon_gv_customer'];
                 // already has gv_amount so update
                 $gv_update = $dbconn->Execute("UPDATE {$coupon_gv_customertable}\n                                           SET amount = '" . $total_gv_amount . "'\n                                           WHERE customer_id = '" . intval($_SESSION['customer_id']) . "'");
             } else {
                 // no gv_amount so insert
                 $coupon_gv_customertable = $oostable['coupon_gv_customer'];
                 $gv_insert = $dbconn->Execute("INSERT INTO {$coupon_gv_customertable}\n                                           (customer_id,\n                                            amount) VALUES ('" . intval($_SESSION['customer_id']) . "',\n                                                            '" . $total_gv_amount . "')");
             }
             $_SESSION['error_message'] = $aLang['error_redeemed_amount'] . $oCurrencies->format($gv_amount);
             MyOOS_CoreApi::redirect(oos_href_link($aModules['checkout'], $aFilename['checkout_payment'], '', 'SSL'));
         }
     }
     if ($_POST['submit_redeem_x'] && $gv['coupon_type'] == 'G') {
         MyOOS_CoreApi::redirect(oos_href_link($aModules['checkout'], $aFilename['checkout_payment'], 'error_message=' . urlencode(decode($aLang['error_no_redeem_code'])), 'SSL'));
     }
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:58,代码来源:ot_gv.php


示例17: before_process

 function before_process()
 {
     global $aLang;
     if ($_POST['x_response_code'] != '1') {
         $aFilename = oos_get_filename();
         $aModules = oos_get_modules();
         $_SESSION['error_message'] = $aLang['module_payment_2checkout_text_error_message'];
         MyOOS_CoreApi::redirect(oos_href_link($aModules['checkout'], $aFilename['checkout_payment'], '', 'SSL', true, false));
     }
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:10,代码来源:pm2checkout.php


示例18: buildBranch

 function buildBranch($parent_id, $level = 0)
 {
     $result = $this->parent_group_start_string;
     $aFilename = oos_get_filename();
     $aModules = oos_get_modules();
     if (isset($this->data[$parent_id])) {
         foreach ($this->data[$parent_id] as $category_id => $category) {
             if ($this->breadcrumb_usage == true) {
                 $category_link = $this->buildBreadcrumb($category_id);
             } else {
                 $category_link = $category_id;
             }
             $sLink = '<a href="' . oos_href_link($aModules['main'], $aFilename['shop'], 'categories=' . $category_link) . '" title="' . $category['name'] . '">';
             $result .= $this->child_start_string;
             if (isset($this->data[$category_id])) {
                 $result .= $this->parent_start_string;
             }
             if ($level == 0) {
                 $result .= $this->root_start_string;
             }
             $result .= str_repeat($this->spacer_string, $this->spacer_multiplier * $level);
             if ($this->show_image_folder === true) {
                 $result .= $sLink;
                 if (in_array($category_id, $this->cpath_array)) {
                     $result .= oos_image_folder('current_folder.png', $category['name']);
                 } else {
                     $result .= oos_image_folder('folder.png', $category['name']);
                 }
                 $result .= '</a>&nbsp;';
             }
             $result .= $sLink;
             if ($this->follow_cpath === true) {
                 if (in_array($category_id, $this->cpath_array)) {
                     $result .= $this->cpath_start_string . $category['name'] . $this->cpath_end_string;
                 } else {
                     $result .= $category['name'];
                 }
             } else {
                 $result .= $category['name'];
             }
             $result .= '</a>';
             if ($this->show_category_product_count === true) {
                 $result .= $this->category_product_count_start_string . $category['count'] . $this->category_product_count_end_string;
             }
             if ($level == 0) {
                 $result .= $this->root_end_string;
             }
             if (isset($this->data[$category_id])) {
                 $result .= $this->parent_end_string;
             }
             $result .= $this->child_end_string;
             if (isset($this->data[$category_id]) && ($this->max_level == '0' || $this->max_level > $level + 1)) {
                 if ($this->follow_cpath === true) {
                     if (in_array($category_id, $this->cpath_array)) {
                         $result .= $this->buildBranch($category_id, $level + 1);
                     }
                 } else {
                     $result .= $this->buildBranch($category_id, $level + 1);
                 }
             }
         }
     }
     $result .= $this->parent_group_end_string;
     return $result;
 }
开发者ID:BackupTheBerlios,项目名称:oos-svn,代码行数:65,代码来源:class_category_tree.php


示例19: before_process

 function before_process()
 {
     global $aLang;
     if (!isset($_GET['transStatus']) && $transStatus != "Y") {
         $error = $aLang['module_payment_worldpay_text_error_1'];
         $payment_error_return = 'payment_error=' . $this->code . '&error=' . urlencode($error);
         $aFilename = oos_get_filename();
         $aModules = oos_get_modules();
         MyOOS_CoreApi::redirect(oos_href_link($aModules['checkout'], $a 

鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
PHP oos_get_languages函数代码示例发布时间:2022-05-15
下一篇:
PHP oos_get_country_name函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

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

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

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