Esempio n. 1
0
              </tr>
<?php 
    }
    ?>
            </table></td>
<?php 
    $heading = array();
    $contents = array();
    switch ($action) {
        case 'delete':
            $heading[] = array('text' => '<b>' . TEXT_HEADING_DELETE_AUTHOR . '</b>');
            $contents = array('form' => vam_draw_form('authors', FILENAME_AUTHORS, 'page=' . $_GET['page'] . '&auID=' . $auInfo->authors_id . '&action=deleteconfirm'));
            $contents[] = array('text' => TEXT_DELETE_INTRO);
            $contents[] = array('text' => '<br><b>' . $auInfo->authors_name . '</b>');
            if ($auInfo->articles_count > 0) {
                $contents[] = array('text' => '<br>' . vam_draw_checkbox_field('delete_articles') . ' ' . TEXT_DELETE_ARTICLES);
                $contents[] = array('text' => '<br>' . sprintf(TEXT_DELETE_WARNING_ARTICLES, $auInfo->articles_count));
            }
            $contents[] = array('align' => 'center', 'text' => '<br>' . '<span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span>' . ' <a class="button" href="' . vam_href_link(FILENAME_AUTHORS, 'page=' . $_GET['page'] . '&auID=' . $auInfo->authors_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
            break;
        default:
            if (isset($auInfo) && is_object($auInfo)) {
                $heading[] = array('text' => '<b>' . $auInfo->authors_name . '</b>');
                $contents[] = array('align' => 'center', 'text' => '<a class="button" href="' . vam_href_link(FILENAME_AUTHORS, 'page=' . $_GET['page'] . '&auID=' . $auInfo->authors_id . '&action=edit') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/edit.png', '', '12', '12') . '&nbsp;' . BUTTON_EDIT . '</span></a> <a class="button" href="' . vam_href_link(FILENAME_AUTHORS, 'page=' . $_GET['page'] . '&auID=' . $auInfo->authors_id . '&action=delete') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</span></a>');
                $contents[] = array('text' => '<br>' . TEXT_DATE_ADDED . ' ' . vam_date_short($auInfo->date_added));
                if (vam_not_null($auInfo->last_modified)) {
                    $contents[] = array('text' => TEXT_LAST_MODIFIED . ' ' . vam_date_short($auInfo->last_modified));
                }
                $contents[] = array('text' => '<br>' . TEXT_ARTICLES . ' ' . $auInfo->articles_count);
            }
            break;
Esempio n. 2
0
}
if (EP_MVS_SUPPORT == true) {
    $cells[$tmp_row_count][$tmp_col_count++] = array('text' => '<table border="0" cellpadding="0" cellspacing="0"><tr><td class="smallText">' . vam_draw_checkbox_field('epcust_vendor', 'show', !empty($_GET['epcust_vendor']) ? true : false) . '</td><td class="smallText"> ' . TEXT_EASYPOPULATE_LABEL_VENDOR . '</td></tr></table>');
}
if (EP_XSELL_SUPPORT == true) {
    $cells[$tmp_row_count][$tmp_col_count++] = array('text' => '<table border="0" cellpadding="0" cellspacing="0"><tr><td class="smallText">' . vam_draw_checkbox_field('epcust_cross_sell', 'show', !empty($_GET['epcust_cross_sell']) ? true : false) . '</td><td class="smallText"> ' . TEXT_EASYPOPULATE_LABEL_XSELL . '</td></tr></table>');
}
foreach ($custom_fields[TABLE_PRODUCTS] as $key => $name) {
    $cells[$tmp_row_count][$tmp_col_count++] = array('text' => '<table border="0" cellpadding="0" cellspacing="0"><tr><td class="smallText">' . vam_draw_checkbox_field('epcust_' . $key, 'show', !empty($_GET['epcust_' . $key]) ? true : false) . '</td><td class="smallText"> ' . $name . '</td></tr></table>');
    if ($tmp_col_count >= 7) {
        $tmp_row_count += 1;
        $tmp_col_count = 0;
    }
}
foreach ($custom_fields[TABLE_PRODUCTS_DESCRIPTION] as $key => $name) {
    $cells[$tmp_row_count][$tmp_col_count++] = array('text' => '<table border="0" cellpadding="0" cellspacing="0"><tr><td class="smallText">' . vam_draw_checkbox_field('epcust_' . $key, 'show', !empty($_GET['epcust_' . $key]) ? true : false) . '</td><td class="smallText"> ' . $name . '</td></tr></table>');
    if ($tmp_col_count >= 7) {
        $tmp_row_count += 1;
        $tmp_col_count = 0;
    }
}
$bigbox = new epbox('', false);
$bigbox->table_parameters = 'id="customtable" style="border: 1px solid #CCCCCC; padding: 2px; margin: 3px;"';
echo $bigbox->output($cells);
$manufacturers_array = array();
$manufacturers_array[] = array("id" => '', 'text' => TEXT_EASYPOPULATE_FILTER_MANUFACTURER);
$manufacturers_query = vam_db_query("select manufacturers_id, manufacturers_name from " . TABLE_MANUFACTURERS . " order by manufacturers_name");
while ($manufacturers = vam_db_fetch_array($manufacturers_query)) {
    $manufacturers_array[] = array("id" => $manufacturers['manufacturers_id'], 'text' => $manufacturers['manufacturers_name']);
}
$status_array = array(array("id" => '', 'text' => TEXT_EASYPOPULATE_FILTER_STATUS), array("id" => '1', 'text' => TEXT_EASYPOPULATE_FILTER_STATUS_ACTIVE), array("id" => '0', 'text' => TEXT_EASYPOPULATE_FILTER_STATUS_DISABLED));
        $state_input = vam_draw_pull_down_menuNote(array('name' => 'state', 'text' => '&nbsp;' . (vam_not_null(ENTRY_STATE_TEXT) ? '<span class="Requirement">' . ENTRY_STATE_TEXT . '</span>' : '')), $zones_array, vam_get_zone_name($entry['entry_country_id'], $entry['entry_zone_id'], $entry['entry_state']), ' id="state"');
    } else {
        $state_input = vam_draw_input_fieldNote(array('name' => 'state', 'text' => '&nbsp;' . (vam_not_null(ENTRY_STATE_TEXT) ? '<span class="Requirement">' . ENTRY_STATE_TEXT . '</span>' : '')), vam_get_zone_name(STORE_COUNTRY, STORE_ZONE), ' id="state"');
    }
    $module->assign('INPUT_STATE', $state_input);
} else {
    $module->assign('state', '0');
}
if ($_POST['country']) {
    $selected = $_POST['country'];
} else {
    $selected = $entry['entry_country_id'];
}
if (ACCOUNT_COUNTRY == 'true') {
    $module->assign('country', '1');
    if ($process == true) {
        $entry['entry_country_id'] = (int) $_POST['country'];
    }
    $module->assign('SELECT_COUNTRY', vam_get_country_list('country', $entry['entry_country_id'], 'id="country"') . (vam_not_null(ENTRY_COUNTRY_TEXT) ? '<span class="Requirement">' . ENTRY_COUNTRY_TEXT . '</span>' : ''));
    $module->assign('SELECT_COUNTRY_NOSCRIPT', '<noscript><br />' . vam_image_submit('update.png', IMAGE_BUTTON_UPDATE, 'name=loadStateXML') . '<br />' . ENTRY_STATE_RELOAD . '</noscript>');
} else {
    $vamTemplate->assign('country', '0');
}
if (isset($_GET['edit']) && $_SESSION['customer_default_address_id'] != $_GET['edit'] || isset($_GET['edit']) == false) {
    $module->assign('new', '1');
    $module->assign('CHECKBOX_PRIMARY', vam_draw_checkbox_field('primary', 'on', false, 'id="primary"'));
}
$module->assign('language', $_SESSION['language']);
$module->caching = 0;
$main_content = $module->fetch(CURRENT_TEMPLATE . '/module/address_book_details.html');
$vamTemplate->assign('MODULE_address_book_details', $main_content);
         if (mysql_num_rows($donequery) > 0) {
             $ttl = vam_db_fetch_array($donequery);
             if ($emailttl <= $ttl['dateadded']) {
                 $sentdate = $ttl['dateadded'];
                 $fcolor = $CONTACTED_COLOR;
             }
         }
         $ccquery = vam_db_query("select * from " . TABLE_ORDERS . " where customers_id = '" . $curcus . "'");
         if (mysql_num_rows($ccquery) > 0) {
             $customer = '&nbsp;[<font color="' . $CURCUST_COLOR . '">' . TEXT_CURRENT_CUSTOMER . '</font>]';
         }
         $sentInfo = TEXT_NOT_CONTACTED;
         if ($sentdate != '') {
             $sentInfo = cart_date_short($sentdate);
         }
         $cline = "\n        <tr bgcolor=" . $fcolor . ">\n          <td class='dataTableContent' align='center' width='1%'>" . vam_draw_checkbox_field('custid[]', $curcus) . "</td>\n          <td class='dataTableContent' align='left' width='9%' nowrap><b>" . $sentInfo . "</b></td>\n          <td class='dataTableContent' align='left' width='15%' nowrap> " . cart_date_short($inrec['bdate']) . "</td>\n          <td class='dataTableContent' align='left' width='30%' nowrap><a href='" . vam_href_link(FILENAME_CUSTOMERS, 'search=' . $inrec['lname'], 'NONSSL') . "'>" . $inrec['fname'] . " " . $inrec['lname'] . "</a>" . $customer . "</td>\n          <td class='dataTableContent' align='left' colspan='2' width='30%' nowrap><a href='" . vam_href_link('mail.php', 'selected_box=tools&customer=' . $inrec['email']) . "'>" . $inrec['email'] . "</a></td>\n          <td class='dataTableContent' align='left' colspan='2' width='15%' nowrap>" . $inrec['phone'] . "</td>\n        </tr>";
     }
 }
 // empty the shopping cart
 $query2 = vam_db_query("select  p.products_price price,\n                                    p.products_model model,\n                                    pd.products_name name\n                            from    " . TABLE_PRODUCTS . " p,\n                                    " . TABLE_PRODUCTS_DESCRIPTION . " pd,\n                                    " . TABLE_LANGUAGES . " l\n                            where   p.products_id = '" . $inrec['pid'] . "' and\n                                    pd.products_id = p.products_id and\n                                    pd.language_id = '" . $_SESSION['languages_id'] . "' ");
 $inrec2 = vam_db_fetch_array($query2);
 // BEGIN OF ATTRIBUTE DB CODE
 $prodAttribs = '';
 // DO NOT DELETE
 if ($SHOW_ATTRIBUTES) {
     $attribquery = vam_db_query("select  cba.products_id pid,\n                                           po.products_options_name poname,\n                                           pov.products_options_values_name povname\n                                   from    " . TABLE_CUSTOMERS_BASKET_ATTRIBUTES . " cba,\n                                           " . TABLE_PRODUCTS_OPTIONS . " po,\n                                           " . TABLE_PRODUCTS_OPTIONS_VALUES . " pov,\n                                           " . TABLE_LANGUAGES . " l\n                                   where   cba.products_id ='" . $inrec['pid'] . "' and\n                                           po.products_options_id = cba.products_options_id and\n                                           pov.products_options_values_id = cba.products_options_value_id and\n                                           po.language_id = '" . $_SESSION['languages_id'] . "' and\n                                           pov.language_id = '" . $_SESSION['languages_id'] . "'\n                                ");
     $hasAttributes = false;
     if (vam_db_num_rows($attribquery)) {
         $hasAttributes = true;
         $prodAttribs = '<br>';
         while ($attribrecs = vam_db_fetch_array($attribquery)) {
</td>
                  </tr>
                </table></td>
              </tr>
            </table></td>
<?php 
    $heading = array();
    $contents = array();
    switch ($_GET['action']) {
        case 'delete':
            $heading[] = array('text' => '<b>' . $bInfo->banners_title . '</b>');
            $contents = array('form' => vam_draw_form('banners', FILENAME_BANNER_MANAGER, 'page=' . $_GET['page'] . '&bID=' . $bInfo->banners_id . '&action=deleteconfirm'));
            $contents[] = array('text' => TEXT_INFO_DELETE_INTRO);
            $contents[] = array('text' => '<br /><b>' . $bInfo->banners_title . '</b>');
            if ($bInfo->banners_image) {
                $contents[] = array('text' => '<br />' . vam_draw_checkbox_field('delete_image', 'on', true) . ' ' . TEXT_INFO_DELETE_IMAGE);
            }
            $contents[] = array('align' => 'center', 'text' => '<br /><span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span>&nbsp;<a class="button" href="' . vam_href_link(FILENAME_BANNER_MANAGER, 'page=' . $_GET['page'] . '&bID=' . $_GET['bID']) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
            break;
        default:
            if (is_object($bInfo)) {
                $heading[] = array('text' => '<b>' . $bInfo->banners_title . '</b>');
                $contents[] = array('align' => 'center', 'text' => '<a class="button" href="' . vam_href_link(FILENAME_BANNER_MANAGER, 'page=' . $_GET['page'] . '&bID=' . $bInfo->banners_id . '&action=new') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/edit.png', '', '12', '12') . '&nbsp;' . BUTTON_EDIT . '</span></a> <a class="button" href="' . vam_href_link(FILENAME_BANNER_MANAGER, 'page=' . $_GET['page'] . '&bID=' . $bInfo->banners_id . '&action=delete') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</span></a>');
                $contents[] = array('text' => '<br />' . TEXT_BANNERS_DATE_ADDED . ' ' . vam_date_short($bInfo->date_added));
                if (function_exists('imagecreate') && $dir_ok && $banner_extension) {
                    $banner_id = $bInfo->banners_id;
                    $days = '3';
                    include DIR_WS_INCLUDES . 'graphs/banner_infobox.php';
                    $contents[] = array('align' => 'center', 'text' => '<br />' . vam_image(DIR_WS_IMAGES . 'graphs/banner_infobox-' . $banner_id . '.' . $banner_extension));
                } else {
                    include DIR_WS_FUNCTIONS . 'html_graphs.php';
    $vamTemplate->assign('gender', '0');
}
$vamTemplate->assign('INPUT_FIRSTNAME', vam_draw_input_fieldNote(array('name' => 'firstname', 'text' => '&nbsp;' . (vam_not_null(ENTRY_FIRST_NAME_TEXT) ? '<span class="Requirement">' . ENTRY_FIRST_NAME_TEXT . '</span>' : '')), '', 'id="firstname"'));
if (ACCOUNT_SECOND_NAME == 'true') {
    $vamTemplate->assign('secondname', '1');
    $vamTemplate->assign('INPUT_SECONDNAME', vam_draw_input_fieldNote(array('name' => 'secondname', 'text' => '&nbsp;' . (vam_not_null(ENTRY_SECOND_NAME_TEXT) ? '<span class="Requirement">' . ENTRY_SECOND_NAME_TEXT . '</span>' : '')), '', 'id="secondname"'));
}
$vamTemplate->assign('INPUT_LASTNAME', vam_draw_input_fieldNote(array('name' => 'lastname', 'text' => '&nbsp;' . (vam_not_null(ENTRY_LAST_NAME_TEXT) ? '<span class="Requirement">' . ENTRY_LAST_NAME_TEXT . '</span>' : '')), '', 'id="lastname"'));
if (ACCOUNT_DOB == 'true') {
    $vamTemplate->assign('birthdate', '1');
    $vamTemplate->assign('INPUT_DOB', vam_draw_input_fieldNote(array('name' => 'dob', 'text' => '&nbsp;' . (vam_not_null(ENTRY_DATE_OF_BIRTH_TEXT) ? '<span class="Requirement">' . ENTRY_DATE_OF_BIRTH_TEXT . '</span>' : '')), '', 'id="dob"'));
} else {
    $vamTemplate->assign('birthdate', '0');
}
$vamTemplate->assign('INPUT_EMAIL', vam_draw_input_fieldNote(array('name' => 'email_address', 'text' => '&nbsp;' . (vam_not_null(ENTRY_EMAIL_ADDRESS_TEXT) ? '<span class="Requirement">' . ENTRY_EMAIL_ADDRESS_TEXT . '</span>' : '')), '', 'id="email_address"'));
$vamTemplate->assign('INPUT_NEWSLETTER', vam_draw_checkbox_field('newsletter', '1', true));
if (ACCOUNT_COMPANY == 'true') {
    $vamTemplate->assign('company', '1');
    $vamTemplate->assign('INPUT_COMPANY', vam_draw_input_fieldNote(array('name' => 'company', 'text' => '&nbsp;' . (vam_not_null(ENTRY_COMPANY_TEXT) ? '<span class="Requirement">' . ENTRY_COMPANY_TEXT . '</span>' : ''))));
} else {
    $vamTemplate->assign('company', '0');
}
if (ACCOUNT_COMPANY_VAT_CHECK == 'true') {
    $vamTemplate->assign('vat', '1');
    $vamTemplate->assign('INPUT_VAT', vam_draw_input_fieldNote(array('name' => 'vat', 'text' => '&nbsp;' . (vam_not_null(ENTRY_VAT_TEXT) ? '<span class="Requirement">' . ENTRY_VAT_TEXT . '</span>' : ''))));
} else {
    $vamTemplate->assign('vat', '0');
}
if (ACCOUNT_STREET_ADDRESS == 'true') {
    $vamTemplate->assign('street_address', '1');
    $vamTemplate->assign('INPUT_STREET', vam_draw_input_fieldNote(array('name' => 'street_address', 'text' => '&nbsp;' . (vam_not_null(ENTRY_STREET_ADDRESS_TEXT) ? '<span class="Requirement">' . ENTRY_STREET_ADDRESS_TEXT . '</span>' : '')), '', 'id="street_address"'));
   </tr>
   <tr>
        <td width="10%"><?php 
        echo TEXT_TO;
        ?>
</td>
        <td width="90%"><?php 
        for ($i = 0, $n = sizeof($customers_status); $i < $n; $i++) {
            $group_query = vam_db_query("SELECT count(*) as count\n                                FROM " . TABLE_NEWSLETTER_RECIPIENTS . "\n                                WHERE mail_status='1' and\n                                customers_status='" . $customers_status[$i]['id'] . "'");
            $group_data = vam_db_fetch_array($group_query);
            $group_query = vam_db_query("SELECT count(*) as count\n                                FROM " . TABLE_CUSTOMERS . "\n                                WHERE\n                                customers_status='" . $customers_status[$i]['id'] . "'");
            $group_data_all = vam_db_fetch_array($group_query);
            $bc_array = explode(',', $newsletters_data['bc']);
            echo vam_draw_checkbox_field('status[' . $i . ']', 'yes', in_array($customers_status[$i]['id'], $bc_array)) . ' ' . $customers_status[$i]['text'] . '  <i>(<b>' . $group_data['count'] . '</b> ' . TEXT_USERS . $group_data_all['count'] . TEXT_CUSTOMERS . '<br />';
        }
        echo vam_draw_checkbox_field('status_all', 'yes', in_array('all', $bc_array)) . ' <b>' . TEXT_NEWSLETTER_ONLY . '</b>';
        ?>
</td>
   </tr>
        <tr>
        <td width="10%"><?php 
        echo TEXT_CC;
        ?>
</td>
        <td width="90%"><?php 
        echo vam_draw_input_field('cc', $newsletters_data['cc'], 'size=100');
        ?>
</td>
   </tr>
        </tr>
        <tr>
                 $contents[] = array('text' => '<tr><td class="infoBoxContent">' . sprintf(TEXT_DELETE_WARNING_PRODUCTS, $cInfo->products_count) . '</td></tr>');
             }
         }
     }
     if (is_array($_POST['multi_products'])) {
         foreach ($_POST['multi_products'] as $multi_product) {
             $contents[] = array('text' => '<tr><td style="border-bottom: 1px solid Black; margin-bottom: 10px;" class="infoBoxContent"><b>' . vam_get_products_name($multi_product) . '</b></td></tr>');
             $product_categories_string = '';
             $product_categories = vam_generate_category_path($multi_product, 'product');
             for ($i = 0, $n = sizeof($product_categories); $i < $n; $i++) {
                 $category_path = '';
                 for ($j = 0, $k = sizeof($product_categories[$i]); $j < $k; $j++) {
                     $category_path .= $product_categories[$i][$j]['text'] . '&nbsp;&gt;&nbsp;';
                 }
                 $category_path = substr($category_path, 0, -16);
                 $product_categories_string .= vam_draw_checkbox_field('multi_products_categories[' . $multi_product . '][]', $product_categories[$i][sizeof($product_categories[$i]) - 1]['id'], true) . '&nbsp;' . $category_path . '<br />';
             }
             $product_categories_string = substr($product_categories_string, 0, -4);
             $product_categories_string = '<tr><td class="infoBoxContent">' . $product_categories_string . '</td></tr>';
             $contents[] = array('text' => $product_categories_string);
         }
     }
     //close list table
     $contents[] = array('text' => '</table>');
     $contents[] = array('align' => 'center', 'text' => '<span class="button"><button type="submit" name="multi_delete_confirm" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span> <a class="button" href="' . vam_href_link(FILENAME_CATEGORIES, vam_get_all_get_params(array('cPath', 'action', 'pID', 'cID')) . 'cPath=' . $cPath . '&pID=' . $pInfo->products_id . '&cID=' . $cInfo->categories_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     //close multi-action form
     $contents[] = array('text' => '</form>');
 }
 // multi_delete confirm ENDS
 // --------------------
 // multi_copy confirm
Esempio n. 9
0
     $contents[] = array('align' => 'center', 'text' => '<br>' . '<span class="button"><button type="submit" value="' . BUTTON_MOVE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/move.png', '', '12', '12') . '&nbsp;' . BUTTON_MOVE . '</button></span>' . ' <a class="button" href="' . vam_href_link(FILENAME_ARTICLES, 'tPath=' . $tPath . '&tID=' . $tInfo->topics_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'delete_article':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_DELETE_ARTICLE . '</b>');
     $contents = array('form' => vam_draw_form('articles', FILENAME_ARTICLES, 'action=delete_article_confirm&tPath=' . $tPath) . vam_draw_hidden_field('articles_id', $aInfo->articles_id));
     $contents[] = array('text' => TEXT_DELETE_ARTICLE_INTRO);
     $contents[] = array('text' => '<br><b>' . $aInfo->articles_name . '</b>');
     $article_topics_string = '';
     $article_topics = vam_generate_topic_path($aInfo->articles_id, 'article');
     for ($i = 0, $n = sizeof($article_topics); $i < $n; $i++) {
         $topic_path = '';
         for ($j = 0, $k = sizeof($article_topics[$i]); $j < $k; $j++) {
             $topic_path .= $article_topics[$i][$j]['text'] . '&nbsp;&gt;&nbsp;';
         }
         $topic_path = substr($topic_path, 0, -16);
         $article_topics_string .= vam_draw_checkbox_field('article_topics[]', $article_topics[$i][sizeof($article_topics[$i]) - 1]['id'], true) . '&nbsp;' . $topic_path . '<br>';
     }
     $article_topics_string = substr($article_topics_string, 0, -4);
     $contents[] = array('text' => '<br>' . $article_topics_string);
     $contents[] = array('align' => 'center', 'text' => '<br>' . '<span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span>' . ' <a class="button" href="' . vam_href_link(FILENAME_ARTICLES, 'tPath=' . $tPath . '&aID=' . $aInfo->articles_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'move_article':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_MOVE_ARTICLE . '</b>');
     $contents = array('form' => vam_draw_form('articles', FILENAME_ARTICLES, 'action=move_article_confirm&tPath=' . $tPath) . vam_draw_hidden_field('articles_id', $aInfo->articles_id));
     $contents[] = array('text' => sprintf(TEXT_MOVE_ARTICLES_INTRO, $aInfo->articles_name));
     $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENT_TOPICS . '<br><b>' . vam_output_generated_topic_path($aInfo->articles_id, 'article') . '</b>');
     $contents[] = array('text' => '<br>' . sprintf(TEXT_MOVE, $aInfo->articles_name) . '<br>' . vam_draw_pull_down_menu('move_to_topic_id', vam_get_topic_tree(), $current_topic_id));
     $contents[] = array('align' => 'center', 'text' => '<br>' . '<span class="button"><button type="submit" value="' . BUTTON_MOVE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/move.png', '', '12', '12') . '&nbsp;' . BUTTON_MOVE . '</button></span>' . ' <a class="button" href="' . vam_href_link(FILENAME_ARTICLES, 'tPath=' . $tPath . '&aID=' . $aInfo->articles_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'copy_to':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_COPY_TO . '</b>');
         $contents[] = array('text' => '<br />' . sprintf(TEXT_DELETE_WARNING_SPECS, $count_specs));
     }
     if ($count_products > 0) {
         $contents[] = array('text' => '<br />' . sprintf(TEXT_DELETE_WARNING_PRODUCTS, $count_products));
     }
     if ($count_filters > 0) {
         $contents[] = array('text' => '<br />' . sprintf(TEXT_DELETE_WARNING_FILTERS, $count_filters));
     }
     $contents[] = array('align' => 'center', 'text' => '<br />' . '<span class="button"><button type="submit" value="' . IMAGE_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . IMAGE_DELETE . '</button></span>' . ' <a class="button" href="' . vam_href_link(FILENAME_PRODUCTS_SPECIFICATIONS, 'sgid=' . $cInfo->specification_group_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . IMAGE_CANCEL . '</span></a>');
     break;
 case 'link_category':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_LINK_CATEGORY . '</b>');
     $contents = array('form' => vam_draw_form('link_category_confirm', FILENAME_PRODUCTS_SPECIFICATIONS, 'action=link_category_confirm'));
     $contents[] = array('text' => sprintf(TEXT_LINK_CATEGORIES_INTRO, $cInfo->categories_name) . vam_draw_hidden_field('specification_group_id', $cInfo->specification_group_id));
     $contents[] = array('text' => '<br />' . TEXT_LINK_TO . '<br />' . vam_draw_pull_down_menu('link_category_id', vam_get_category_tree()));
     $contents[] = array('text' => vam_draw_checkbox_field('link_subcats', 'True') . ' ' . TEXT_LINK_TO_SUBCATS);
     $contents[] = array('align' => 'center', 'text' => '<br />' . '<span class="button"><button type="submit" value="' . IMAGE_LINK . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . IMAGE_LINK . '</button></span>' . ' <a class="button" href="' . vam_href_link(FILENAME_PRODUCTS_SPECIFICATIONS, 'sgid=' . $cInfo->specification_group_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . IMAGE_CANCEL . '</span></a>');
     break;
 case 'link_all_categories':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_LINK_ALL_CATEGORIES . '</b>');
     $contents = array('form' => vam_draw_form('link_all_categories', FILENAME_PRODUCTS_SPECIFICATIONS, 'action=link_all_categories_confirm'));
     $contents[] = array('text' => TEXT_LINK_ALL_INTRO . vam_draw_hidden_field('specification_group_id', $cInfo->specification_group_id));
     $contents[] = array('align' => 'center', 'text' => '<br />' . '<span class="button"><button type="submit" value="' . IMAGE_LINK_ALL . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . IMAGE_LINK_ALL . '</button></span>' . ' <a class="button" href="' . vam_href_link(FILENAME_PRODUCTS_SPECIFICATIONS, 'sgid=' . $cInfo->specification_group_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . IMAGE_CANCEL . '</span></a>');
     break;
 case 'unlink_category':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_UNLINK_CATEGORY . '</b>');
     $contents = array('form' => vam_draw_form('categories', FILENAME_PRODUCTS_SPECIFICATIONS, 'action=unlink_category_confirm'));
     $contents[] = array('text' => TEXT_UNLINK_INTRO . vam_draw_hidden_field('specification_group_id', $cInfo->specification_group_id));
     $contents[] = array('text' => TEXT_UNLINK_CATEGORY . '<br />' . vam_draw_pull_down_menu('categories_id', $categories_list));
     $contents[] = array('align' => 'center', 'text' => '<br />' . '<span class="button"><button type="submit" value="' . IMAGE_UNLINK . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . IMAGE_UNLINK . '</button></span>' . ' <a class="button" href="' . vam_href_link(FILENAME_PRODUCTS_SPECIFICATIONS, 'sgid=' . $cInfo->specification_group_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . IMAGE_CANCEL . '</span></a>');
     break;
Esempio n. 11
0
     $manufacturer_inputs_string = '';
     $languages = vam_get_languages();
     for ($i = 0, $n = sizeof($languages); $i < $n; $i++) {
         $manufacturer_inputs_string .= '<br />' . $languages[$i]['name'] . '&nbsp;' . vam_draw_input_field('manufacturers_url[' . $languages[$i]['id'] . ']', vam_get_manufacturer_url($mInfo->manufacturers_id, $languages[$i]['id']));
     }
     $contents[] = array('text' => '<br />' . TEXT_MANUFACTURERS_URL . $manufacturer_inputs_string);
     $contents[] = array('align' => 'center', 'text' => '<br />' . '<span class="button"><button type="submit" value="' . BUTTON_SAVE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/save.png', '', '12', '12') . '&nbsp;' . BUTTON_SAVE . '</button></span>' . '&nbsp;' . '<a class="button" href="' . vam_href_link(FILENAME_MANUFACTURERS, 'page=' . $_GET['page'] . '&mID=' . $mInfo->manufacturers_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'delete':
     $heading[] = array('text' => '<b>' . TEXT_HEADING_DELETE_MANUFACTURER . '</b>');
     $contents = array('form' => vam_draw_form('manufacturers', FILENAME_MANUFACTURERS, 'page=' . $_GET['page'] . '&mID=' . $mInfo->manufacturers_id . '&action=deleteconfirm'));
     $contents[] = array('text' => TEXT_DELETE_INTRO);
     $contents[] = array('text' => '<br /><b>' . $mInfo->manufacturers_name . '</b>');
     $contents[] = array('text' => '<br />' . vam_draw_checkbox_field('delete_image', '', true) . ' ' . TEXT_DELETE_IMAGE);
     if ($mInfo->products_count > 0) {
         $contents[] = array('text' => '<br />' . vam_draw_checkbox_field('delete_products') . ' ' . TEXT_DELETE_PRODUCTS);
         $contents[] = array('text' => '<br />' . sprintf(TEXT_DELETE_WARNING_PRODUCTS, $mInfo->products_count));
     }
     $contents[] = array('align' => 'center', 'text' => '<br />' . '<span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span>' . '&nbsp;' . '<a class="button" href="' . vam_href_link(FILENAME_MANUFACTURERS, 'page=' . $_GET['page'] . '&mID=' . $mInfo->manufacturers_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 default:
     if (is_object($mInfo)) {
         $heading[] = array('text' => '<b>' . $mInfo->manufacturers_name . '</b>');
         $contents[] = array('align' => 'center', 'text' => '<a class="button" href="' . vam_href_link(FILENAME_MANUFACTURERS, 'page=' . $_GET['page'] . '&mID=' . $mInfo->manufacturers_id . '&action=edit') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/edit.png', '', '12', '12') . '&nbsp;' . BUTTON_EDIT . '</span></a>' . '&nbsp;' . '<a class="button" href="' . vam_href_link(FILENAME_MANUFACTURERS, 'page=' . $_GET['page'] . '&mID=' . $mInfo->manufacturers_id . '&action=delete') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</span></a>');
         $contents[] = array('text' => '<br />' . TEXT_DATE_ADDED . ' ' . vam_date_short($mInfo->date_added));
         if (vam_not_null($mInfo->last_modified)) {
             $contents[] = array('text' => TEXT_LAST_MODIFIED . ' ' . vam_date_short($mInfo->last_modified));
         }
         $contents[] = array('text' => '<br />' . vam_info_image($mInfo->manufacturers_image, $mInfo->manufacturers_name));
         $contents[] = array('text' => '<br />' . TEXT_PRODUCTS . ' ' . $mInfo->products_count);
     }
      <td width="90%"><?php 
            echo vam_draw_input_field('sort_order', $content['sort_order'], 'size="5"');
            ?>
</td>
    </tr>

      <tr> 
      <td valign="top" width="10%"><?php 
            echo TEXT_STATUS;
            ?>
</td>
      <td width="90%"><?php 
            if ($content['content_status'] == '1') {
                echo vam_draw_checkbox_field('status', 'yes', true) . ' ' . TEXT_STATUS_DESCRIPTION;
            } else {
                echo vam_draw_checkbox_field('status', 'yes', false) . ' ' . TEXT_STATUS_DESCRIPTION;
            }
            ?>
<br /><br /></td>
   </tr>

          <?php 
            if (GROUP_CHECK == 'true') {
                $customers_statuses_array = vam_get_customers_statuses();
                $customers_statuses_array = array_merge(array(array('id' => 'all', 'text' => TXT_ALL)), $customers_statuses_array);
                ?>
<tr>
<td style="border-top: 1px solid; border-color: #ff0000;" valign="top" class="main" ><?php 
                echo ENTRY_CUSTOMERS_STATUS;
                ?>
</td>
echo TABLE_HEADING_LANGUAGE;
?>
</td>
        <td class="dataTableHeadingContent" align="center"><?php 
echo TABLE_HEADING_STATUS;
?>
</td>
       </tr>
<?php 
$products_extra_fields_query = vam_db_query("SELECT * FROM " . TABLE_PRODUCTS_EXTRA_FIELDS . " ORDER BY products_extra_fields_order");
while ($extra_fields = vam_db_fetch_array($products_extra_fields_query)) {
    ?>
       <tr>
        <td width="20">
         <?php 
    echo vam_draw_checkbox_field('mark[' . $extra_fields['products_extra_fields_id'] . ']', 1);
    ?>
        </td>
        <td class="dataTableContent">
         <?php 
    echo vam_draw_input_field('field[' . $extra_fields['products_extra_fields_id'] . '][name]', $extra_fields['products_extra_fields_name'], 'size=30', false, 'text', true);
    ?>
        </td>
		<td class="dataTableContent" align="center">
         <?php 
    echo vam_draw_input_field('field[' . $extra_fields['products_extra_fields_id'] . '][order]', $extra_fields['products_extra_fields_order'], 'size=5', false, 'text', true);
    ?>
        </td>
		<td class="dataTableContent" align="center">
		 <?php 
    echo vam_draw_pull_down_menu('field[' . $extra_fields['products_extra_fields_id'] . '][language]', $values, $extra_fields['languages_id'], '');
Esempio n. 14
0
 function selection()
 {
     global $order;
     $selection = array('id' => $this->code, 'module' => $this->title, 'description' => $this->info, 'fields' => array(array('title' => MODULE_PAYMENT_BANKTRANSFER_TEXT_NOTE, 'field' => MODULE_PAYMENT_BANKTRANSFER_TEXT_BANK_INFO), array('title' => MODULE_PAYMENT_BANKTRANSFER_TEXT_BANK_OWNER, 'field' => vam_draw_input_field('banktransfer_owner', $order->billing['firstname'] . ' ' . $order->billing['lastname'])), array('title' => MODULE_PAYMENT_BANKTRANSFER_TEXT_BANK_BLZ, 'field' => vam_draw_input_field('banktransfer_blz', $_GET['banktransfer_blz'], 'size="8" maxlength="8"')), array('title' => MODULE_PAYMENT_BANKTRANSFER_TEXT_BANK_NUMBER, 'field' => vam_draw_input_field('banktransfer_number', $_GET['banktransfer_number'], 'size="16" maxlength="32"')), array('title' => MODULE_PAYMENT_BANKTRANSFER_TEXT_BANK_NAME, 'field' => vam_draw_input_field('banktransfer_bankname')), array('title' => '', 'field' => vam_draw_hidden_field('recheckok', $_POST['recheckok']))));
     if (MODULE_PAYMENT_BANKTRANSFER_FAX_CONFIRMATION == 'true') {
         $selection['fields'][] = array('title' => MODULE_PAYMENT_BANKTRANSFER_TEXT_NOTE, 'field' => MODULE_PAYMENT_BANKTRANSFER_TEXT_NOTE2 . '<a href="' . MODULE_PAYMENT_BANKTRANSFER_URL_NOTE . '" target="_blank"><b>' . MODULE_PAYMENT_BANKTRANSFER_TEXT_NOTE3 . '</b></a>' . MODULE_PAYMENT_BANKTRANSFER_TEXT_NOTE4);
         $selection['fields'][] = array('title' => MODULE_PAYMENT_BANKTRANSFER_TEXT_BANK_FAX, 'field' => vam_draw_checkbox_field('banktransfer_fax', 'on'));
     }
     return $selection;
 }
Esempio n. 15
0
     } else {
         echo "<td align=\"center\">" . $manufacturer['manufacturers_name'] . "</td>";
     }
 } else {
     echo "<td>&nbsp;</td>";
 }
 //// check specials
 if (in_array($products['products_id'], $specials_array)) {
     echo "<td align=\"center\">&nbsp;<input type=\"text\" size=\"6\" name=\"product_new_price[" . $products['products_id'] . "]\" value=\"" . $products['products_price'] . "\" disabled >&nbsp;<a href=\"" . vam_href_link(FILENAME_SPECIALS) . "\">" . vam_image(DIR_WS_IMAGES . 'icon_info.gif', TEXT_SPECIALS_PRODUCTS) . "</a></td>\n";
 } else {
     if ($flag_spec == 'true') {
         echo "<td align=\"center\">&nbsp;<input type=\"text\" size=\"6\" name=\"product_new_price[" . $products['products_id'] . "]\" ";
         if (DISPLAY_TVA_UP == 'true') {
             echo "onKeyUp=\"display_ttc('keyup', this.value" . ", " . $tax_rate['tax_rate'] . ", 1);\"";
         }
         echo " value=\"" . $price . "\">" . vam_draw_checkbox_field('update_price[' . $products['products_id'] . ']', 'yes', 'checked', 'no') . "</td>\n";
     } else {
         echo "<td align=\"center\">&nbsp;<input type=\"text\" size=\"6\" name=\"product_new_price[" . $products['products_id'] . "]\" ";
         if (DISPLAY_TVA_UP == 'true') {
             echo "onKeyUp=\"display_ttc('keyup', this.value" . ", " . $tax_rate['tax_rate'] . ", 1);\"";
         }
         echo " value=\"" . $price . "\">" . vam_draw_hidden_field('update_price[' . $products['products_id'] . ']', 'yes') . "</td>\n";
     }
 }
 //
 $xquery = "SELECT `personal_offer` FROM `personal_offers_by_customers_status_1` WHERE `products_id` = '" . $products['products_id'] . "'";
 $xres = mysql_query($xquery);
 $xobj = mysql_fetch_object($xres);
 $xprice1 = $xobj->personal_offer;
 if ($_POST['spec_price']) {
     // dopisac aby dzialalo
Esempio n. 16
0
     break;
 case 'edit':
     $heading[] = array('text' => '<b>' . TEXT_HEADING_EDIT_CAMPAIGN . '</b>');
     $contents = array('form' => vam_draw_form('campaigns', FILENAME_CAMPAIGNS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->campaigns_id . '&action=save', 'post', 'enctype="multipart/form-data"'));
     $contents[] = array('text' => TEXT_EDIT_INTRO);
     $contents[] = array('text' => '<br />' . TEXT_CAMPAIGNS_NAME . '<br />' . vam_draw_input_field('campaigns_name', $cInfo->campaigns_name));
     $contents[] = array('text' => '<br />' . TEXT_CAMPAIGNS_REFID . '<br />' . vam_draw_input_field('campaigns_refID', $cInfo->campaigns_refID));
     $contents[] = array('align' => 'center', 'text' => '<br />' . '<span class="button"><button type="submit" value="' . BUTTON_SAVE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/save.png', '', '12', '12') . '&nbsp;' . BUTTON_SAVE . '</button></span>' . '&nbsp;' . '<a class="button" href="' . vam_href_link(FILENAME_CAMPAIGNS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->campaigns_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'delete':
     $heading[] = array('text' => '<b>' . TEXT_HEADING_DELETE_CAMPAIGN . '</b>');
     $contents = array('form' => vam_draw_form('campaigns', FILENAME_CAMPAIGNS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->campaigns_id . '&action=deleteconfirm'));
     $contents[] = array('text' => TEXT_DELETE_INTRO);
     $contents[] = array('text' => '<br /><b>' . $cInfo->campaigns_name . '</b>');
     if ($cInfo->refferers_count > 0) {
         $contents[] = array('text' => '<br />' . vam_draw_checkbox_field('delete_refferers') . ' ' . TEXT_DELETE_REFFERERS);
         $contents[] = array('text' => '<br />' . sprintf(TEXT_DELETE_WARNING_REFFERERS, $cInfo->refferers_count));
     }
     $contents[] = array('align' => 'center', 'text' => '<br />' . '<span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span>' . '&nbsp;' . '<a class="button" href="' . vam_href_link(FILENAME_CAMPAIGNS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->campaigns_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 default:
     if (is_object($cInfo)) {
         $heading[] = array('text' => '<b>' . $cInfo->campaigns_name . '</b>');
         $contents[] = array('align' => 'center', 'text' => '<a class="button" href="' . vam_href_link(FILENAME_CAMPAIGNS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->campaigns_id . '&action=edit') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/edit.png', '', '12', '12') . '&nbsp;' . BUTTON_EDIT . '</span></a>' . '&nbsp;' . '<a class="button" href="' . vam_href_link(FILENAME_CAMPAIGNS, 'page=' . $_GET['page'] . '&cID=' . $cInfo->campaigns_id . '&action=delete') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</span></a>');
         $contents[] = array('text' => '<br />' . TEXT_DATE_ADDED . ' ' . vam_date_short($cInfo->date_added));
         if (vam_not_null($cInfo->last_modified)) {
             $contents[] = array('text' => TEXT_LAST_MODIFIED . ' ' . vam_date_short($cInfo->last_modified));
         }
         $contents[] = array('text' => TEXT_REFERER . '?refID=' . $cInfo->campaigns_refID);
     }
     break;
Esempio n. 17
0
        <td align="left"><?php 
        echo vam_draw_input_field('coupon_min_order', $coupon_min_order);
        ?>
</td>
        <td align="left" class="main"><?php 
        echo COUPON_MIN_ORDER_HELP;
        ?>
</td>
      </tr>
      <tr>
        <td align="left" class="main"><?php 
        echo COUPON_FREE_SHIP;
        ?>
</td>
        <td align="left"><?php 
        echo vam_draw_checkbox_field('coupon_free_ship', $coupon_free_ship);
        ?>
</td>
        <td align="left" class="main"><?php 
        echo COUPON_FREE_SHIP_HELP;
        ?>
</td>
      </tr>
      <tr>
        <td align="left" class="main"><?php 
        echo COUPON_CODE;
        ?>
</td>
        <td align="left"><?php 
        echo vam_draw_input_field('coupon_code', $coupon_code);
        ?>
Esempio n. 18
0
<?php 
    }
    ?>
                </table></td>
              </tr>
            </table></td>
<?php 
    $heading = array();
    $contents = array();
    switch ($_GET['action']) {
        case 'confirm':
            $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_DELETE_CUSTOMER . '</b>');
            $contents = array('form' => vam_draw_form('customers', FILENAME_CUSTOMERS, vam_get_all_get_params(array('cID', 'action')) . 'cID=' . $cInfo->customers_id . '&action=deleteconfirm'));
            $contents[] = array('text' => TEXT_DELETE_INTRO . '<br /><br /><b>' . $cInfo->customers_firstname . ' ' . $cInfo->customers_lastname . '</b>');
            if ($cInfo->number_of_reviews > 0) {
                $contents[] = array('text' => '<br />' . vam_draw_checkbox_field('delete_reviews', 'on', true) . ' ' . sprintf(TEXT_DELETE_REVIEWS, $cInfo->number_of_reviews));
            }
            $contents[] = array('align' => 'center', 'text' => '<br /><span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span><a class="button" href="' . vam_href_link(FILENAME_CUSTOMERS, vam_get_all_get_params(array('cID', 'action')) . 'cID=' . $cInfo->customers_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
            break;
        case 'editstatus':
            if ($_GET['cID'] != 1) {
                $customers_history_query = vam_db_query("select new_value, old_value, date_added, customer_notified from " . TABLE_CUSTOMERS_STATUS_HISTORY . " where customers_id = '" . vam_db_input($_GET['cID']) . "' order by customers_status_history_id desc");
                $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_STATUS_CUSTOMER . '</b>');
                $contents = array('form' => vam_draw_form('customers', FILENAME_CUSTOMERS, vam_get_all_get_params(array('cID', 'action')) . 'cID=' . $cInfo->customers_id . '&action=statusconfirm'));
                $contents[] = array('text' => '<br />' . vam_draw_pull_down_menu('status', $customers_statuses_array, $cInfo->customers_status));
                $contents[] = array('text' => '<table nowrap border="0" cellspacing="0" cellpadding="0"><tr><td style="border-bottom: 1px solid; border-color: #000000;" nowrap class="smallText" align="center"><b>' . TABLE_HEADING_NEW_VALUE . ' </b></td><td style="border-bottom: 1px solid; border-color: #000000;" nowrap class="smallText" align="center"><b>' . TABLE_HEADING_DATE_ADDED . '</b></td></tr>');
                if (vam_db_num_rows($customers_history_query)) {
                    while ($customers_history = vam_db_fetch_array($customers_history_query)) {
                        $contents[] = array('text' => '<tr>' . "\n" . '<td class="smallText">' . $customers_statuses_array[$customers_history['new_value']]['text'] . '</td>' . "\n" . '<td class="smallText" align="center">' . vam_datetime_short($customers_history['date_added']) . '</td>' . "\n" . '<td class="smallText" align="center">');
                        $contents[] = array('text' => '</tr>' . "\n");
                    }
                $value_name = vam_db_fetch_array($value_name);
                $flag = $languages[$i]['name'];
                $flag = $languages[$i]['name'];
                $inputs = $flag . ':&nbsp;<input type="text" name="value_name[' . $languages[$i]['id'] . ']" size="15" value="' . $value_name['products_options_values_name'] . '">&nbsp;<input type="hidden" name="orig_image_' . $languages[$i]['code'] . '" value="' . $value_name['products_options_values_image'] . '"><br />';
                $inputs_desc = $flag . ':&nbsp;<textarea name="value_description[' . $languages[$i]['id'] . ']" cols="50" rows="4">' . $value_name['products_options_values_description'] . '</textarea>&nbsp;<br />';
                $inputs_text = $flag . ':&nbsp;<input type="text" name="value_text[' . $languages[$i]['id'] . ']" size="15" value="' . $value_name['products_options_values_text'] . '">&nbsp;<br />';
                if ($value_name['products_options_values_image'] != '') {
                    $inputs_image .= $languages[$i]['name'] . ':&nbsp;<img src="' . ($request_type == 'SSL' ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG . DIR_WS_IMAGES . 'attribute_images/mini/' . $value_name['products_options_values_image'] . '">&nbsp;<a href="' . vam_href_link(FILENAME_PRODUCTS_ATTRIBUTES, 'action=update_option_value&value_id=' . $values_values['products_options_values_id'] . '&value_page=' . $_GET['value_page'] . '&image=edit', 'NONSSL') . '">' . vam_image(DIR_WS_ICONS . 'icon_edit.gif', IMAGE_EDIT) . '</a>&nbsp;<a href="' . vam_href_link(FILENAME_PRODUCTS_ATTRIBUTES, 'action=update_option_value&value_id=' . $values_values['products_options_values_id'] . '&value_page=' . $_GET['value_page'] . '&image=delete', 'NONSSL') . '">' . vam_image(DIR_WS_ICONS . 'delete.gif', IMAGE_DELETE) . '</a>';
                    $inputs_image_delete .= $languages[$i]['name'] . ':&nbsp;<img src="' . ($request_type == 'SSL' ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG . DIR_WS_IMAGES . 'attribute_images/mini/' . $value_name['products_options_values_image'] . '"></img>&nbsp;' . vam_draw_checkbox_field('delete_flag[]', $languages[$i]['code']) . '&nbsp;' . DELETE_TEXT;
                } else {
                    $inputs_image .= $languages[$i]['name'] . ':&nbsp;<a href="' . vam_href_link(FILENAME_PRODUCTS_ATTRIBUTES, 'action=update_option_value&value_id=' . $values_values['products_options_values_id'] . '&value_page=' . $_GET['value_page'] . '&image=edit', 'NONSSL') . '">' . vam_image(DIR_WS_ICONS . 'icon_edit.gif', IMAGE_EDIT) . '</a>';
                    //$inputs_image_delete .= $languages[$i]['name'] . ':&nbsp;'.vam_draw_checkbox_field('delete_flag[]',$languages[$i]['code']).'&nbsp;'.DELETE_TEXT;
                    $inputs_image .= '';
                    $inputs_image_delete .= '';
                }
                $inputs_image_edit .= $languages[$i]['code'] . ':&nbsp;<input type="file" name="value_image[' . $languages[$i]['id'] . ']" size="15" value="' . $value_name['products_options_values_image'] . '">&nbsp;' . vam_draw_checkbox_field('edit_flag[]', $languages[$i]['code']) . '&nbsp;' . EDIT_TEXT . '&nbsp;<br />';
                $inputs_link .= $languages[$i]['name'] . ':&nbsp;http://<input type="text" name="value_link[' . $languages[$i]['id'] . ']" size="15" value="' . $value_name['products_options_values_link'] . '">&nbsp;<br />';
                ?>
  <tr class="dataTableRowSelected">
    <td class="dataTableContent" width="100">&nbsp;</td>
    <td class="dataTableContent" width="150"><b><?php 
                echo TABLE_HEADING_OPT_VALUE;
                ?>
</b></td>
    <td class="dataTableContent"><?php 
                echo $inputs;
                ?>
</td>
  </tr>
  <tr class="dataTableRowSelected">
    <td class="dataTableContent" width="100">&nbsp;</td>
Esempio n. 20
0
    if (ORDER_EDITOR_USE_AJAX != 'true') {
        ?>
 
	<!-- Begin Update Block, only for non-javascript browsers -->
	       <div class="updateBlock">
              <div class="update1"><?php 
        echo HINT_PRESS_UPDATE;
        ?>
</div>
              <div class="update2">&nbsp;</div>
              <div class="update3">&nbsp;</div>
              <div class="update4" align="center"><?php 
        echo ENTRY_SEND_NEW_ORDER_CONFIRMATION;
        ?>
&nbsp;<?php 
        echo vam_draw_checkbox_field('nC1', '', false);
        ?>
</div>
              <div class="update5" align="center"><span class="button"><button type="submit" value="<?php 
        echo BUTTON_UPDATE;
        ?>
"><?php 
        echo vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12');
        ?>
&nbsp;<?php 
        echo BUTTON_UPDATE;
        ?>
</button></span></div>
          </div>
		  
	       <br>
Esempio n. 21
0
     $contents[] = array('align' => 'center', 'text' => '<br>' . '<span class="button"><button type="submit" value="' . BUTTON_INSERT . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . BUTTON_INSERT . '</button></span>' . '&nbsp;<a class="button" href="' . vam_href_link(FILENAME_SHIP2PAY, 'page=' . $_GET['page']) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'edit':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_EDIT_SHP2PAY . '</b>');
     $contents = array('form' => vam_draw_form('s2p', FILENAME_SHIP2PAY, 'page=' . $_GET['page'] . '&s2p_id=' . $trInfo->s2p_id . '&action=save'));
     $contents[] = array('text' => TEXT_INFO_EDIT_INTRO);
     $ship_menu = array();
     foreach ($shipping_modules as $file => $title) {
         $ship_menu[] = array('id' => $file, 'text' => $title);
     }
     $contents[] = array('text' => '<br>' . TEXT_INFO_SHIPMENT . '<br>' . vam_draw_pull_down_menu("shp_id", $ship_menu, $trInfo->shipment));
     $contents[] = array('text' => '<br>' . TEXT_INFO_ZONE . '<br>' . vam_cfg_pull_down_zone_classes($trInfo->zones_id, 'zone_id'));
     $pay_menu = '';
     $allowed = explode(';', $trInfo->payments_allowed);
     foreach ($payment_modules as $file => $title) {
         $pay_menu .= '<br />' . vam_draw_checkbox_field('pay_ids[]', $file, in_array($file, $allowed) ? true : false) . $title;
     }
     $contents[] = array('text' => '<br>' . TEXT_INFO_PAYMENTS . $pay_menu);
     $contents[] = array('align' => 'center', 'text' => '<br>' . '<span class="button"><button type="submit" value="' . BUTTON_UPDATE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . BUTTON_INSERT . '</button></span>' . '&nbsp;<a class="button" href="' . vam_href_link(FILENAME_SHIP2PAY, 'page=' . $_GET['page'] . '&s2p_id=' . $trInfo->s2p_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'delete':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_DELETE_SHP2PAY . '</b>');
     $contents = array('form' => vam_draw_form('s2p', FILENAME_SHIP2PAY, 'page=' . $_GET['page'] . '&s2p_id=' . $trInfo->s2p_id . '&action=deleteconfirm'));
     $contents[] = array('text' => TEXT_INFO_DELETE_INTRO);
     $contents[] = array('text' => '<br>' . TEXT_INFO_PAYMENTS_ALLOWED . '<br><b>' . $shipping_modules[$trInfo->shipment] . ' >> <br></b>');
     $contents[] = array('text' => '<br><b>' . vam_get_zone_class_title($trInfo->zones_id) . '<br>' . vam_p2s_module_name($trInfo->payments_allowed) . '</b>');
     $contents[] = array('align' => 'center', 'text' => '<br>' . '<span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span>' . '&nbsp;<a class="button" href="' . vam_href_link(FILENAME_SHIP2PAY, 'page=' . $_GET['page'] . '&s2p_id=' . $trInfo->s2p_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 default:
     if (is_object($trInfo)) {
         $heading[] = array('text' => '<b>' . $shipping_modules[$trInfo->shipment] . '</b>');
function vam_get_values_menu($display_type, $values_select_array, $specification_name, $specification_value)
{
    $box_text = '';
    switch ($display_type) {
        case 'pulldown':
            $box_text .= vam_draw_pull_down_menu($specification_name, $values_select_array, $specification_value);
            break;
        case 'radio':
            foreach ($values_select_array as $value) {
                $checked = $value['id'] == $specification_value ? true : false;
                $box_text .= vam_draw_radio_field($specification_name, $value['id'], $checked) . '&nbsp;' . $value['text'];
                $box_text .= '<br>' . "\n";
            }
            break;
        case 'multi':
            $box_text .= vam_draw_multi_pull_down_menu($specification_name . '[]', $values_select_array, $specification_value, 'multiple="' . $specification_name . 'f"');
            break;
        case 'checkbox':
            $checkbox_id = 0;
            foreach ($values_select_array as $value) {
                $checked = false;
                if (is_array($specification_value)) {
                    foreach ($specification_value as $spec) {
                        if ($spec['id'] == $value['id']) {
                            $checked = true;
                            break;
                        }
                    }
                } else {
                    $checked = $value['id'] == $specification_value[$checkbox_id] ? true : false;
                }
                // if (is_array ... else ...
                $box_text .= vam_draw_checkbox_field($specification_name . '[' . $checkbox_id . ']', $value['id'], $checked) . '&nbsp;' . $value['text'];
                $box_text .= '<br>' . "\n";
                $checkbox_id++;
            }
            // foreach ($values_select_array
            break;
        case 'image':
            $value = $specification_value != '0' ? $specification_value : '';
            foreach ($values_select_array as $value) {
                $checked = $value['id'] == $specification_value ? true : false;
                $box_text .= '<span class=image_box>';
                $box_text .= vam_draw_radio_field($specification_name, $value['id'], $checked);
                $box_text .= '&nbsp;&nbsp;' . vam_image(DIR_WS_CATALOG_IMAGES . $value['text'], $value['text'], SPECIFICATIONS_FILTER_IMAGE_WIDTH, SPECIFICATIONS_FILTER_IMAGE_HEIGHT, ' class="image_filter"');
                $box_text .= '</span>' . "\n";
            }
            break;
        case 'multiimage':
            foreach ($values_select_array as $value) {
                $checked = $value['id'] == $specification_value ? true : false;
                if ($value['id'] == '0') {
                    $value['id'] = SPECIFICATIONS_GET_ALL_IMAGE;
                    $value['text'] = SPECIFICATIONS_GET_ALL_IMAGE;
                }
                $box_text .= '<span class=image_box>';
                $box_text .= vam_draw_checkbox_field($specification_name, $value['id'], $checked);
                $box_text .= '&nbsp;&nbsp;' . vam_image(DIR_WS_CATALOG_IMAGES . $value['text'], $value['text'], SPECIFICATIONS_FILTER_IMAGE_WIDTH, SPECIFICATIONS_FILTER_IMAGE_HEIGHT, ' class="image_filter"');
                $box_text .= '</span>' . "\n";
            }
            break;
        default:
        case 'text':
            $value = $specification_value != 0 ? $specification_value : '';
            $box_text .= vam_draw_input_field($specification_name, $value);
            break;
    }
    // switch ($display_type
    return $box_text;
}
function vam_get_filter_string($display_type, $filters_select_array, $target, $filter_name, $filter_value)
{
    $filter_name = (string) $filter_name;
    if (is_array($filter_value)) {
    } else {
        $filter_value = (string) $filter_value;
    }
    $exclude_array = array($filter_name, 'page');
    $additional_variables = vam_get_hidden_get_variables($exclude_array);
    $box_text = '';
    switch ($display_type) {
        case 'pulldown':
            $box_text .= vam_draw_form('filter', $target, 'get');
            $box_text .= vam_draw_pull_down_menu($filter_name, $filters_select_array, $filter_value, 'onChange="this.form.submit();"');
            $box_text .= $additional_variables . vam_hide_session_id();
            $box_text .= '<noscript>' . vam_image_submit('submit.png', TEXT_FIND_PRODUCTS) . '</noscript>';
            $box_text .= '</form>';
            break;
        case 'radio':
            $box_text .= vam_draw_form('filter', $target, 'get');
            foreach ($filters_select_array as $filter) {
                $checked = $filter['id'] == $filter_value ? true : false;
                switch (true) {
                    case $filter['count'] != '' && $filter['count'] < 1 && SPECIFICATIONS_FILTER_NO_RESULT == 'none':
                        break;
                    case $filter['count'] != '' && $filter['count'] < 1 && SPECIFICATIONS_FILTER_NO_RESULT == 'grey':
                        /* $box_text .= '<input type="radio" name="0" value="0" disabled="disabled">';
                           $box_text .= '<span class="no_results">' . '&nbsp;';
                           $box_text .= vam_output_string ($filter['text'] );
                           $box_text .= '</span>';
                           if (SPECIFICATIONS_FILTER_SHOW_COUNT == 'True' && $filter['count'] != '') {
                             $box_text .= '<span class="filter_count"> (' . $filter['count'] . ')</span>';
                           }
                           $box_text .= '<br>' . "\n";
                           */
                        break;
                    default:
                        $box_text .= vam_draw_radio_field($filter_name, $filter['id'], $checked, 'onClick="this.form.submit();"') . '&nbsp;' . $filter['text'];
                        if (SPECIFICATIONS_FILTER_SHOW_COUNT == 'True' && $filter['count'] != '') {
                            $box_text .= '<span class="filter_count"> (' . $filter['count'] . ')</span>';
                        }
                        $box_text .= '<br>' . "\n";
                        break;
                }
                // switch (true)
            }
            $box_text .= $additional_variables . vam_hide_session_id();
            $box_text .= '<noscript>' . vam_image_submit('submit.png', TEXT_FIND_PRODUCTS) . '</noscript>';
            $box_text .= '</form>';
            break;
        case 'text':
            $value = $filter_value != 0 ? $filter_value : '';
            $box_text .= vam_draw_form('filter', $target, 'get');
            //$box_text .= vam_draw_input_field($filter_name, $value);
            $box_text .= vam_draw_input_price_slider($filter_name, $value);
            $box_text .= $additional_variables . vam_hide_session_id();
            //$box_text .= '<noscript>' . vam_image_submit('submit.png', TEXT_FIND_PRODUCTS) . '</noscript>';
            $box_text .= '</form>';
            break;
        case 'multi':
            $box_text .= vam_draw_form('filter', $target, 'get');
            $box_text .= vam_draw_multi_pull_down_menu($filter_name . '[]', $filters_select_array, $filter_value, 'multiple="' . $filter_name . 'f"');
            $box_text .= $additional_variables . vam_hide_session_id();
            $box_text .= vam_image_submit('submit.png', TEXT_FIND_PRODUCTS);
            $box_text .= '</form>';
            break;
        case 'checkbox':
            $box_text .= vam_draw_form('filter', $target, 'get');
            $checkbox_id = 0;
            foreach ($filters_select_array as $filter) {
                $checked = $filter['id'] == $filter_value[$checkbox_id] ? true : false;
                switch (true) {
                    case $filter['count'] < 1 && SPECIFICATIONS_FILTER_NO_RESULT == 'none':
                        break;
                    case $filter['count'] < 1 && SPECIFICATIONS_FILTER_NO_RESULT == 'grey':
                        /* $box_text .= '<input type="checkbox" name="0" value="0" disabled="disabled">';
                           $box_text .= '<span class="no_results">' . '&nbsp;';
                           $box_text .= vam_output_string ($filter['text'] );
                           $box_text .= '</span>';
                           if (SPECIFICATIONS_FILTER_SHOW_COUNT == 'True') {
                             $box_text .= '<span class="filter_count"> (' . $filter['count'] . ')</span>';
                           }
                           $box_text .= '<br>' . "\n";
                           */
                        break;
                    default:
                        $box_text .= vam_draw_checkbox_field($filter_name . '[' . $checkbox_id . ']', $filter['id'], $checked, 'onclick="this.form.submit();"') . '&nbsp;' . $filter['text'];
                        if (SPECIFICATIONS_FILTER_SHOW_COUNT == 'True') {
                            $box_text .= '<span class="filter_count"> (' . $filter['count'] . ')</span>';
                        }
                        $box_text .= '<br>' . "\n";
                        break;
                }
                // switch (true)
                $checkbox_id++;
            }
            $box_text .= $additional_variables . vam_hide_session_id();
            //$box_text .= vam_image_submit('submit.png', TEXT_FIND_PRODUCTS);
            $box_text .= '</form>';
            break;
        case 'image':
            $value = $filter_value != 0 ? $filter_value : '';
            $box_text .= vam_draw_images_menu($filter_name, $filters_select_array, $target, $value);
            break;
        case 'multiimage':
            $box_text .= vam_draw_form('filter', $target, 'get');
            foreach ($filters_select_array as $filter) {
                $checked = $filter['id'] == $filter_value[$checkbox_id] ? true : false;
                $box_text .= vam_draw_checkbox_field($filter_name . '[' . $checkbox_id . ']', $filter['id'], $checked);
                $box_text .= '  ' . vam_image(DIR_WS_IMAGES . trim($filter['text']), $filter['text']) . '<br>' . "\n";
                $box_text .= '<br>' . "\n";
                $checkbox_id++;
            }
            $box_text .= $additional_variables . vam_hide_session_id();
            $box_text .= vam_image_submit('submit.png', TEXT_FIND_PRODUCTS);
            $box_text .= '</form>';
            break;
        case 'links':
        default:
            $box_text .= vam_draw_links_menu($filter_name, $filters_select_array, $target, $filter_value);
            break;
    }
    // switch ($display_type
    return $box_text;
}
Esempio n. 24
0
    echo $orders_split->display_links($orders_query_numrows, MAX_DISPLAY_ADMIN_PAGE, MAX_DISPLAY_PAGE_LINKS, $_GET['page'], vam_get_all_get_params(array('page', 'oID', 'action')));
    ?>
</td>
                  </tr>
                </table></td>
              </tr>
            </table></td>
<?php 
    $heading = array();
    $contents = array();
    switch ($_GET['action']) {
        case 'delete':
            $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_DELETE_ORDER . '</b>');
            $contents = array('form' => vam_draw_form('orders', FILENAME_ORDERS, vam_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id . '&action=deleteconfirm'));
            $contents[] = array('text' => TEXT_INFO_DELETE_INTRO . '<br /><br /><b>' . $cInfo->customers_firstname . ' ' . $cInfo->customers_lastname . '</b>');
            $contents[] = array('text' => '<br />' . vam_draw_checkbox_field('restock') . ' ' . TEXT_INFO_RESTOCK_PRODUCT_QUANTITY);
            $contents[] = array('align' => 'center', 'text' => '<br /><span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span><a class="button" href="' . vam_href_link(FILENAME_ORDERS, vam_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
            break;
        default:
            if (is_object($oInfo)) {
                $heading[] = array('text' => '<b>[' . $oInfo->orders_id . ']&nbsp;&nbsp;' . vam_datetime_short($oInfo->date_purchased) . '</b>');
                $contents[] = array('align' => 'center', 'text' => '<a class="button" href="' . vam_href_link(FILENAME_ORDERS, vam_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id . '&action=edit') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/edit.png', '', '12', '12') . '&nbsp;' . BUTTON_EDIT . '</span></a> <a class="button" href="' . vam_href_link(FILENAME_ORDERS, vam_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id . '&action=delete') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</span></a>&nbsp;<a class="button" href="' . vam_href_link(FILENAME_PRINT_ORDER, 'oID=' . $oInfo->orders_id) . '" target="_blank"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/payment.png', '', '12', '12') . '&nbsp;' . BUTTON_INVOICE . '</span></a>&nbsp;<a class="button" href="' . vam_href_link(FILENAME_PRINT_PACKINGSLIP, 'oID=' . $oInfo->orders_id) . '" target="_blank"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/shipping.png', '', '12', '12') . '&nbsp;' . BUTTON_PACKINGSLIP . '</span></a>');
                if (AFTERBUY_ACTIVATED == 'true') {
                    $contents[] = array('align' => 'center', 'text' => '<a class="button" href="' . vam_href_link(FILENAME_ORDERS, vam_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id . '&action=afterbuy_send') . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . BUTTON_AFTERBUY_SEND . '</span></a>');
                }
                //$contents[] = array('align' => 'center', 'text' => '');
                $order_payment = $oInfo->payment_method;
                require DIR_FS_LANGUAGES . $_SESSION['language'] . '/modules/payment/' . $order_payment . '.php';
                $order_payment_text = constant(MODULE_PAYMENT_ . strtoupper($order_payment) . _TEXT_TITLE);
                $contents[] = array('text' => '<br />' . TEXT_DATE_ORDER_CREATED . ' ' . vam_date_short($oInfo->date_purchased));
                if (vam_not_null($oInfo->last_modified)) {
                    echo "</TR>";
                    // Download function start
                    if (DOWNLOAD_ENABLED == 'true') {
                        $file_list = vam_array_merge(array('0' => array('id' => '', 'text' => SELECT_FILE)), vam_getFiles(DIR_FS_CATALOG . 'download/'));
                        echo "<tr>";
                        // echo "<td colspan=\"2\">File: <input type=\"file\" name=\"" . $current_value_id . "_download_file\"></td>";
                        //                echo "<td colspan=\"2\" class=\"main\">&nbsp;" . DL_FILE . "<br>" . vam_draw_pull_down_menu($current_value_id . '_download_file', vam_getDownloads(), $attribute_value_download_filename, '')."</td>";
                        echo "<td colspan=\"2\" class=\"main\">&nbsp;" . DL_FILE . "<br>" . vam_draw_pull_down_menu($current_value_id . '_download_file', $file_list, $attribute_value_download_filename) . "</td>";
                        echo "<td class=\"main\">&nbsp;" . DL_COUNT . "<br><input type=\"text\" name=\"" . $current_value_id . "_download_count\" value=\"" . $attribute_value_download_count . "\"></td>";
                        echo "<td class=\"main\">&nbsp;" . DL_EXPIRE . "<br><input type=\"text\" name=\"" . $current_value_id . "_download_expire\" value=\"" . $attribute_value_download_expire . "\"></td>";
                        ?>
                 <td class="main" align="left"><?php 
                        echo TABLE_TEXT_IS_PIN;
                        ?>
 <?php 
                        echo vam_draw_checkbox_field($current_value_id . '_ispin', '', $products_attributes_is_pin, 1);
                        ?>
&nbsp;</td>
                <?php 
                        echo "</tr>";
                    }
                    // Download function end
                }
                if ($i == $matches2) {
                    $i = '0';
                }
            }
        } else {
            echo "<TR>";
            echo "<TD class=\"main\"><SMALL>No values under this option.</SMALL></TD>";
            echo "</TR>";
     $contents[] = array('text' => '<br />' . vam_draw_checkbox_field('default') . ' ' . TEXT_SET_DEFAULT);
     $contents[] = array('align' => 'center', 'text' => '<br /><span class="button"><button type="submit" value="' . BUTTON_INSERT . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . BUTTON_INSERT . '</button></span> <a class="button" href="' . vam_href_link(FILENAME_SHIPPING_STATUS, 'page=' . $_GET['page']) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'edit':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_EDIT_SHIPPING_STATUS . '</b>');
     $contents = array('form' => vam_draw_form('status', FILENAME_SHIPPING_STATUS, 'page=' . $_GET['page'] . '&oID=' . $oInfo->shipping_status_id . '&action=save', 'post', 'enctype="multipart/form-data"'));
     $contents[] = array('text' => TEXT_INFO_EDIT_INTRO);
     $shipping_status_inputs_string = '';
     $languages = vam_get_languages();
     for ($i = 0, $n = sizeof($languages); $i < $n; $i++) {
         $shipping_status_inputs_string .= '<br />' . $languages[$i]['name'] . ':&nbsp;' . vam_draw_input_field('shipping_status_name[' . $languages[$i]['id'] . ']', vam_get_shipping_status_name($oInfo->shipping_status_id, $languages[$i]['id']));
     }
     $contents[] = array('text' => '<br />' . TEXT_INFO_SHIPPING_STATUS_IMAGE . '<br />' . vam_draw_file_field('shipping_status_image', $oInfo->shipping_status_image));
     $contents[] = array('text' => '<br />' . TEXT_INFO_SHIPPING_STATUS_NAME . $shipping_status_inputs_string);
     if (DEFAULT_SHIPPING_STATUS_ID != $oInfo->shipping_status_id) {
         $contents[] = array('text' => '<br />' . vam_draw_checkbox_field('default') . ' ' . TEXT_SET_DEFAULT);
     }
     $contents[] = array('align' => 'center', 'text' => '<br /><span class="button"><button type="submit" value="' . BUTTON_UPDATE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . BUTTON_INSERT . '</button></span> <a class="button" href="' . vam_href_link(FILENAME_SHIPPING_STATUS, 'page=' . $_GET['page'] . '&oID=' . $oInfo->shipping_status_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     break;
 case 'delete':
     $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_DELETE_SHIPPING_STATUS . '</b>');
     $contents = array('form' => vam_draw_form('status', FILENAME_SHIPPING_STATUS, 'page=' . $_GET['page'] . '&oID=' . $oInfo->shipping_status_id . '&action=deleteconfirm'));
     $contents[] = array('text' => TEXT_INFO_DELETE_INTRO);
     $contents[] = array('text' => '<br /><b>' . $oInfo->shipping_status_name . '</b>');
     if ($remove_status) {
         $contents[] = array('align' => 'center', 'text' => '<br /><span class="button"><button type="submit" value="' . BUTTON_DELETE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/delete.png', '', '12', '12') . '&nbsp;' . BUTTON_DELETE . '</button></span> <a class="button" href="' . vam_href_link(FILENAME_SHIPPING_STATUS, 'page=' . $_GET['page'] . '&oID=' . $oInfo->shipping_status_id) . '"><span>' . vam_image(DIR_WS_IMAGES . 'icons/buttons/cancel.png', '', '12', '12') . '&nbsp;' . BUTTON_CANCEL . '</span></a>');
     }
     break;
 default:
     if (is_object($oInfo)) {
         $heading[] = array('text' => '<b>' . $oInfo->shipping_status_name . '</b>');
    ?>
&nbsp;</td>
            <td class="main"><?php 
    echo vam_draw_input_field('expires-dd', substr($sInfo->expires_date, 8, 2), "size=\"2\" maxlength=\"2\" id=\"expires-dd\"");
    ?>
 / <?php 
    echo vam_draw_input_field('expires-mm', substr($sInfo->expires_date, 5, 2), "size=\"2\" maxlength=\"2\" id=\"expires-mm\" class=\"\"");
    ?>
 / <?php 
    echo vam_draw_input_field('expires', substr($sInfo->expires_date, 0, 4), "size=\"4\" maxlength=\"4\" id=\"expires\" class=\"format-d-m-y split-date\"");
    ?>
</td>
          </tr>
          <tr>
            <td colspan="2" valign="middle" class="main"><?php 
    echo vam_draw_checkbox_field('override', 'y');
    ?>
 &nbsp; <?php 
    echo TEXT_SPECIALS_OVERRIDE;
    ?>
</td>
          </tr>
        </table></td>
      </tr>
	
      <tr>
        <td>
<table border="0" width="100%" cellspacing="0" cellpadding="2">
          <tr>
            <td class="main"><br><?php 
    echo TEXT_SPECIALS_PRICE_TIP;
            <td><table border="0" cellspacing="0" cellpadding="2">
              <tr>
                <td class="main"><b><?php 
    echo PAYMENT_STATUS;
    ?>
</b> <?php 
    echo vam_draw_pull_down_menu('status', $payments_statuses, $payments['affiliate_payment_status']);
    ?>
</td>
              </tr>
              <tr>
                <td class="main"><b><?php 
    echo PAYMENT_NOTIFY_AFFILIATE;
    ?>
</b><?php 
    echo vam_draw_checkbox_field('notify', '', true);
    ?>
</td>
              </tr>
            </table></td>
            <td valign="top"><?php 
    echo '<span class="button"><button type="submit" class="button" value="' . BUTTON_UPDATE . '">' . vam_image(DIR_WS_IMAGES . 'icons/buttons/submit.png', '', '12', '12') . '&nbsp;' . BUTTON_UPDATE . '</button></span>';
    ?>
</td>
          </tr>
        </table></td>
      </form></tr>

      <tr>
        <td><?php 
    echo vam_draw_separator('pixel_trans.gif', '1', '10');
// create template elements
$vamTemplate = new vamTemplate();
// include boxes
require DIR_FS_CATALOG . 'templates/' . CURRENT_TEMPLATE . '/source/boxes.php';
// include needed functions
require_once DIR_FS_INC . 'vam_get_categories.inc.php';
require_once DIR_FS_INC . 'vam_get_manufacturers.inc.php';
require_once DIR_FS_INC . 'vam_checkdate.inc.php';
$breadcrumb->add(NAVBAR_TITLE_ADVANCED_SEARCH, vam_href_link(FILENAME_ADVANCED_SEARCH));
require DIR_WS_INCLUDES . 'header.php';
$vamTemplate->assign('FORM_ACTION', vam_draw_form('advanced_search', vam_href_link(FILENAME_ADVANCED_SEARCH_RESULT, '', 'NONSSL', false), 'get', 'onsubmit="return check_form(this);"') . vam_hide_session_id());
$vamTemplate->assign('INPUT_KEYWORDS', vam_draw_input_field('keywords', '', ''));
$vamTemplate->assign('HELP_LINK', 'javascript:popupWindow(\'' . vam_href_link(FILENAME_POPUP_SEARCH_HELP) . '\')');
$vamTemplate->assign('BUTTON_SUBMIT', vam_image_submit('search.png', IMAGE_BUTTON_SEARCH));
$vamTemplate->assign('SELECT_CATEGORIES', vam_draw_pull_down_menu('categories_id', vam_get_categories(array(array('id' => '', 'text' => TEXT_ALL_CATEGORIES)))));
$vamTemplate->assign('ENTRY_SUBCAT', vam_draw_checkbox_field('inc_subcat', '1', true));
$vamTemplate->assign('SELECT_MANUFACTURERS', vam_draw_pull_down_menu('manufacturers_id', vam_get_manufacturers(array(array('id' => '', 'text' => TEXT_ALL_MANUFACTURERS)))));
$vamTemplate->assign('SELECT_PFROM', vam_draw_input_field('pfrom'));
$vamTemplate->assign('SELECT_PTO', vam_draw_input_field('pto'));
$error = '';
if (isset($_GET['errorno'])) {
    if (($_GET['errorno'] & 1) == 1) {
        $error .= str_replace('\\n', '<br />', JS_AT_LEAST_ONE_INPUT);
    }
    if (($_GET['errorno'] & 10) == 10) {
        $error .= str_replace('\\n', '<br />', JS_INVALID_FROM_DATE);
    }
    if (($_GET['errorno'] & 100) == 100) {
        $error .= str_replace('\\n', '<br />', JS_INVALID_TO_DATE);
    }
    if (($_GET['errorno'] & 1000) == 1000) {