Version Description
Download this release
Release Info
Developer | jghazally |
Plugin | WP eCommerce |
Version | 3.7.6RC2 |
Comparing to | |
See all releases |
Code changes from version 3.7.6.1 to 3.7.6RC2
- admin-form-functions.php +3 -2
- admin.js +7 -3
- currency_list.php +2 -2
- edit-profile.php +2 -3
- install_and_update.php +0 -2
- js/wp-e-commerce.js +4 -4
- merchants/paypal_multiple.php +1 -4
- merchants/paypal_pro.php +4 -4
- readme.txt +12 -10
- themes/default/category_widget.php +2 -2
- themes/default/default.css +5 -1
- themes/default/grid_view.php +33 -32
- themes/default/list_view.php +2 -2
- themes/default/products_page.php +3 -3
- themes/default/shopping_cart_page.php +4 -4
- themes/iShop/grid_view.php +2 -2
- themes/iShop/list_view.php +2 -2
- themes/iShop/products_page.php +3 -3
- themes/iShop/shopping_cart_page.php +5 -3
- themes/marketplace/grid_view.php +2 -2
- themes/marketplace/list_view.php +2 -2
- themes/marketplace/products_page.php +3 -3
- themes/marketplace/shopping_cart_page.php +5 -3
- transaction_results.php +0 -6
- user-downloads.php +1 -4
- user-log.php +2 -1
- wp-shopping-cart.php +4 -10
- wpsc-admin/admin.php +0 -6
- wpsc-admin/ajax-and-init.php +3 -4
- wpsc-admin/display-items.page.php +5 -24
- wpsc-admin/display-sales-logs.php +4 -34
- wpsc-admin/includes/display-items-functions.php +3 -6
- wpsc-admin/includes/settings-pages/admin.php +1 -6
- wpsc-admin/includes/settings-pages/general.php +0 -24
- wpsc-admin/includes/settings-pages/presentation.php +10 -15
- wpsc-admin/includes/settings-pages/shipping.php +0 -1
- wpsc-admin/js/admin.js +7 -16
- wpsc-includes/ajax.functions.php +14 -27
- wpsc-includes/cart.class.php +7 -16
- wpsc-includes/checkout.class.php +2 -2
- wpsc-includes/display.functions.php +1 -1
- wpsc-includes/install_and_update.functions.php +1 -3
- wpsc-includes/merchant.class.php +2 -12
- wpsc-includes/misc.functions.php +4 -34
- wpsc-includes/productfeed.php +3 -3
- wpsc-includes/theme.functions.php +1 -1
- wpsc-includes/wpsc_query.php +9 -64
admin-form-functions.php
CHANGED
@@ -585,7 +585,7 @@ function setting_button(){
|
|
585 |
return $output;
|
586 |
}
|
587 |
|
588 |
-
function wpsc_right_now(
|
589 |
global $wpdb,$nzshpcrt_imagesize_info;
|
590 |
$year = date("Y");
|
591 |
$month = date("m");
|
@@ -624,9 +624,10 @@ function wpsc_right_now($hidden = '') {
|
|
624 |
|
625 |
$replace_values[":theme:"] = get_option('wpsc_selected_theme');
|
626 |
$replace_values[":versionnumber:"] = WPSC_PRESENTABLE_VERSION;
|
|
|
627 |
if (function_exists('add_object_page')) {
|
628 |
$output="";
|
629 |
-
$output.="<div id='dashboard_right_now' class='postbox
|
630 |
$output.=" <h3 class='hndle'>";
|
631 |
$output.=" <span>".__('Current Month', 'wpsc')."</span>";
|
632 |
$output.=" <br class='clear'/>";
|
585 |
return $output;
|
586 |
}
|
587 |
|
588 |
+
function wpsc_right_now() {
|
589 |
global $wpdb,$nzshpcrt_imagesize_info;
|
590 |
$year = date("Y");
|
591 |
$month = date("m");
|
624 |
|
625 |
$replace_values[":theme:"] = get_option('wpsc_selected_theme');
|
626 |
$replace_values[":versionnumber:"] = WPSC_PRESENTABLE_VERSION;
|
627 |
+
|
628 |
if (function_exists('add_object_page')) {
|
629 |
$output="";
|
630 |
+
$output.="<div id='dashboard_right_now' class='postbox'>";
|
631 |
$output.=" <h3 class='hndle'>";
|
632 |
$output.=" <span>".__('Current Month', 'wpsc')."</span>";
|
633 |
$output.=" <br class='clear'/>";
|
admin.js
CHANGED
@@ -235,14 +235,12 @@ jQuery("div.previewimage").hover(
|
|
235 |
}
|
236 |
);
|
237 |
|
238 |
-
jQuery(".closeimagesettings").click(
|
239 |
function (e) {
|
240 |
-
alert('uhuh');
|
241 |
jQuery("div#image_settings_box").hide();
|
242 |
}
|
243 |
);
|
244 |
|
245 |
-
|
246 |
jQuery("#table_rate_price").click(
|
247 |
function() {
|
248 |
if (this.checked) {
|
@@ -1063,6 +1061,12 @@ function enablebuttons(){
|
|
1063 |
}
|
1064 |
);
|
1065 |
|
|
|
|
|
|
|
|
|
|
|
|
|
1066 |
function imageorderresults(results) {
|
1067 |
eval(results);
|
1068 |
jQuery('#gallery_image_'+ser).append(output);
|
235 |
}
|
236 |
);
|
237 |
|
238 |
+
jQuery("a.closeimagesettings").click(
|
239 |
function (e) {
|
|
|
240 |
jQuery("div#image_settings_box").hide();
|
241 |
}
|
242 |
);
|
243 |
|
|
|
244 |
jQuery("#table_rate_price").click(
|
245 |
function() {
|
246 |
if (this.checked) {
|
1061 |
}
|
1062 |
);
|
1063 |
|
1064 |
+
jQuery("a.closeimagesettings").click(
|
1065 |
+
function (e) {
|
1066 |
+
jQuery("div#image_settings_box").hide();
|
1067 |
+
}
|
1068 |
+
);
|
1069 |
+
|
1070 |
function imageorderresults(results) {
|
1071 |
eval(results);
|
1072 |
jQuery('#gallery_image_'+ser).append(output);
|
currency_list.php
CHANGED
@@ -84,7 +84,7 @@ INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (82, 'Czech Rep.', 'CZ', 'Czec
|
|
84 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (83, 'Cyprus', 'CY', 'Cyprus Pound', '', '', 'CYP', '0', '0','europe','1');
|
85 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (84, 'Cuba', 'CU', 'Cuban Peso', '', '', 'CUP', '0', '0','northamerica','1');
|
86 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (85, 'Croatia', 'HR', 'Croatian Kuna', '', '', 'HRK', '0', '0','europe','1');
|
87 |
-
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (86, 'Costa Rica', 'CR', 'Costa Rican Colon', '', '', 'CRC', '0', '0','
|
88 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (87, 'Cook Islands', 'CK', 'New Zealand Dollar', '$', '$', 'NZD', '0', '0' ,'asiapacific','1');
|
89 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (88, 'Congo', 'CG', 'CFA Franc BEAC', '', '', 'XAF', '0', '0','africa','1');
|
90 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (89, 'Comoros', 'KM', 'Comoros Franc', '', '', 'KMF', '0', '0','africa','1');
|
@@ -240,4 +240,4 @@ INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (238, 'Yemen', 'YE', 'Yemeni R
|
|
240 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (239, 'Yugoslavia', 'YU', 'Yugoslav New Dinar', '', '', 'YUN', '0', '0','europe','1');
|
241 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (240, 'Zambia', 'ZM', 'Zambian Kwacha', '', '', 'ZMK', '0', '0','africa','1');
|
242 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (241, 'Zimbabwe', 'ZW', 'Zimbabwe Dollar', '$', '$', 'ZWD', '0', '0','africa','1');
|
243 |
-
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (242, 'Deutschland', 'DE', 'Euro', '€', '€', 'EUR', '0', '0','europe','1');";
|
84 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (83, 'Cyprus', 'CY', 'Cyprus Pound', '', '', 'CYP', '0', '0','europe','1');
|
85 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (84, 'Cuba', 'CU', 'Cuban Peso', '', '', 'CUP', '0', '0','northamerica','1');
|
86 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (85, 'Croatia', 'HR', 'Croatian Kuna', '', '', 'HRK', '0', '0','europe','1');
|
87 |
+
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (86, 'Costa Rica', 'CR', 'Costa Rican Colon', '', '', 'CRC', '0', '0','southamrica','1');
|
88 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (87, 'Cook Islands', 'CK', 'New Zealand Dollar', '$', '$', 'NZD', '0', '0' ,'asiapacific','1');
|
89 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (88, 'Congo', 'CG', 'CFA Franc BEAC', '', '', 'XAF', '0', '0','africa','1');
|
90 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (89, 'Comoros', 'KM', 'Comoros Franc', '', '', 'KMF', '0', '0','africa','1');
|
240 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (239, 'Yugoslavia', 'YU', 'Yugoslav New Dinar', '', '', 'YUN', '0', '0','europe','1');
|
241 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (240, 'Zambia', 'ZM', 'Zambian Kwacha', '', '', 'ZMK', '0', '0','africa','1');
|
242 |
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (241, 'Zimbabwe', 'ZW', 'Zimbabwe Dollar', '$', '$', 'ZWD', '0', '0','africa','1');
|
243 |
+
INSERT INTO `".WPSC_TABLE_CURRENCY_LIST."` VALUES (242, 'Deutschland', 'DE', 'Euro', '€', '€', 'EUR', '0', '0','europe','1');";
|
edit-profile.php
CHANGED
@@ -78,7 +78,7 @@ if($_POST['collected_data'] != null) {
|
|
78 |
<?php
|
79 |
echo " <div class='user-profile-links'><a href='".get_option('user_account_url')."'>Purchase History</a> | <a href='".get_option('user_account_url').$seperator."edit_profile=true'>Your Details</a> | <a href='".get_option('user_account_url').$seperator."downloads=true'>Your Downloads</a></div><br />";
|
80 |
?>
|
81 |
-
<form method='
|
82 |
<?php
|
83 |
if($changes_saved == true) {
|
84 |
echo __('Thanks, your changes have been saved.', 'wpsc');
|
@@ -189,5 +189,4 @@ foreach($form_data as $form_field)
|
|
189 |
</td>
|
190 |
</tr>
|
191 |
</table>
|
192 |
-
</form>
|
193 |
-
</div>
|
78 |
<?php
|
79 |
echo " <div class='user-profile-links'><a href='".get_option('user_account_url')."'>Purchase History</a> | <a href='".get_option('user_account_url').$seperator."edit_profile=true'>Your Details</a> | <a href='".get_option('user_account_url').$seperator."downloads=true'>Your Downloads</a></div><br />";
|
80 |
?>
|
81 |
+
<form method='POST'>
|
82 |
<?php
|
83 |
if($changes_saved == true) {
|
84 |
echo __('Thanks, your changes have been saved.', 'wpsc');
|
189 |
</td>
|
190 |
</tr>
|
191 |
</table>
|
192 |
+
</form>
|
|
install_and_update.php
CHANGED
@@ -391,7 +391,6 @@ function wpsc_check_and_copy_files() {
|
|
391 |
$wpsc_dirs['categories']['old'] = ABSPATH."{$upload_path}/category_images/";
|
392 |
$wpsc_dirs['categories']['new'] = WPSC_CATEGORY_DIR;
|
393 |
$incomplete_file_transfer = false;
|
394 |
-
exit('called');
|
395 |
foreach($wpsc_dirs as $wpsc_dir) {
|
396 |
if(is_dir($wpsc_dir['old'])) {
|
397 |
$files_in_dir = glob($wpsc_dir['old']."*");
|
@@ -435,7 +434,6 @@ function wpsc_create_upload_directories() {
|
|
435 |
WPSC_UPGRADES_DIR,
|
436 |
WPSC_THEMES_PATH,
|
437 |
);
|
438 |
-
// exit('<pre>'.print_r($folders, true).'</pre>');
|
439 |
foreach ($folders as $folder) {
|
440 |
wp_mkdir_p($folder);
|
441 |
@ chmod( $folder, 0775 );
|
391 |
$wpsc_dirs['categories']['old'] = ABSPATH."{$upload_path}/category_images/";
|
392 |
$wpsc_dirs['categories']['new'] = WPSC_CATEGORY_DIR;
|
393 |
$incomplete_file_transfer = false;
|
|
|
394 |
foreach($wpsc_dirs as $wpsc_dir) {
|
395 |
if(is_dir($wpsc_dir['old'])) {
|
396 |
$files_in_dir = glob($wpsc_dir['old']."*");
|
434 |
WPSC_UPGRADES_DIR,
|
435 |
WPSC_THEMES_PATH,
|
436 |
);
|
|
|
437 |
foreach ($folders as $folder) {
|
438 |
wp_mkdir_p($folder);
|
439 |
@ chmod( $folder, 0775 );
|
js/wp-e-commerce.js
CHANGED
@@ -73,7 +73,7 @@ jQuery(document).ready(function () {
|
|
73 |
jQuery("select#region").show();
|
74 |
shipName = jQuery('input.shipping_region').attr('name');
|
75 |
shipID = jQuery('input.shipping_region').attr('id');
|
76 |
-
jQuery('input.shipping_region').replaceWith('<input type="hidden" class="shipping_region" value="'+stateID+'" name="'+shipName+'" id="'+shipName+'"
|
77 |
jQuery("select#region :selected").html(state).attr('selected','selected');
|
78 |
jQuery('span.shipping_region_name').html(state);
|
79 |
}
|
@@ -287,7 +287,7 @@ function wpsc_fancy_notification(parent_form){
|
|
287 |
//console.log(form_button_id);
|
288 |
//return;
|
289 |
var container_offset = {};
|
290 |
-
new_container_offset = jQuery('#products_page_container').offset();
|
291 |
|
292 |
if(container_offset['left'] == null) {
|
293 |
container_offset['left'] = new_container_offset.left;
|
@@ -295,13 +295,13 @@ function wpsc_fancy_notification(parent_form){
|
|
295 |
}
|
296 |
|
297 |
var button_offset = {};
|
298 |
-
new_button_offset = jQuery('#'+form_button_id).offset()
|
299 |
|
300 |
if(button_offset['left'] == null) {
|
301 |
button_offset['left'] = new_button_offset.left;
|
302 |
button_offset['top'] = new_button_offset.top;
|
303 |
}
|
304 |
-
|
305 |
jQuery('#fancy_notification').css("left", (button_offset['left'] - container_offset['left'] + 10) + 'px');
|
306 |
jQuery('#fancy_notification').css("top", ((button_offset['top'] - container_offset['top']) -60) + 'px');
|
307 |
|
73 |
jQuery("select#region").show();
|
74 |
shipName = jQuery('input.shipping_region').attr('name');
|
75 |
shipID = jQuery('input.shipping_region').attr('id');
|
76 |
+
jQuery('input.shipping_region').replaceWith('<input type="hidden" class="shipping_region" value="'+stateID+'" name="'+shipName+'" id="'+shipName+'" />');
|
77 |
jQuery("select#region :selected").html(state).attr('selected','selected');
|
78 |
jQuery('span.shipping_region_name').html(state);
|
79 |
}
|
287 |
//console.log(form_button_id);
|
288 |
//return;
|
289 |
var container_offset = {};
|
290 |
+
new_container_offset = jQuery('#products_page_container').offset(options, container_offset);
|
291 |
|
292 |
if(container_offset['left'] == null) {
|
293 |
container_offset['left'] = new_container_offset.left;
|
295 |
}
|
296 |
|
297 |
var button_offset = {};
|
298 |
+
new_button_offset = jQuery('#'+form_button_id).offset(options, button_offset)
|
299 |
|
300 |
if(button_offset['left'] == null) {
|
301 |
button_offset['left'] = new_button_offset.left;
|
302 |
button_offset['top'] = new_button_offset.top;
|
303 |
}
|
304 |
+
|
305 |
jQuery('#fancy_notification').css("left", (button_offset['left'] - container_offset['left'] + 10) + 'px');
|
306 |
jQuery('#fancy_notification').css("top", ((button_offset['top'] - container_offset['top']) -60) + 'px');
|
307 |
|
merchants/paypal_multiple.php
CHANGED
@@ -162,7 +162,6 @@ function gateway_paypal_multiple($seperator, $sessionid) {
|
|
162 |
$data['invoice'] = $sessionid;
|
163 |
|
164 |
// User details
|
165 |
-
|
166 |
if($_POST['collected_data'][get_option('paypal_form_first_name')] != '') {
|
167 |
$data['first_name'] = urlencode($_POST['collected_data'][get_option('paypal_form_first_name')]);
|
168 |
}
|
@@ -221,8 +220,6 @@ function gateway_paypal_multiple($seperator, $sessionid) {
|
|
221 |
$data['upload'] = '1';
|
222 |
$data['cmd'] = "_ext-enter";
|
223 |
$data['redirect_cmd'] = "_cart";
|
224 |
-
$data = apply_filters('wpsc_paypal_standard_post_data',$data);
|
225 |
-
|
226 |
$datacount = count($data);
|
227 |
$num = 0;
|
228 |
foreach($data as $key=>$value) {
|
@@ -643,4 +640,4 @@ $output .= "
|
|
643 |
|
644 |
|
645 |
add_action('init', 'nzshpcrt_paypal_ipn');
|
646 |
-
?>
|
162 |
$data['invoice'] = $sessionid;
|
163 |
|
164 |
// User details
|
|
|
165 |
if($_POST['collected_data'][get_option('paypal_form_first_name')] != '') {
|
166 |
$data['first_name'] = urlencode($_POST['collected_data'][get_option('paypal_form_first_name')]);
|
167 |
}
|
220 |
$data['upload'] = '1';
|
221 |
$data['cmd'] = "_ext-enter";
|
222 |
$data['redirect_cmd'] = "_cart";
|
|
|
|
|
223 |
$datacount = count($data);
|
224 |
$num = 0;
|
225 |
foreach($data as $key=>$value) {
|
640 |
|
641 |
|
642 |
add_action('init', 'nzshpcrt_paypal_ipn');
|
643 |
+
?>
|
merchants/paypal_pro.php
CHANGED
@@ -21,14 +21,14 @@ if(in_array('paypal_pro',(array)get_option('custom_gateway_options'))) {
|
|
21 |
|
22 |
$gateway_checkout_form_fields[$nzshpcrt_gateways[$num]['internalname']] = "
|
23 |
<tr %s>
|
24 |
-
<td>Credit Card Number
|
25 |
<td>
|
26 |
<input type='text' value='' name='card_number' />
|
27 |
<p class='validation-error'>%s</p>
|
28 |
</td>
|
29 |
</tr>
|
30 |
<tr %s>
|
31 |
-
<td>Credit Card Expiry
|
32 |
<td>
|
33 |
<select class='wpsc_ccBox' name='expiry[month]'>
|
34 |
".$months."
|
@@ -52,13 +52,13 @@ if(in_array('paypal_pro',(array)get_option('custom_gateway_options'))) {
|
|
52 |
</td>
|
53 |
</tr>
|
54 |
<tr %s>
|
55 |
-
<td>CVV
|
56 |
<td><input type='text' size='4' value='' maxlength='4' name='card_code' />
|
57 |
<p class='validation-error'>%s</p>
|
58 |
</td>
|
59 |
</tr>
|
60 |
<tr %s>
|
61 |
-
<td>Card Type
|
62 |
<td>
|
63 |
<select class='wpsc_ccBox' name='cctype'>
|
64 |
<option value='Visa'>Visa</option>
|
21 |
|
22 |
$gateway_checkout_form_fields[$nzshpcrt_gateways[$num]['internalname']] = "
|
23 |
<tr %s>
|
24 |
+
<td>Credit Card Number *</td>
|
25 |
<td>
|
26 |
<input type='text' value='' name='card_number' />
|
27 |
<p class='validation-error'>%s</p>
|
28 |
</td>
|
29 |
</tr>
|
30 |
<tr %s>
|
31 |
+
<td>Credit Card Expiry *</td>
|
32 |
<td>
|
33 |
<select class='wpsc_ccBox' name='expiry[month]'>
|
34 |
".$months."
|
52 |
</td>
|
53 |
</tr>
|
54 |
<tr %s>
|
55 |
+
<td>CVV *</td>
|
56 |
<td><input type='text' size='4' value='' maxlength='4' name='card_code' />
|
57 |
<p class='validation-error'>%s</p>
|
58 |
</td>
|
59 |
</tr>
|
60 |
<tr %s>
|
61 |
+
<td>Card Type *</td>
|
62 |
<td>
|
63 |
<select class='wpsc_ccBox' name='cctype'>
|
64 |
<option value='Visa'>Visa</option>
|
readme.txt
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
=== WP e-Commerce ===
|
2 |
Contributors: Dan Milward, Tom Howard, Jeffry Ghazally
|
3 |
-
Donate link: http://
|
4 |
Tags: e-commerce, shop, cart, dropshop, ajax, web2.0, paypal, authorize, exchange, stock control, ecommerce
|
5 |
Requires at least: 2.7
|
6 |
Tested up to: 2.9
|
@@ -36,6 +36,15 @@ If you experience database errors try de-activating and re-activating your plugi
|
|
36 |
|
37 |
|
38 |
== Changelog ==
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
39 |
= 3.7.5.4 =
|
40 |
* Implemented the new UPS Api for shipping calculation. The old API is being depricated
|
41 |
* Added switch to specify use of the UPS testing environment
|
@@ -100,7 +109,7 @@ If you experience database errors try de-activating and re-activating your plugi
|
|
100 |
|
101 |
= Where do I find DropShop and Grid View =
|
102 |
|
103 |
-
From the BlogShop of course http://
|
104 |
|
105 |
= How do I customize WP e-Commerce =
|
106 |
|
@@ -113,11 +122,4 @@ Advanced users can edit the CSS (and do just about anything). Not so advanced us
|
|
113 |
We're taking this one step further.
|
114 |
|
115 |
Check out our flickr guides online
|
116 |
-
www.flickr.com/photos/danmilward/sets/72157594425079473/detail/
|
117 |
-
|
118 |
-
== Readme Validator ==
|
119 |
-
|
120 |
-
This readme was made using:
|
121 |
-
wordpress.org/extend/plugins/about/validator/
|
122 |
-
|
123 |
-
Totally totally cool tool!!
|
1 |
=== WP e-Commerce ===
|
2 |
Contributors: Dan Milward, Tom Howard, Jeffry Ghazally
|
3 |
+
Donate link: http://getshopped.org/
|
4 |
Tags: e-commerce, shop, cart, dropshop, ajax, web2.0, paypal, authorize, exchange, stock control, ecommerce
|
5 |
Requires at least: 2.7
|
6 |
Tested up to: 2.9
|
36 |
|
37 |
|
38 |
== Changelog ==
|
39 |
+
= 3.7.6.1 =
|
40 |
+
* Bugfix release
|
41 |
+
|
42 |
+
= 3.7.6 =
|
43 |
+
* Significant upgrade
|
44 |
+
* New Pagination Implementation
|
45 |
+
* Improved marketing, including Google Merchant Centre support
|
46 |
+
* gettext implementation for themes
|
47 |
+
|
48 |
= 3.7.5.4 =
|
49 |
* Implemented the new UPS Api for shipping calculation. The old API is being depricated
|
50 |
* Added switch to specify use of the UPS testing environment
|
109 |
|
110 |
= Where do I find DropShop and Grid View =
|
111 |
|
112 |
+
From the BlogShop of course http://getshopped.org/extend/premium-upgrades/
|
113 |
|
114 |
= How do I customize WP e-Commerce =
|
115 |
|
122 |
We're taking this one step further.
|
123 |
|
124 |
Check out our flickr guides online
|
125 |
+
http://www.flickr.com/photos/danmilward/sets/72157594425079473/detail/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
themes/default/category_widget.php
CHANGED
@@ -36,5 +36,5 @@
|
|
36 |
</div>
|
37 |
|
38 |
<?php endif;?>
|
39 |
-
|
40 |
-
|
36 |
</div>
|
37 |
|
38 |
<?php endif;?>
|
39 |
+
</div>
|
40 |
+
<div class='clear_category_group'></div>
|
themes/default/default.css
CHANGED
@@ -15,6 +15,7 @@ Author URI: http://instinct.co.nz
|
|
15 |
.wpsc_container{
|
16 |
position: relative;
|
17 |
_zoom: 1;
|
|
|
18 |
}
|
19 |
|
20 |
div.productdisplay img {
|
@@ -23,7 +24,10 @@ div.productdisplay img {
|
|
23 |
border: none;
|
24 |
}
|
25 |
|
26 |
-
|
|
|
|
|
|
|
27 |
#change_country{
|
28 |
float:left;
|
29 |
}
|
15 |
.wpsc_container{
|
16 |
position: relative;
|
17 |
_zoom: 1;
|
18 |
+
clear: both;
|
19 |
}
|
20 |
|
21 |
div.productdisplay img {
|
24 |
border: none;
|
25 |
}
|
26 |
|
27 |
+
a.wpsc-current-cat{
|
28 |
+
font-weight: bold;
|
29 |
+
color:#000000 !important;
|
30 |
+
}
|
31 |
#change_country{
|
32 |
float:left;
|
33 |
}
|
themes/default/grid_view.php
CHANGED
@@ -23,7 +23,7 @@ $image_height = get_option('product_image_height');
|
|
23 |
<?php if(wpsc_display_categories()): ?>
|
24 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
25 |
<div class='wpsc_categories wpsc_category_grid'>
|
26 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
27 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
28 |
<?php wpsc_print_category_image(45, 45); ?>
|
29 |
</a>
|
@@ -33,7 +33,7 @@ $image_height = get_option('product_image_height');
|
|
33 |
</div>
|
34 |
<?php else:?>
|
35 |
<ul class='wpsc_categories'>
|
36 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
37 |
<li>
|
38 |
<?php wpsc_print_category_image(32, 32); ?>
|
39 |
|
@@ -66,31 +66,27 @@ $image_height = get_option('product_image_height');
|
|
66 |
<?php endif; ?>
|
67 |
|
68 |
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
<?php
|
73 |
-
<?php
|
74 |
-
|
75 |
-
<?php else: ?>
|
76 |
-
<a href='<?php echo wpsc_page_url(); ?>'><?php echo wpsc_page_number(); ?></a>
|
77 |
-
<?php endif; ?>
|
78 |
-
<?php endwhile; ?>
|
79 |
</div>
|
80 |
<?php endif; ?>
|
|
|
|
|
81 |
|
82 |
-
|
83 |
-
|
84 |
<div class="product_grid_display">
|
85 |
<?php while (wpsc_have_products()) : wpsc_the_product(); ?>
|
86 |
<div class="product_grid_item product_view_<?php echo wpsc_the_product_id(); ?>">
|
87 |
-
|
88 |
-
|
89 |
<?php if(wpsc_the_product_thumbnail()) :?>
|
|
|
90 |
<a href="<?php echo wpsc_the_product_permalink(); ?>">
|
91 |
<img class="product_image" id="product_image_<?php echo wpsc_the_product_id(); ?>" alt="<?php echo wpsc_the_product_title(); ?>" title="<?php echo wpsc_the_product_title(); ?>" src="<?php echo wpsc_the_product_thumbnail(); ?>" />
|
92 |
</a>
|
93 |
-
|
94 |
<?php else: ?>
|
95 |
<div class="item_no_image">
|
96 |
<a href="<?php echo wpsc_the_product_permalink(); ?>">
|
@@ -103,14 +99,19 @@ $image_height = get_option('product_image_height');
|
|
103 |
<?php if(get_option('show_images_only') != 1): ?>
|
104 |
<div class="grid_product_info">
|
105 |
<div class="product_text">
|
106 |
-
|
107 |
-
<div id="product_price_<?php echo wpsc_the_product_id(); ?>" class="pricedisplay"><?php echo wpsc_the_product_price(true); ?></div>
|
108 |
<strong><?php echo wpsc_the_product_title(); ?></strong>
|
109 |
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
114 |
</div>
|
115 |
</div>
|
116 |
<div class="grid_more_info">
|
@@ -171,18 +172,18 @@ $image_height = get_option('product_image_height');
|
|
171 |
|
172 |
</div>
|
173 |
|
174 |
-
|
175 |
-
|
176 |
-
|
177 |
-
|
178 |
-
<?php if(
|
179 |
-
|
180 |
-
<?php else: ?>
|
181 |
-
<a href='<?php echo wpsc_page_url(); ?>'><?php echo wpsc_page_number(); ?></a>
|
182 |
<?php endif; ?>
|
183 |
-
<?php endwhile; ?>
|
184 |
</div>
|
185 |
<?php endif; ?>
|
|
|
|
|
|
|
186 |
<?php endif; ?>
|
187 |
|
188 |
|
23 |
<?php if(wpsc_display_categories()): ?>
|
24 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
25 |
<div class='wpsc_categories wpsc_category_grid'>
|
26 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> 1)); ?>
|
27 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
28 |
<?php wpsc_print_category_image(45, 45); ?>
|
29 |
</a>
|
33 |
</div>
|
34 |
<?php else:?>
|
35 |
<ul class='wpsc_categories'>
|
36 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> get_option('show_category_thumbnails'))); ?>
|
37 |
<li>
|
38 |
<?php wpsc_print_category_image(32, 32); ?>
|
39 |
|
66 |
<?php endif; ?>
|
67 |
|
68 |
|
69 |
+
<!-- Start Pagination -->
|
70 |
+
<?php if ( ( get_option( 'use_pagination' ) == 1 && ( get_option( 'wpsc_page_number_position' ) == 1 || get_option( 'wpsc_page_number_position' ) == 3 ) ) ) : ?>
|
71 |
+
<div class="wpsc_page_numbers">
|
72 |
+
<?php if ( wpsc_has_pages() ) : ?>
|
73 |
+
Pages: <?php echo wpsc_first_products_link( '« First', true ); ?> <?php echo wpsc_previous_products_link( '« Previous', true ); ?> <?php echo wpsc_pagination( 10 ); ?> <?php echo wpsc_next_products_link( 'Next »', true ); ?> <?php echo wpsc_last_products_link( 'Last »', true ); ?>
|
74 |
+
<?php endif; ?>
|
|
|
|
|
|
|
|
|
75 |
</div>
|
76 |
<?php endif; ?>
|
77 |
+
<!-- End Pagination -->
|
78 |
+
|
79 |
|
|
|
|
|
80 |
<div class="product_grid_display">
|
81 |
<?php while (wpsc_have_products()) : wpsc_the_product(); ?>
|
82 |
<div class="product_grid_item product_view_<?php echo wpsc_the_product_id(); ?>">
|
83 |
+
|
|
|
84 |
<?php if(wpsc_the_product_thumbnail()) :?>
|
85 |
+
<div class="item_image">
|
86 |
<a href="<?php echo wpsc_the_product_permalink(); ?>">
|
87 |
<img class="product_image" id="product_image_<?php echo wpsc_the_product_id(); ?>" alt="<?php echo wpsc_the_product_title(); ?>" title="<?php echo wpsc_the_product_title(); ?>" src="<?php echo wpsc_the_product_thumbnail(); ?>" />
|
88 |
</a>
|
89 |
+
</div>
|
90 |
<?php else: ?>
|
91 |
<div class="item_no_image">
|
92 |
<a href="<?php echo wpsc_the_product_permalink(); ?>">
|
99 |
<?php if(get_option('show_images_only') != 1): ?>
|
100 |
<div class="grid_product_info">
|
101 |
<div class="product_text">
|
|
|
|
|
102 |
<strong><?php echo wpsc_the_product_title(); ?></strong>
|
103 |
|
104 |
+
<?php if((wpsc_the_product_description() != '') && (get_option('display_description') == 1)): ?>
|
105 |
+
<p class='griddescription'><?php echo wpsc_the_product_description(); ?></p>
|
106 |
+
<?php endif; ?>
|
107 |
+
|
108 |
+
<br/>
|
109 |
+
<span id="product_price_<?php echo wpsc_the_product_id(); ?>" class="pricedisplay"><?php echo wpsc_the_product_price(); ?></span>Price:
|
110 |
+
|
111 |
+
<?php if(get_option('display_moredetails') == 1) : ?>
|
112 |
+
<br />
|
113 |
+
<a href='<?php echo wpsc_the_product_permalink(); ?>'>More Details</a>
|
114 |
+
<?php endif; ?>
|
115 |
</div>
|
116 |
</div>
|
117 |
<div class="grid_more_info">
|
172 |
|
173 |
</div>
|
174 |
|
175 |
+
|
176 |
+
<!-- Start Pagination -->
|
177 |
+
<?php if ( ( get_option( 'use_pagination' ) == 1 && ( get_option( 'wpsc_page_number_position' ) == 2 || get_option( 'wpsc_page_number_position' ) == 3 ) ) ) : ?>
|
178 |
+
<div class="wpsc_page_numbers">
|
179 |
+
<?php if ( wpsc_has_pages() ) : ?>
|
180 |
+
Pages: <?php echo wpsc_first_products_link( '« First', true ); ?> <?php echo wpsc_previous_products_link( '« Previous', true ); ?> <?php echo wpsc_pagination( 10 ); ?> <?php echo wpsc_next_products_link( 'Next »', true ); ?> <?php echo wpsc_last_products_link( 'Last »', true ); ?>
|
|
|
|
|
181 |
<?php endif; ?>
|
|
|
182 |
</div>
|
183 |
<?php endif; ?>
|
184 |
+
<!-- End Pagination -->
|
185 |
+
|
186 |
+
|
187 |
<?php endif; ?>
|
188 |
|
189 |
|
themes/default/list_view.php
CHANGED
@@ -21,7 +21,7 @@ global $wpsc_query, $wpdb;
|
|
21 |
<?php if(wpsc_display_categories()): ?>
|
22 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
23 |
<div class='wpsc_categories wpsc_category_grid'>
|
24 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
25 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
26 |
<?php wpsc_print_category_image(45, 45); ?>
|
27 |
</a>
|
@@ -31,7 +31,7 @@ global $wpsc_query, $wpdb;
|
|
31 |
</div>
|
32 |
<?php else:?>
|
33 |
<ul class='wpsc_categories'>
|
34 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
35 |
<li>
|
36 |
<?php wpsc_print_category_image(32, 32); ?>
|
37 |
|
21 |
<?php if(wpsc_display_categories()): ?>
|
22 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
23 |
<div class='wpsc_categories wpsc_category_grid'>
|
24 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> 1)); ?>
|
25 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
26 |
<?php wpsc_print_category_image(45, 45); ?>
|
27 |
</a>
|
31 |
</div>
|
32 |
<?php else:?>
|
33 |
<ul class='wpsc_categories'>
|
34 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> get_option('show_category_thumbnails'))); ?>
|
35 |
<li>
|
36 |
<?php wpsc_print_category_image(32, 32); ?>
|
37 |
|
themes/default/products_page.php
CHANGED
@@ -211,11 +211,11 @@ global $wpsc_query, $wpdb;
|
|
211 |
|
212 |
<?php else : ?>
|
213 |
<?php if(wpsc_product_on_special()) : ?>
|
214 |
-
<span class='oldprice'><?php echo __('Price', 'wpsc'); ?>: <?php echo wpsc_product_normal_price(
|
215 |
<?php endif; ?>
|
216 |
-
<span id="product_price_<?php echo wpsc_the_product_id(); ?>" class="pricedisplay"><?php echo wpsc_the_product_price(
|
217 |
<?php if(get_option('display_pnp') == 1) : ?>
|
218 |
-
<span class="pricedisplay"><?php echo wpsc_product_postage_and_packaging(
|
219 |
<?php endif; ?>
|
220 |
<?php endif; ?>
|
221 |
</div>
|
211 |
|
212 |
<?php else : ?>
|
213 |
<?php if(wpsc_product_on_special()) : ?>
|
214 |
+
<span class='oldprice'><?php echo __('Price', 'wpsc'); ?>: <?php echo wpsc_product_normal_price(); ?></span><br />
|
215 |
<?php endif; ?>
|
216 |
+
<span id="product_price_<?php echo wpsc_the_product_id(); ?>" class="pricedisplay"><?php echo wpsc_the_product_price(); ?></span><?php echo __('Price', 'wpsc'); ?>: <br/>
|
217 |
<?php if(get_option('display_pnp') == 1) : ?>
|
218 |
+
<span class="pricedisplay"><?php echo wpsc_product_postage_and_packaging(); ?></span><?php echo __('P&P', 'wpsc'); ?>: <br />
|
219 |
<?php endif; ?>
|
220 |
<?php endif; ?>
|
221 |
</div>
|
themes/default/shopping_cart_page.php
CHANGED
@@ -128,7 +128,7 @@ if(wpsc_cart_item_count() > 0) :
|
|
128 |
<?php if (!wpsc_have_shipping_quotes()) { continue; } // Don't display shipping method if it doesn't have at least one quote ?>
|
129 |
<tr><td class='shipping_header' colspan='5'><?php echo wpsc_shipping_method_name().__('- Choose a Shipping Rate', 'wpsc'); ?> </td></tr>
|
130 |
<?php while (wpsc_have_shipping_quotes()) : wpsc_the_shipping_quote(); ?>
|
131 |
-
<tr>
|
132 |
<td colspan='3'>
|
133 |
<label for='<?php echo wpsc_shipping_quote_html_id(); ?>'><?php echo wpsc_shipping_quote_name(); ?></label>
|
134 |
</td>
|
@@ -282,7 +282,7 @@ if(wpsc_cart_item_count() > 0) :
|
|
282 |
<tr <?php echo wpsc_the_checkout_item_error_class();?>>
|
283 |
<td>
|
284 |
<label for='<?php echo wpsc_checkout_form_element_id(); ?>'>
|
285 |
-
<?php echo wpsc_checkout_form_name()
|
286 |
</label>
|
287 |
</td>
|
288 |
<td>
|
@@ -314,7 +314,7 @@ if(wpsc_cart_item_count() > 0) :
|
|
314 |
</tr>
|
315 |
<?php endif; ?>
|
316 |
<tr>
|
317 |
-
<td colspan='2'
|
318 |
|
319 |
<?php //this HTML displays activated payment gateways?>
|
320 |
|
@@ -380,7 +380,7 @@ if(wpsc_cart_item_count() > 0) :
|
|
380 |
</div>
|
381 |
<?php
|
382 |
else:
|
383 |
-
echo __('Oops, there is nothing in your cart.', 'wpsc') . "<a href=".get_option("product_list_url").">" . __('Please visit our shop', 'wpsc') . "</a>";
|
384 |
endif;
|
385 |
do_action('wpsc_bottom_of_shopping_cart');
|
386 |
?>
|
128 |
<?php if (!wpsc_have_shipping_quotes()) { continue; } // Don't display shipping method if it doesn't have at least one quote ?>
|
129 |
<tr><td class='shipping_header' colspan='5'><?php echo wpsc_shipping_method_name().__('- Choose a Shipping Rate', 'wpsc'); ?> </td></tr>
|
130 |
<?php while (wpsc_have_shipping_quotes()) : wpsc_the_shipping_quote(); ?>
|
131 |
+
<tr class='shipping_quotes'>
|
132 |
<td colspan='3'>
|
133 |
<label for='<?php echo wpsc_shipping_quote_html_id(); ?>'><?php echo wpsc_shipping_quote_name(); ?></label>
|
134 |
</td>
|
282 |
<tr <?php echo wpsc_the_checkout_item_error_class();?>>
|
283 |
<td>
|
284 |
<label for='<?php echo wpsc_checkout_form_element_id(); ?>'>
|
285 |
+
<?php echo wpsc_checkout_form_name();?>:
|
286 |
</label>
|
287 |
</td>
|
288 |
<td>
|
314 |
</tr>
|
315 |
<?php endif; ?>
|
316 |
<tr>
|
317 |
+
<td colspan='2'>
|
318 |
|
319 |
<?php //this HTML displays activated payment gateways?>
|
320 |
|
380 |
</div>
|
381 |
<?php
|
382 |
else:
|
383 |
+
echo __('Oops, there is nothing in your cart.', 'wpsc') . "<a href='".get_option("product_list_url")."'>" . __('Please visit our shop', 'wpsc') . "</a>";
|
384 |
endif;
|
385 |
do_action('wpsc_bottom_of_shopping_cart');
|
386 |
?>
|
themes/iShop/grid_view.php
CHANGED
@@ -23,7 +23,7 @@ $image_height = get_option('product_image_height');
|
|
23 |
<?php if(wpsc_display_categories()): ?>
|
24 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
25 |
<div class='wpsc_categories wpsc_category_grid'>
|
26 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
27 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
28 |
<?php wpsc_print_category_image(45, 45); ?>
|
29 |
</a>
|
@@ -33,7 +33,7 @@ $image_height = get_option('product_image_height');
|
|
33 |
</div>
|
34 |
<?php else:?>
|
35 |
<ul class='wpsc_categories'>
|
36 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
37 |
<li>
|
38 |
<?php wpsc_print_category_image(32, 32); ?>
|
39 |
|
23 |
<?php if(wpsc_display_categories()): ?>
|
24 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
25 |
<div class='wpsc_categories wpsc_category_grid'>
|
26 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> 1)); ?>
|
27 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
28 |
<?php wpsc_print_category_image(45, 45); ?>
|
29 |
</a>
|
33 |
</div>
|
34 |
<?php else:?>
|
35 |
<ul class='wpsc_categories'>
|
36 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> get_option('show_category_thumbnails'))); ?>
|
37 |
<li>
|
38 |
<?php wpsc_print_category_image(32, 32); ?>
|
39 |
|
themes/iShop/list_view.php
CHANGED
@@ -21,7 +21,7 @@ global $wpsc_query, $wpdb;
|
|
21 |
<?php if(wpsc_display_categories()): ?>
|
22 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
23 |
<div class='wpsc_categories wpsc_category_grid'>
|
24 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
25 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
26 |
<?php wpsc_print_category_image(45, 45); ?>
|
27 |
</a>
|
@@ -31,7 +31,7 @@ global $wpsc_query, $wpdb;
|
|
31 |
</div>
|
32 |
<?php else:?>
|
33 |
<ul class='wpsc_categories'>
|
34 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
35 |
<li>
|
36 |
<?php wpsc_print_category_image(32, 32); ?>
|
37 |
|
21 |
<?php if(wpsc_display_categories()): ?>
|
22 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
23 |
<div class='wpsc_categories wpsc_category_grid'>
|
24 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> 1)); ?>
|
25 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
26 |
<?php wpsc_print_category_image(45, 45); ?>
|
27 |
</a>
|
31 |
</div>
|
32 |
<?php else:?>
|
33 |
<ul class='wpsc_categories'>
|
34 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> get_option('show_category_thumbnails'))); ?>
|
35 |
<li>
|
36 |
<?php wpsc_print_category_image(32, 32); ?>
|
37 |
|
themes/iShop/products_page.php
CHANGED
@@ -209,11 +209,11 @@ global $wpsc_query, $wpdb;
|
|
209 |
|
210 |
<?php else : ?>
|
211 |
<?php if(wpsc_product_on_special()) : ?>
|
212 |
-
<span class='oldprice'><?php echo __('Price', 'wpsc'); ?>: <?php echo wpsc_product_normal_price(
|
213 |
<?php endif; ?>
|
214 |
-
<span id="product_price_<?php echo wpsc_the_product_id(); ?>" class="pricedisplay"><?php echo wpsc_the_product_price(
|
215 |
<?php if(get_option('display_pnp') == 1) : ?>
|
216 |
-
<span class="pricedisplay"><?php echo wpsc_product_postage_and_packaging(
|
217 |
<?php endif; ?>
|
218 |
<?php endif; ?>
|
219 |
</div>
|
209 |
|
210 |
<?php else : ?>
|
211 |
<?php if(wpsc_product_on_special()) : ?>
|
212 |
+
<span class='oldprice'><?php echo __('Price', 'wpsc'); ?>: <?php echo wpsc_product_normal_price(); ?></span><br />
|
213 |
<?php endif; ?>
|
214 |
+
<span id="product_price_<?php echo wpsc_the_product_id(); ?>" class="pricedisplay"><?php echo wpsc_the_product_price(); ?></span><?php echo __('Price', 'wpsc'); ?>:<br/>
|
215 |
<?php if(get_option('display_pnp') == 1) : ?>
|
216 |
+
<span class="pricedisplay"><?php echo wpsc_product_postage_and_packaging(); ?></span><?php echo __('P&P', 'wpsc'); ?>: <br />
|
217 |
<?php endif; ?>
|
218 |
<?php endif; ?>
|
219 |
</div>
|
themes/iShop/shopping_cart_page.php
CHANGED
@@ -112,8 +112,10 @@ if(wpsc_cart_item_count() > 0) :
|
|
112 |
if (!wpsc_have_shipping_quotes()) continue;
|
113 |
?>
|
114 |
<tr><td class='shipping_header' colspan='5'><?php echo wpsc_shipping_method_name().__('- Choose a Shipping Rate', 'wpsc'); ?> </td></tr>
|
115 |
-
<?php while (wpsc_have_shipping_quotes()) : wpsc_the_shipping_quote();
|
116 |
-
|
|
|
|
|
117 |
<td colspan='3'>
|
118 |
<label for='<?php echo wpsc_shipping_quote_html_id(); ?>'><?php echo wpsc_shipping_quote_name(); ?></label>
|
119 |
</td>
|
@@ -253,7 +255,7 @@ if(wpsc_cart_item_count() > 0) :
|
|
253 |
<tr <?php echo wpsc_the_checkout_item_error_class();?>>
|
254 |
<td>
|
255 |
<label for='<?php echo wpsc_checkout_form_element_id(); ?>'>
|
256 |
-
<?php echo wpsc_checkout_form_name()
|
257 |
</label>
|
258 |
</td>
|
259 |
<td>
|
112 |
if (!wpsc_have_shipping_quotes()) continue;
|
113 |
?>
|
114 |
<tr><td class='shipping_header' colspan='5'><?php echo wpsc_shipping_method_name().__('- Choose a Shipping Rate', 'wpsc'); ?> </td></tr>
|
115 |
+
<?php while (wpsc_have_shipping_quotes()) : wpsc_the_shipping_quote();
|
116 |
+
|
117 |
+
?>
|
118 |
+
<tr>
|
119 |
<td colspan='3'>
|
120 |
<label for='<?php echo wpsc_shipping_quote_html_id(); ?>'><?php echo wpsc_shipping_quote_name(); ?></label>
|
121 |
</td>
|
255 |
<tr <?php echo wpsc_the_checkout_item_error_class();?>>
|
256 |
<td>
|
257 |
<label for='<?php echo wpsc_checkout_form_element_id(); ?>'>
|
258 |
+
<?php echo wpsc_checkout_form_name();?>:
|
259 |
</label>
|
260 |
</td>
|
261 |
<td>
|
themes/marketplace/grid_view.php
CHANGED
@@ -23,7 +23,7 @@ $image_height = get_option('product_image_height');
|
|
23 |
<?php if(wpsc_display_categories()): ?>
|
24 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
25 |
<div class='wpsc_categories wpsc_category_grid'>
|
26 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
27 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
28 |
<?php wpsc_print_category_image(45, 45); ?>
|
29 |
</a>
|
@@ -33,7 +33,7 @@ $image_height = get_option('product_image_height');
|
|
33 |
</div>
|
34 |
<?php else:?>
|
35 |
<ul class='wpsc_categories'>
|
36 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
37 |
<li>
|
38 |
<?php wpsc_print_category_image(32, 32); ?>
|
39 |
|
23 |
<?php if(wpsc_display_categories()): ?>
|
24 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
25 |
<div class='wpsc_categories wpsc_category_grid'>
|
26 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> 1)); ?>
|
27 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
28 |
<?php wpsc_print_category_image(45, 45); ?>
|
29 |
</a>
|
33 |
</div>
|
34 |
<?php else:?>
|
35 |
<ul class='wpsc_categories'>
|
36 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> get_option('show_category_thumbnails'))); ?>
|
37 |
<li>
|
38 |
<?php wpsc_print_category_image(32, 32); ?>
|
39 |
|
themes/marketplace/list_view.php
CHANGED
@@ -21,7 +21,7 @@ global $wpsc_query, $wpdb;
|
|
21 |
<?php if(wpsc_display_categories()): ?>
|
22 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
23 |
<div class='wpsc_categories wpsc_category_grid'>
|
24 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
25 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
26 |
<?php wpsc_print_category_image(45, 45); ?>
|
27 |
</a>
|
@@ -31,7 +31,7 @@ global $wpsc_query, $wpdb;
|
|
31 |
</div>
|
32 |
<?php else:?>
|
33 |
<ul class='wpsc_categories'>
|
34 |
-
<?php wpsc_start_category_query(array('category_group'=>
|
35 |
<li>
|
36 |
<?php wpsc_print_category_image(32, 32); ?>
|
37 |
|
21 |
<?php if(wpsc_display_categories()): ?>
|
22 |
<?php if(get_option('wpsc_category_grid_view') == 1) :?>
|
23 |
<div class='wpsc_categories wpsc_category_grid'>
|
24 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> 1)); ?>
|
25 |
<a href="<?php wpsc_print_category_url();?>" class="wpsc_category_grid_item" title='<?php wpsc_print_category_name();?>'>
|
26 |
<?php wpsc_print_category_image(45, 45); ?>
|
27 |
</a>
|
31 |
</div>
|
32 |
<?php else:?>
|
33 |
<ul class='wpsc_categories'>
|
34 |
+
<?php wpsc_start_category_query(array('category_group'=> 1, 'show_thumbnails'=> get_option('show_category_thumbnails'))); ?>
|
35 |
<li>
|
36 |
<?php wpsc_print_category_image(32, 32); ?>
|
37 |
|
themes/marketplace/products_page.php
CHANGED
@@ -213,11 +213,11 @@ global $wpsc_query, $wpdb;
|
|
213 |
|
214 |
<?php else : ?>
|
215 |
<?php if(wpsc_product_on_special()) : ?>
|
216 |
-
<span class='oldprice'><?php echo __('Price', 'wpsc'); ?>: <?php echo wpsc_product_normal_price(
|
217 |
<?php endif; ?>
|
218 |
-
<span id="product_price_<?php echo wpsc_the_product_id(); ?>" class="pricedisplay"><?php echo wpsc_the_product_price(
|
219 |
<?php if(get_option('display_pnp') == 1) : ?>
|
220 |
-
<span class="pricedisplay"><?php echo wpsc_product_postage_and_packaging(
|
221 |
<?php endif; ?>
|
222 |
<?php endif; ?>
|
223 |
</div>
|
213 |
|
214 |
<?php else : ?>
|
215 |
<?php if(wpsc_product_on_special()) : ?>
|
216 |
+
<span class='oldprice'><?php echo __('Price', 'wpsc'); ?>: <?php echo wpsc_product_normal_price(); ?></span><br />
|
217 |
<?php endif; ?>
|
218 |
+
<span id="product_price_<?php echo wpsc_the_product_id(); ?>" class="pricedisplay"><?php echo wpsc_the_product_price(); ?></span><?php echo __('Price', 'wpsc'); ?>:<br/>
|
219 |
<?php if(get_option('display_pnp') == 1) : ?>
|
220 |
+
<span class="pricedisplay"><?php echo wpsc_product_postage_and_packaging(); ?></span><?php echo __('P&P', 'wpsc'); ?>: <br />
|
221 |
<?php endif; ?>
|
222 |
<?php endif; ?>
|
223 |
</div>
|
themes/marketplace/shopping_cart_page.php
CHANGED
@@ -111,8 +111,10 @@ if(wpsc_cart_item_count() > 0) :
|
|
111 |
if (!wpsc_have_shipping_quotes()) continue;
|
112 |
?>
|
113 |
<tr><td class='shipping_header' colspan='5'><?php echo wpsc_shipping_method_name().__('- Choose a Shipping Rate', 'wpsc'); ?> </td></tr>
|
114 |
-
<?php while (wpsc_have_shipping_quotes()) : wpsc_the_shipping_quote();
|
115 |
-
|
|
|
|
|
116 |
<td colspan='3'>
|
117 |
<label for='<?php echo wpsc_shipping_quote_html_id(); ?>'><?php echo wpsc_shipping_quote_name(); ?></label>
|
118 |
</td>
|
@@ -251,7 +253,7 @@ if(wpsc_cart_item_count() > 0) :
|
|
251 |
<tr <?php echo wpsc_the_checkout_item_error_class();?>>
|
252 |
<td>
|
253 |
<label for='<?php echo wpsc_checkout_form_element_id(); ?>'>
|
254 |
-
<?php echo wpsc_checkout_form_name()
|
255 |
</label>
|
256 |
</td>
|
257 |
<td>
|
111 |
if (!wpsc_have_shipping_quotes()) continue;
|
112 |
?>
|
113 |
<tr><td class='shipping_header' colspan='5'><?php echo wpsc_shipping_method_name().__('- Choose a Shipping Rate', 'wpsc'); ?> </td></tr>
|
114 |
+
<?php while (wpsc_have_shipping_quotes()) : wpsc_the_shipping_quote();
|
115 |
+
|
116 |
+
?>
|
117 |
+
<tr>
|
118 |
<td colspan='3'>
|
119 |
<label for='<?php echo wpsc_shipping_quote_html_id(); ?>'><?php echo wpsc_shipping_quote_name(); ?></label>
|
120 |
</td>
|
253 |
<tr <?php echo wpsc_the_checkout_item_error_class();?>>
|
254 |
<td>
|
255 |
<label for='<?php echo wpsc_checkout_form_element_id(); ?>'>
|
256 |
+
<?php echo wpsc_checkout_form_name();?>:
|
257 |
</label>
|
258 |
</td>
|
259 |
<td>
|
transaction_results.php
CHANGED
@@ -40,12 +40,10 @@ if($_REQUEST['eway']=='1') {
|
|
40 |
if($_SESSION['wpsc_previous_selected_gateway'] == 'paypal_certified'){
|
41 |
echo $_SESSION['paypalExpressMessage'];
|
42 |
|
43 |
-
|
44 |
} elseif($sessionid == ''){
|
45 |
_e('Sorry your transaction was not accepted.<br /><a href='.get_option("shopping_cart_url").'>Click here to go back to checkout page.</a>');
|
46 |
|
47 |
}else{
|
48 |
-
|
49 |
if($_SESSION['wpsc_previous_selected_gateway']== 'dps') {
|
50 |
$sessionid = decrypt_dps_response();
|
51 |
//exit($sessionid);
|
@@ -60,8 +58,4 @@ if($_SESSION['wpsc_previous_selected_gateway'] == 'paypal_certified'){
|
|
60 |
echo transaction_results($sessionid, true);
|
61 |
}
|
62 |
}
|
63 |
-
if($sessionid != ''){
|
64 |
-
//exit('<pre>'.print_r($sessionid, true).'</pre>');
|
65 |
-
//transaction_results($sessionid, true);
|
66 |
-
}
|
67 |
?>
|
40 |
if($_SESSION['wpsc_previous_selected_gateway'] == 'paypal_certified'){
|
41 |
echo $_SESSION['paypalExpressMessage'];
|
42 |
|
|
|
43 |
} elseif($sessionid == ''){
|
44 |
_e('Sorry your transaction was not accepted.<br /><a href='.get_option("shopping_cart_url").'>Click here to go back to checkout page.</a>');
|
45 |
|
46 |
}else{
|
|
|
47 |
if($_SESSION['wpsc_previous_selected_gateway']== 'dps') {
|
48 |
$sessionid = decrypt_dps_response();
|
49 |
//exit($sessionid);
|
58 |
echo transaction_results($sessionid, true);
|
59 |
}
|
60 |
}
|
|
|
|
|
|
|
|
|
61 |
?>
|
user-downloads.php
CHANGED
@@ -67,8 +67,5 @@ if(count($files) > 0) {
|
|
67 |
<?php
|
68 |
} else {
|
69 |
echo __('You have not purchased any downloadable products yet.', 'wpsc');
|
70 |
-
}
|
71 |
-
</div>
|
72 |
-
<?php
|
73 |
-
|
74 |
?>
|
67 |
<?php
|
68 |
} else {
|
69 |
echo __('You have not purchased any downloadable products yet.', 'wpsc');
|
70 |
+
}
|
|
|
|
|
|
|
71 |
?>
|
user-log.php
CHANGED
@@ -393,6 +393,7 @@ $date_list[0]['end'] = $end_timestamp;
|
|
393 |
echo " </td>\n\r";
|
394 |
echo "</tr>\n\r";
|
395 |
}
|
|
|
396 |
}
|
397 |
else
|
398 |
{
|
@@ -442,4 +443,4 @@ $date_list[0]['end'] = $end_timestamp;
|
|
442 |
}
|
443 |
?>
|
444 |
</div>
|
445 |
-
<?php } ?>
|
393 |
echo " </td>\n\r";
|
394 |
echo "</tr>\n\r";
|
395 |
}
|
396 |
+
echo "</tr>";
|
397 |
}
|
398 |
else
|
399 |
{
|
443 |
}
|
444 |
?>
|
445 |
</div>
|
446 |
+
<?php } ?>
|
wp-shopping-cart.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name:WP Shopping Cart
|
4 |
Plugin URI: http://www.getshopped.org
|
5 |
Description: A plugin that provides a WordPress Shopping Cart. Visit the <a href='http://getshopped.org/forums'>getshopped forums</a> for support.
|
6 |
-
Version: 3.7.6
|
7 |
Author: Instinct
|
8 |
Author URI: http://www.getshopped.org
|
9 |
*/
|
@@ -14,9 +14,9 @@ Author URI: http://www.getshopped.org
|
|
14 |
// this is to make sure it sets up the table name constants correctly on activation
|
15 |
global $wpdb;
|
16 |
define('WPSC_VERSION', '3.7');
|
17 |
-
define('WPSC_MINOR_VERSION', '
|
18 |
|
19 |
-
define('WPSC_PRESENTABLE_VERSION', '3.7.6
|
20 |
|
21 |
define('WPSC_DEBUG', false);
|
22 |
define('WPSC_GATEWAY_DEBUG', false);
|
@@ -291,13 +291,7 @@ $shipping_directory = WPSC_FILE_PATH.'/shipping';
|
|
291 |
$nzshpcrt_shipping_list = wpsc_list_dir($shipping_directory);
|
292 |
foreach($nzshpcrt_shipping_list as $nzshpcrt_shipping) {
|
293 |
if(stristr( $nzshpcrt_shipping , '.php' )) {
|
294 |
-
|
295 |
-
if (phpMinV('5')){
|
296 |
-
require(WPSC_FILE_PATH."/shipping/".$nzshpcrt_shipping);
|
297 |
-
}
|
298 |
-
}else{
|
299 |
-
require(WPSC_FILE_PATH."/shipping/".$nzshpcrt_shipping);
|
300 |
-
}
|
301 |
}
|
302 |
}
|
303 |
$wpsc_shipping_modules = apply_filters('wpsc_shipping_modules',$wpsc_shipping_modules);
|
3 |
Plugin Name:WP Shopping Cart
|
4 |
Plugin URI: http://www.getshopped.org
|
5 |
Description: A plugin that provides a WordPress Shopping Cart. Visit the <a href='http://getshopped.org/forums'>getshopped forums</a> for support.
|
6 |
+
Version: 3.7.6 RC 2
|
7 |
Author: Instinct
|
8 |
Author URI: http://www.getshopped.org
|
9 |
*/
|
14 |
// this is to make sure it sets up the table name constants correctly on activation
|
15 |
global $wpdb;
|
16 |
define('WPSC_VERSION', '3.7');
|
17 |
+
define('WPSC_MINOR_VERSION', '48');
|
18 |
|
19 |
+
define('WPSC_PRESENTABLE_VERSION', '3.7.6 Beta 2');
|
20 |
|
21 |
define('WPSC_DEBUG', false);
|
22 |
define('WPSC_GATEWAY_DEBUG', false);
|
291 |
$nzshpcrt_shipping_list = wpsc_list_dir($shipping_directory);
|
292 |
foreach($nzshpcrt_shipping_list as $nzshpcrt_shipping) {
|
293 |
if(stristr( $nzshpcrt_shipping , '.php' )) {
|
294 |
+
require(WPSC_FILE_PATH."/shipping/".$nzshpcrt_shipping);
|
|
|
|
|
|
|
|
|
|
|
|
|
295 |
}
|
296 |
}
|
297 |
$wpsc_shipping_modules = apply_filters('wpsc_shipping_modules',$wpsc_shipping_modules);
|
wpsc-admin/admin.php
CHANGED
@@ -755,12 +755,6 @@ function wpsc_admin_4months_widget_rightnow() {
|
|
755 |
echo "</div>";
|
756 |
}
|
757 |
}
|
758 |
-
function wpsc_getshopped_news_meta_box(){
|
759 |
-
$rss = fetch_feed('http://getshopped.org/category/community-plugins/feed/');
|
760 |
-
$args = array('show_author' => 1, 'show_date' => 1, 'show_summary' => 1, 'items'=>3 );
|
761 |
-
wp_widget_rss_output($rss, $args);
|
762 |
-
}
|
763 |
-
|
764 |
|
765 |
if( IS_WP27 ) {
|
766 |
add_action('wp_dashboard_setup','wpsc_dashboard_4months_widget_setup');
|
755 |
echo "</div>";
|
756 |
}
|
757 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
758 |
|
759 |
if( IS_WP27 ) {
|
760 |
add_action('wp_dashboard_setup','wpsc_dashboard_4months_widget_setup');
|
wpsc-admin/ajax-and-init.php
CHANGED
@@ -1329,7 +1329,7 @@ function wpsc_purchlog_edit_status($purchlog_id='', $purchlog_status='') {
|
|
1329 |
if(($purchlog_status > $log_data['processed']) && ($log_data['processed'] <= 2)) {
|
1330 |
transaction_results($log_data['sessionid'],false);
|
1331 |
}
|
1332 |
-
|
1333 |
}
|
1334 |
|
1335 |
if($_REQUEST['wpsc_admin_action'] == 'purchlog_edit_status') {
|
@@ -1340,15 +1340,14 @@ SELECT DISTINCT `products`.*, `category`.`category_id`,`order`.`order`, IF(ISNUL
|
|
1340 |
*/
|
1341 |
function wpsc_save_product_order() {
|
1342 |
global $wpdb;
|
1343 |
-
if(is_numeric($_POST['category_id'])
|
1344 |
$category_id = absint($_POST['category_id']);
|
1345 |
$products = $_POST['product'];
|
1346 |
$order=1;
|
1347 |
-
// echo '/*<pre>'.print_r($products,true).'</pre>*/';
|
1348 |
foreach($products as $product_id) {
|
1349 |
$product_id = absint($product_id);
|
1350 |
$wpdb->query("REPLACE INTO `".WPSC_TABLE_PRODUCT_ORDER."`(`category_id`, `product_id`, `order`) VALUES ('{$category_id}', '{$product_id}', '{$order}' )");
|
1351 |
-
|
1352 |
$order++;
|
1353 |
}
|
1354 |
$success = true;
|
1329 |
if(($purchlog_status > $log_data['processed']) && ($log_data['processed'] <= 2)) {
|
1330 |
transaction_results($log_data['sessionid'],false);
|
1331 |
}
|
1332 |
+
exit("1");
|
1333 |
}
|
1334 |
|
1335 |
if($_REQUEST['wpsc_admin_action'] == 'purchlog_edit_status') {
|
1340 |
*/
|
1341 |
function wpsc_save_product_order() {
|
1342 |
global $wpdb;
|
1343 |
+
if(is_numeric($_POST['category_id'])) {
|
1344 |
$category_id = absint($_POST['category_id']);
|
1345 |
$products = $_POST['product'];
|
1346 |
$order=1;
|
|
|
1347 |
foreach($products as $product_id) {
|
1348 |
$product_id = absint($product_id);
|
1349 |
$wpdb->query("REPLACE INTO `".WPSC_TABLE_PRODUCT_ORDER."`(`category_id`, `product_id`, `order`) VALUES ('{$category_id}', '{$product_id}', '{$order}' )");
|
1350 |
+
//echo "/* REPLACE INTO `".WPSC_TABLE_PRODUCT_ORDER."`(`category_id`, `product_id`, `order`) VALUES ('{$category_id}', '{$product_id}', '$order' ) */\n\r";
|
1351 |
$order++;
|
1352 |
}
|
1353 |
$success = true;
|
wpsc-admin/display-items.page.php
CHANGED
@@ -196,7 +196,6 @@ function wpsc_admin_products_list($category_id = 0) {
|
|
196 |
$is_sortable = true;
|
197 |
} else {
|
198 |
$itempp = 10;
|
199 |
-
|
200 |
if ($_GET['pageno']!='all') {
|
201 |
if($_GET['pageno'] > 0) {
|
202 |
$page = absint($_GET['pageno']);
|
@@ -205,19 +204,11 @@ function wpsc_admin_products_list($category_id = 0) {
|
|
205 |
}
|
206 |
$start = (int)($page * $itempp) - $itempp;
|
207 |
$sql = "SELECT DISTINCT * FROM `".WPSC_TABLE_PRODUCT_LIST."` AS `products` WHERE `products`.`active`='1' $search_sql ORDER BY `products`.`date_added` DESC LIMIT $start,$itempp";
|
208 |
-
if(get_option('wpsc_sort_by') == 'dragndrop'){
|
209 |
-
$sql = "SELECT DISTINCT * FROM `".WPSC_TABLE_PRODUCT_LIST."` AS `products` LEFT JOIN `".WPSC_TABLE_PRODUCT_ORDER."` AS `order` ON `products`.`id`= `order`.`product_id` WHERE `products`.`active`='1' AND `order`.`category_id`='0' $search_sql ORDER BY `order`.`order`";
|
210 |
-
}
|
211 |
-
|
212 |
} else {
|
213 |
-
|
214 |
-
|
215 |
}
|
216 |
-
|
217 |
}
|
218 |
-
// exit($sql);
|
219 |
$product_list = $wpdb->get_results($sql,ARRAY_A);
|
220 |
-
//exit('<pre>'.print_r($product_list, true).'</pre>');
|
221 |
$num_products = $wpdb->get_var("SELECT COUNT(DISTINCT `products`.`id`) FROM `".WPSC_TABLE_PRODUCT_LIST."` AS `products` WHERE `products`.`active`='1' $search_sql");
|
222 |
|
223 |
if (isset($itempp)) {
|
@@ -244,13 +235,12 @@ function wpsc_admin_products_list($category_id = 0) {
|
|
244 |
|
245 |
|
246 |
|
247 |
-
|
248 |
<div class="tablenav-pages">
|
249 |
<?php
|
250 |
echo $page_links;
|
251 |
?>
|
252 |
</div>
|
253 |
-
<?php } ?>
|
254 |
|
255 |
<div class="alignleft actions">
|
256 |
<form action="admin.php" method="get">
|
@@ -320,17 +310,12 @@ function wpsc_admin_products_list($category_id = 0) {
|
|
320 |
$product_name = htmlentities(stripslashes($product['name']), ENT_QUOTES, 'UTF-8');
|
321 |
}
|
322 |
|
323 |
-
|
324 |
$category_html = '';
|
325 |
-
if(get_option('wpsc_sort_by') != 'dragndrop'){
|
326 |
$category_list = $wpdb->get_results("SELECT `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`id`,`".WPSC_TABLE_PRODUCT_CATEGORIES."`.`name` FROM `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."` , `".WPSC_TABLE_PRODUCT_CATEGORIES."` WHERE `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`product_id` IN ('".$product['id']."') AND `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`category_id` = `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`id` AND `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`active` IN('1')",ARRAY_A);
|
327 |
-
}else{
|
328 |
-
$category_list = $wpdb->get_results("SELECT `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`id`,`".WPSC_TABLE_PRODUCT_CATEGORIES."`.`name` FROM `".WPSC_TABLE_PRODUCT_CATEGORIES."` LEFT JOIN `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."` ON `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`category_id`= `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`id` WHERE `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`product_id` IN ('".$product['product_id']."') AND `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`active` IN('1')",ARRAY_A);
|
329 |
-
}
|
330 |
$i = 0;
|
331 |
foreach((array)$category_list as $category_row) {
|
332 |
if($i > 0) {
|
333 |
-
|
334 |
$category_html .= "<br />";
|
335 |
}
|
336 |
|
@@ -339,11 +324,7 @@ function wpsc_admin_products_list($category_id = 0) {
|
|
339 |
$i++;
|
340 |
}
|
341 |
|
342 |
-
|
343 |
-
$product['id'] = $product['product_id'];
|
344 |
-
}
|
345 |
-
|
346 |
-
|
347 |
?>
|
348 |
<tr class="product-edit <?php echo ( wpsc_publish_status($product['id']) ) ? ' wpsc_published' : ' wpsc_not_published'; ?>" id="product-<?php echo $product['id']?>" >
|
349 |
<th class="check-column" scope="row">
|
@@ -392,7 +373,7 @@ function wpsc_admin_products_list($category_id = 0) {
|
|
392 |
</span>
|
393 |
|
|
394 |
<span class="delete">
|
395 |
-
<a class='submitdelete
|
396 |
title='<?php echo attribute_escape(__('Delete this product', 'wpsc')); ?>'
|
397 |
href='<?php echo wp_nonce_url("admin.php?wpsc_admin_action=delete_product&product={$product['id']}", 'delete_product_' . $product['id']); ?>'
|
398 |
onclick="if ( confirm(' <?php echo js_escape(sprintf( __("You are about to delete this product '%s'\n 'Cancel' to stop, 'OK' to delete."), $product['name'] )) ?>') ) { return true;}return false;"
|
196 |
$is_sortable = true;
|
197 |
} else {
|
198 |
$itempp = 10;
|
|
|
199 |
if ($_GET['pageno']!='all') {
|
200 |
if($_GET['pageno'] > 0) {
|
201 |
$page = absint($_GET['pageno']);
|
204 |
}
|
205 |
$start = (int)($page * $itempp) - $itempp;
|
206 |
$sql = "SELECT DISTINCT * FROM `".WPSC_TABLE_PRODUCT_LIST."` AS `products` WHERE `products`.`active`='1' $search_sql ORDER BY `products`.`date_added` DESC LIMIT $start,$itempp";
|
|
|
|
|
|
|
|
|
207 |
} else {
|
208 |
+
$sql = "SELECT DISTINCT * FROM `".WPSC_TABLE_PRODUCT_LIST."` AS `products` WHERE `products`.`active`='1' $search_sql ORDER BY `products`.`date_added`";
|
|
|
209 |
}
|
|
|
210 |
}
|
|
|
211 |
$product_list = $wpdb->get_results($sql,ARRAY_A);
|
|
|
212 |
$num_products = $wpdb->get_var("SELECT COUNT(DISTINCT `products`.`id`) FROM `".WPSC_TABLE_PRODUCT_LIST."` AS `products` WHERE `products`.`active`='1' $search_sql");
|
213 |
|
214 |
if (isset($itempp)) {
|
235 |
|
236 |
|
237 |
|
238 |
+
|
239 |
<div class="tablenav-pages">
|
240 |
<?php
|
241 |
echo $page_links;
|
242 |
?>
|
243 |
</div>
|
|
|
244 |
|
245 |
<div class="alignleft actions">
|
246 |
<form action="admin.php" method="get">
|
310 |
$product_name = htmlentities(stripslashes($product['name']), ENT_QUOTES, 'UTF-8');
|
311 |
}
|
312 |
|
313 |
+
|
314 |
$category_html = '';
|
|
|
315 |
$category_list = $wpdb->get_results("SELECT `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`id`,`".WPSC_TABLE_PRODUCT_CATEGORIES."`.`name` FROM `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."` , `".WPSC_TABLE_PRODUCT_CATEGORIES."` WHERE `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`product_id` IN ('".$product['id']."') AND `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`category_id` = `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`id` AND `".WPSC_TABLE_PRODUCT_CATEGORIES."`.`active` IN('1')",ARRAY_A);
|
|
|
|
|
|
|
316 |
$i = 0;
|
317 |
foreach((array)$category_list as $category_row) {
|
318 |
if($i > 0) {
|
|
|
319 |
$category_html .= "<br />";
|
320 |
}
|
321 |
|
324 |
$i++;
|
325 |
}
|
326 |
|
327 |
+
|
|
|
|
|
|
|
|
|
328 |
?>
|
329 |
<tr class="product-edit <?php echo ( wpsc_publish_status($product['id']) ) ? ' wpsc_published' : ' wpsc_not_published'; ?>" id="product-<?php echo $product['id']?>" >
|
330 |
<th class="check-column" scope="row">
|
373 |
</span>
|
374 |
|
|
375 |
<span class="delete">
|
376 |
+
<a class='submitdelete'
|
377 |
title='<?php echo attribute_escape(__('Delete this product', 'wpsc')); ?>'
|
378 |
href='<?php echo wp_nonce_url("admin.php?wpsc_admin_action=delete_product&product={$product['id']}", 'delete_product_' . $product['id']); ?>'
|
379 |
onclick="if ( confirm(' <?php echo js_escape(sprintf( __("You are about to delete this product '%s'\n 'Cancel' to stop, 'OK' to delete."), $product['name'] )) ?>') ) { return true;}return false;"
|
wpsc-admin/display-sales-logs.php
CHANGED
@@ -50,14 +50,7 @@ if(!isset($purchlogs)){
|
|
50 |
///// start of update message section //////
|
51 |
|
52 |
//$fixpage = get_option('siteurl').'/wp-admin/admin.php?page='.WPSC_FOLDER.'/wpsc-admin/purchlogs_upgrade.php';
|
53 |
-
|
54 |
-
|
55 |
-
// we put the closed postboxes array into the product data to propagate it to each form without having it global.
|
56 |
-
$dashboard_data['closed_postboxes'] = (array)get_usermeta( $current_user->ID, 'closedpostboxes_store_page_wpscsalelogs');
|
57 |
-
// exit('<pre>'.print_r($dashboard_data,true).'</pre>');
|
58 |
-
// $dashboard_data['hidden_postboxes'] = (array)get_usermeta( $current_user->ID, 'metaboxhidden_store_page_wpsc-edit-products');
|
59 |
-
|
60 |
-
|
61 |
$fixpage = get_option('siteurl').'/wp-admin/admin.php?page=wpsc-sales-logs&subpage=upgrade-purchase-logs';
|
62 |
if (isset($_GET['skipped']) || isset($_GET['updated']) || isset($_GET['deleted']) || isset($_GET['locked']) ) { ?>
|
63 |
<div id="message" class="updated fade"><p>
|
@@ -88,16 +81,11 @@ if(!isset($purchlogs)){
|
|
88 |
<div class='error' style='padding:8px;line-spacing:8px;'><span ><?php _e('When upgrading the Wp-E-Commerce Plugin from 3.6.* to 3.7 it is required that you associate your checkout form fields with the new Purchase Logs system. To do so please '); ?> <a href='<?php echo $fixpage; ?>'>Click Here</a></span></div>
|
89 |
<?php }
|
90 |
///// end of update message section //////?>
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
<div id='dashboard-widgets' style='min-width: 825px;'>
|
95 |
<!--
|
96 |
<div class='inner-sidebar'>
|
97 |
<div class='meta-box-sortables'>
|
98 |
<?php
|
99 |
-
|
100 |
-
|
101 |
//if(IS_WP27){
|
102 |
// display_ecomm_rss_feed();
|
103 |
//}
|
@@ -108,30 +96,12 @@ if(!isset($purchlogs)){
|
|
108 |
<?php /* end of sidebar start of main column */ ?>
|
109 |
<div id='post-body' class='has-sidebar metabox-holder' style='width:95%;'>
|
110 |
<div id='dashboard-widgets-main-content-wpsc' class='has-sidebar-content'>
|
111 |
-
<div class='postbox <?php echo ((array_search('wpsc_getshopped_news', $dashboard_data['closed_postboxes']) !== false) ? 'closed' : ''); ?>' id="wpsc_getshopped_news">
|
112 |
-
<h3 class='hndle'>
|
113 |
-
<span><?php _e('GetShopped News', 'wpsc'); ?></span>
|
114 |
-
<br class='clear'/>
|
115 |
-
</h3>
|
116 |
-
|
117 |
-
<div class='inside'>
|
118 |
-
<?php
|
119 |
-
// exit('Data:<pre>'.print_r($dashboard_data,true).'</pre>');
|
120 |
-
$rss = fetch_feed('http://getshopped.org/category/wp-e-commerce-plugin/');
|
121 |
-
$args = array('show_author' => 1, 'show_date' => 1, 'show_summary' => 1, 'items'=>3 );
|
122 |
-
wp_widget_rss_output($rss, $args);
|
123 |
-
?>
|
124 |
-
</div>
|
125 |
-
</div>
|
126 |
-
<?php
|
127 |
-
// add_meta_box("wpsc_getshopped_news", __('GetShopped News', 'wpsc'), "wpsc_getshopped_news_meta_box", "wpsc");
|
128 |
-
// do_meta_boxes('wpsc','advanced',null);
|
129 |
|
130 |
-
|
131 |
if(function_exists('wpsc_right_now')) {
|
132 |
-
echo wpsc_right_now(
|
133 |
}
|
134 |
-
|
135 |
?>
|
136 |
</div><br />
|
137 |
<div id='wpsc_purchlog_searchbox'>
|
50 |
///// start of update message section //////
|
51 |
|
52 |
//$fixpage = get_option('siteurl').'/wp-admin/admin.php?page='.WPSC_FOLDER.'/wpsc-admin/purchlogs_upgrade.php';
|
53 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
54 |
$fixpage = get_option('siteurl').'/wp-admin/admin.php?page=wpsc-sales-logs&subpage=upgrade-purchase-logs';
|
55 |
if (isset($_GET['skipped']) || isset($_GET['updated']) || isset($_GET['deleted']) || isset($_GET['locked']) ) { ?>
|
56 |
<div id="message" class="updated fade"><p>
|
81 |
<div class='error' style='padding:8px;line-spacing:8px;'><span ><?php _e('When upgrading the Wp-E-Commerce Plugin from 3.6.* to 3.7 it is required that you associate your checkout form fields with the new Purchase Logs system. To do so please '); ?> <a href='<?php echo $fixpage; ?>'>Click Here</a></span></div>
|
82 |
<?php }
|
83 |
///// end of update message section //////?>
|
|
|
|
|
|
|
84 |
<div id='dashboard-widgets' style='min-width: 825px;'>
|
85 |
<!--
|
86 |
<div class='inner-sidebar'>
|
87 |
<div class='meta-box-sortables'>
|
88 |
<?php
|
|
|
|
|
89 |
//if(IS_WP27){
|
90 |
// display_ecomm_rss_feed();
|
91 |
//}
|
96 |
<?php /* end of sidebar start of main column */ ?>
|
97 |
<div id='post-body' class='has-sidebar metabox-holder' style='width:95%;'>
|
98 |
<div id='dashboard-widgets-main-content-wpsc' class='has-sidebar-content'>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
99 |
|
100 |
+
<?php
|
101 |
if(function_exists('wpsc_right_now')) {
|
102 |
+
echo wpsc_right_now();
|
103 |
}
|
104 |
+
|
105 |
?>
|
106 |
</div><br />
|
107 |
<div id='wpsc_purchlog_searchbox'>
|
wpsc-admin/includes/display-items-functions.php
CHANGED
@@ -348,7 +348,7 @@ if(0 == $product_data['special_price']){
|
|
348 |
|
349 |
|
350 |
<input class='button-primary' style='float:left;' type='submit' name='submit' value='<?php if($product_data['id'] > 0) { _e('Update Product', 'wpsc'); } else { _e('Add New Product', 'wpsc'); } ?>' />
|
351 |
-
<a class='submitdelete
|
352 |
<?php
|
353 |
}
|
354 |
|
@@ -1204,7 +1204,7 @@ function wpsc_main_product_image_menu($product_id) {
|
|
1204 |
<ul>
|
1205 |
|
1206 |
<li>
|
1207 |
-
<input type='radio' name='gallery_resize' value='1' id='gallery_resize1' class='image_resize' onclick='image_resize_extra_forms(this)' /> <label for='gallery_resize1'><?php echo __('use default size', 'wpsc');
|
1208 |
</label>
|
1209 |
|
1210 |
</li>
|
@@ -1231,12 +1231,9 @@ function wpsc_main_product_image_menu($product_id) {
|
|
1231 |
<a href='<?php echo htmlentities("admin.php?wpsc_admin_action=crop_image&imagename=".$main_image['image']."&imgheight=".$image_data[1]."&imgwidth=".$image_data[0]."&width=630&height=500&product_id=".$product_id); ?>' title='Crop Image' class='thickbox'>Crop This Image Using jCrop</a>
|
1232 |
|
1233 |
</li>
|
1234 |
-
|
1235 |
<li>
|
1236 |
-
<
|
1237 |
-
<a href='#' class='delete_primary_image delete_button'>Delete</a>
|
1238 |
</li>
|
1239 |
-
|
1240 |
|
1241 |
</ul>
|
1242 |
</div>
|
348 |
|
349 |
|
350 |
<input class='button-primary' style='float:left;' type='submit' name='submit' value='<?php if($product_data['id'] > 0) { _e('Update Product', 'wpsc'); } else { _e('Add New Product', 'wpsc'); } ?>' />
|
351 |
+
<a class='submitdelete' title='<?php echo attribute_escape(__('Delete this product')); ?>' href='<?php echo wp_nonce_url("page.php?wpsc_admin_action=delete_product&product={$product_data['id']}", 'delete_product_' . $product_data['id']); ?>' onclick="if ( confirm(' <?php echo js_escape(sprintf( __("You are about to delete this product '%s'\n 'Cancel' to stop, 'OK' to delete."), $product_data['name'] )) ?>') ) { return true;}return false;"><?php _e('Delete') ?></a>
|
352 |
<?php
|
353 |
}
|
354 |
|
1204 |
<ul>
|
1205 |
|
1206 |
<li>
|
1207 |
+
<input type='radio' name='gallery_resize' value='1' id='gallery_resize1' class='image_resize' onclick='image_resize_extra_forms(this)' /> <label for='gallery_resize1'><?php echo __('use default size', 'wpsc'); ?>(<a href='<?php echo $presentation_link; ?>' title='<?php echo __('This is set on the Settings Page', 'wpsc'); ?>'><?php echo get_option('product_image_height'); ?>×<?php echo get_option('product_image_width'); ?>px</a>)
|
1208 |
</label>
|
1209 |
|
1210 |
</li>
|
1231 |
<a href='<?php echo htmlentities("admin.php?wpsc_admin_action=crop_image&imagename=".$main_image['image']."&imgheight=".$image_data[1]."&imgwidth=".$image_data[0]."&width=630&height=500&product_id=".$product_id); ?>' title='Crop Image' class='thickbox'>Crop This Image Using jCrop</a>
|
1232 |
|
1233 |
</li>
|
|
|
1234 |
<li>
|
1235 |
+
<a href='#' class='delete_primary_image delete_button'>Delete this Image</a>
|
|
|
1236 |
</li>
|
|
|
1237 |
|
1238 |
</ul>
|
1239 |
</div>
|
wpsc-admin/includes/settings-pages/admin.php
CHANGED
@@ -76,9 +76,7 @@ global $wpdb;
|
|
76 |
<?php echo __('Purchase Log Email', 'wpsc');?>:
|
77 |
</th>
|
78 |
<td>
|
79 |
-
<input class='text' name='wpsc_options[purch_log_email]' type='text' size='40' value='<?php echo get_option('purch_log_email'); ?>'
|
80 |
-
<?php _e('i.e. this is the address where your purchase reports are sent.','wpsc'); ?>
|
81 |
-
|
82 |
</td>
|
83 |
</tr>
|
84 |
<tr>
|
@@ -87,7 +85,6 @@ global $wpdb;
|
|
87 |
</th>
|
88 |
<td>
|
89 |
<input class='text' name='wpsc_options[return_email]' type='text' size='40' value='<?php echo get_option('return_email'); ?>' />
|
90 |
-
<?php _e('i.e. this is the reply address contained in the purchase receipt sent to the buyer.','wpsc'); ?>
|
91 |
</td>
|
92 |
</tr>
|
93 |
|
@@ -97,8 +94,6 @@ global $wpdb;
|
|
97 |
</th>
|
98 |
<td>
|
99 |
<input class='text' name='wpsc_options[return_name]' type='text' size='40' value='<?php echo get_option('return_name'); ?>' />
|
100 |
-
<?php _e('i.e. this is the "from name" buyers will see in their purchase receipt. ','wpsc'); ?>
|
101 |
-
|
102 |
</td>
|
103 |
</tr>
|
104 |
|
76 |
<?php echo __('Purchase Log Email', 'wpsc');?>:
|
77 |
</th>
|
78 |
<td>
|
79 |
+
<input class='text' name='wpsc_options[purch_log_email]' type='text' size='40' value='<?php echo get_option('purch_log_email'); ?>' />
|
|
|
|
|
80 |
</td>
|
81 |
</tr>
|
82 |
<tr>
|
85 |
</th>
|
86 |
<td>
|
87 |
<input class='text' name='wpsc_options[return_email]' type='text' size='40' value='<?php echo get_option('return_email'); ?>' />
|
|
|
88 |
</td>
|
89 |
</tr>
|
90 |
|
94 |
</th>
|
95 |
<td>
|
96 |
<input class='text' name='wpsc_options[return_name]' type='text' size='40' value='<?php echo get_option('return_name'); ?>' />
|
|
|
|
|
97 |
</td>
|
98 |
</tr>
|
99 |
|
wpsc-admin/includes/settings-pages/general.php
CHANGED
@@ -176,30 +176,6 @@ function wpsc_options_general(){
|
|
176 |
<label for='csl4'><span id='cslchar4'><?php echo $currency_sign; ?></span> 100</label>
|
177 |
</td>
|
178 |
</tr>
|
179 |
-
<tr>
|
180 |
-
<?php
|
181 |
-
$decimals = get_option('wpsc_hide_decimals');
|
182 |
-
switch($decimals){
|
183 |
-
case '1':
|
184 |
-
$decimal1 = 'checked="checked"';
|
185 |
-
break;
|
186 |
-
|
187 |
-
case '0':
|
188 |
-
default:
|
189 |
-
$decimal2 = 'checked="checked"';
|
190 |
-
break;
|
191 |
-
}
|
192 |
-
|
193 |
-
?>
|
194 |
-
<th scope="row"><?php _e('Hide Decimals on Products Pages'); ?></th>
|
195 |
-
<td>
|
196 |
-
<input type='radio' value='1' name='wpsc_options[wpsc_hide_decimals]' id='hide_decimals1' <?php echo $decimal1; ?> />
|
197 |
-
<label for='hide_decimals1'><?php _e('Yes'); ?></label>
|
198 |
-
|
199 |
-
<input type='radio' value='0' name='wpsc_options[wpsc_hide_decimals]' id='hide_decimals2' <?php echo $decimal2; ?> />
|
200 |
-
<label for='hide_decimals2'><?php _e('No'); ?></label>
|
201 |
-
</td>
|
202 |
-
</tr>
|
203 |
</table>
|
204 |
<div class="submit">
|
205 |
<input type='hidden' name='wpsc_admin_action' value='submit_options' />
|
176 |
<label for='csl4'><span id='cslchar4'><?php echo $currency_sign; ?></span> 100</label>
|
177 |
</td>
|
178 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
179 |
</table>
|
180 |
<div class="submit">
|
181 |
<input type='hidden' name='wpsc_admin_action' value='submit_options' />
|
wpsc-admin/includes/settings-pages/presentation.php
CHANGED
@@ -18,22 +18,22 @@ function options_categorylist() {
|
|
18 |
} else {
|
19 |
$selected = '';
|
20 |
}
|
21 |
-
$categorylist .= "<option value='list' ".$selected." >".__('Show
|
22 |
|
23 |
if(get_option('wpsc_default_category') == 'all+list') {
|
24 |
$selected = "selected='selected'";
|
25 |
} else {
|
26 |
$selected = '';
|
27 |
}
|
28 |
-
$categorylist .= "<option value='all+list' ".$selected." >".__('Show
|
29 |
-
|
30 |
foreach($group_data as $group) {
|
31 |
$cat_sql = "SELECT * FROM `".WPSC_TABLE_PRODUCT_CATEGORIES."` WHERE `group_id` IN ({$group['id']}) AND `active`='1'";
|
32 |
$category_data = $wpdb->get_results($cat_sql,ARRAY_A);
|
33 |
if($category_data != null) {
|
34 |
|
35 |
|
36 |
-
$categorylist .= "<optgroup label='{$group['name']}'>"
|
37 |
foreach((array)$category_data as $category) {
|
38 |
if(get_option('wpsc_default_category') == $category['id']) {
|
39 |
$selected = "selected='selected'";
|
@@ -285,7 +285,7 @@ global $wpdb;
|
|
285 |
<h3 class="form_group"><?php echo __('Product Page Settings', 'wpsc');?></h3>
|
286 |
<table class='wpsc_options form-table'>
|
287 |
<tr>
|
288 |
-
<th scope="row"><?php echo __('
|
289 |
<td>
|
290 |
<?php
|
291 |
$display_pnp = get_option('product_view');
|
@@ -413,7 +413,7 @@ global $wpdb;
|
|
413 |
?>
|
414 |
|
415 |
<tr>
|
416 |
-
<th scope="row"><?php echo __('Theme', 'wpsc');?>:</th>
|
417 |
<td>
|
418 |
<?php
|
419 |
echo wpsc_list_product_themes();
|
@@ -422,7 +422,7 @@ global $wpdb;
|
|
422 |
</tr>
|
423 |
|
424 |
<tr>
|
425 |
-
<th scope="row"><?php echo __('
|
426 |
<td>
|
427 |
<?php echo options_categorylist(); ?>
|
428 |
</td>
|
@@ -438,10 +438,6 @@ global $wpdb;
|
|
438 |
$wpsc_sort_by2 = "selected ='selected'";
|
439 |
break;
|
440 |
|
441 |
-
case 'dragndrop':
|
442 |
-
$wpsc_sort_by4 = "selected='selected'";
|
443 |
-
break;
|
444 |
-
|
445 |
case 'id':
|
446 |
default:
|
447 |
$wpsc_sort_by3 = "selected ='selected'";
|
@@ -450,18 +446,17 @@ global $wpdb;
|
|
450 |
?>
|
451 |
<tr>
|
452 |
<th scope="row">
|
453 |
-
<?php echo __('Sort
|
454 |
</th>
|
455 |
<td>
|
456 |
<select name='wpsc_options[wpsc_sort_by]'>
|
457 |
<option <?php echo $wpsc_sort_by1; ?> value='name'><?php echo __('Name', 'wpsc');?></option>
|
458 |
<option <?php echo $wpsc_sort_by2; ?> value='price'><?php echo __('Price', 'wpsc');?></option>
|
459 |
-
<option <?php echo $wpsc_sort_by4; ?> value='dragndrop'><?php echo __('Drag & Drop', 'wpsc');?></option>
|
460 |
<option <?php echo $wpsc_sort_by3; ?> value='id'><?php echo __('Time Uploaded', 'wpsc');?></option>
|
461 |
-
</select
|
462 |
-
<?php _e('If you have used the drag-drop interface on the edit-products page to order your products then you must use the Drag & Drop option.','wpsc'); ?>
|
463 |
</td>
|
464 |
</tr>
|
|
|
465 |
<tr>
|
466 |
<th scope="row"><?php echo __('Show Breadcrumbs', 'wpsc');?>:</th>
|
467 |
<td>
|
18 |
} else {
|
19 |
$selected = '';
|
20 |
}
|
21 |
+
$categorylist .= "<option value='list' ".$selected." >".__('Show list of product groups', 'wpsc')."</option>";
|
22 |
|
23 |
if(get_option('wpsc_default_category') == 'all+list') {
|
24 |
$selected = "selected='selected'";
|
25 |
} else {
|
26 |
$selected = '';
|
27 |
}
|
28 |
+
$categorylist .= "<option value='all+list' ".$selected." >".__('Show all products + list', 'wpsc')."</option>";
|
29 |
+
|
30 |
foreach($group_data as $group) {
|
31 |
$cat_sql = "SELECT * FROM `".WPSC_TABLE_PRODUCT_CATEGORIES."` WHERE `group_id` IN ({$group['id']}) AND `active`='1'";
|
32 |
$category_data = $wpdb->get_results($cat_sql,ARRAY_A);
|
33 |
if($category_data != null) {
|
34 |
|
35 |
|
36 |
+
$categorylist .= "<optgroup label='{$group['name']}'>";;
|
37 |
foreach((array)$category_data as $category) {
|
38 |
if(get_option('wpsc_default_category') == $category['id']) {
|
39 |
$selected = "selected='selected'";
|
285 |
<h3 class="form_group"><?php echo __('Product Page Settings', 'wpsc');?></h3>
|
286 |
<table class='wpsc_options form-table'>
|
287 |
<tr>
|
288 |
+
<th scope="row"><?php echo __('Product Display', 'wpsc');?>:</th>
|
289 |
<td>
|
290 |
<?php
|
291 |
$display_pnp = get_option('product_view');
|
413 |
?>
|
414 |
|
415 |
<tr>
|
416 |
+
<th scope="row"><?php echo __('Select Theme', 'wpsc');?>:</th>
|
417 |
<td>
|
418 |
<?php
|
419 |
echo wpsc_list_product_themes();
|
422 |
</tr>
|
423 |
|
424 |
<tr>
|
425 |
+
<th scope="row"><?php echo __('Select what product group you want to display on the products page', 'wpsc'); ?>:</th>
|
426 |
<td>
|
427 |
<?php echo options_categorylist(); ?>
|
428 |
</td>
|
438 |
$wpsc_sort_by2 = "selected ='selected'";
|
439 |
break;
|
440 |
|
|
|
|
|
|
|
|
|
441 |
case 'id':
|
442 |
default:
|
443 |
$wpsc_sort_by3 = "selected ='selected'";
|
446 |
?>
|
447 |
<tr>
|
448 |
<th scope="row">
|
449 |
+
<?php echo __('Sort Product By', 'wpsc');?>:
|
450 |
</th>
|
451 |
<td>
|
452 |
<select name='wpsc_options[wpsc_sort_by]'>
|
453 |
<option <?php echo $wpsc_sort_by1; ?> value='name'><?php echo __('Name', 'wpsc');?></option>
|
454 |
<option <?php echo $wpsc_sort_by2; ?> value='price'><?php echo __('Price', 'wpsc');?></option>
|
|
|
455 |
<option <?php echo $wpsc_sort_by3; ?> value='id'><?php echo __('Time Uploaded', 'wpsc');?></option>
|
456 |
+
</select>
|
|
|
457 |
</td>
|
458 |
</tr>
|
459 |
+
|
460 |
<tr>
|
461 |
<th scope="row"><?php echo __('Show Breadcrumbs', 'wpsc');?>:</th>
|
462 |
<td>
|
wpsc-admin/includes/settings-pages/shipping.php
CHANGED
@@ -193,7 +193,6 @@ function selectgateway() {
|
|
193 |
|
194 |
<p>
|
195 |
<?php echo __('To enable shipping in WP e-Commerce you must select which shipping methods you want to enable on your site', 'wpsc'); ?>
|
196 |
-
<?php if (!phpMinV('5')){ echo __('<br /><strong>UPS has been deactivated because you are running PHP4, please upgrade to PHP5 to enable UPS.</strong>','wpsc'); } ?>
|
197 |
</p>
|
198 |
<br />
|
199 |
<p>
|
193 |
|
194 |
<p>
|
195 |
<?php echo __('To enable shipping in WP e-Commerce you must select which shipping methods you want to enable on your site', 'wpsc'); ?>
|
|
|
196 |
</p>
|
197 |
<br />
|
198 |
<p>
|
wpsc-admin/js/admin.js
CHANGED
@@ -195,7 +195,6 @@ jQuery(document).ready( function () {
|
|
195 |
axis: 'y',
|
196 |
containment: 'table#wpsc_checkout_list',
|
197 |
placeholder: 'checkout-placeholder',
|
198 |
-
handle: '.drag',
|
199 |
|
200 |
});
|
201 |
jQuery(this).bind('sortupdate', function(event, ui) {
|
@@ -434,19 +433,10 @@ jQuery(document).ready( function () {
|
|
434 |
wpsc_save_postboxes_state('store_page_wpsc-edit-products', '#poststuff');
|
435 |
});
|
436 |
});
|
437 |
-
jQuery('#dashboard-widgets .postbox h3').livequery(function(){
|
438 |
-
jQuery(this).click( function() {
|
439 |
-
jQuery(jQuery(this).parent('div.postbox')).toggleClass('closed');
|
440 |
-
if(jQuery(jQuery(this).parent('div.postbox')).hasClass('closed')) {
|
441 |
-
jQuery('a.togbox',this).html('+');
|
442 |
-
} else {
|
443 |
-
jQuery('a.togbox',this).html('–');
|
444 |
-
}
|
445 |
-
wpsc_save_postboxes_state('store_page_wpsc-sale-logs', '#dashboard-widgets-main-content-wpsc');
|
446 |
-
});
|
447 |
-
});
|
448 |
|
449 |
|
|
|
|
|
450 |
jQuery('a.add_new_form_set').livequery(function(){
|
451 |
jQuery(this).click( function() {
|
452 |
jQuery(".add_new_form_set_forms").toggle();
|
@@ -475,7 +465,8 @@ jQuery(document).ready( function () {
|
|
475 |
postboxes.save_state('store_page_wpsc-edit-products');
|
476 |
});
|
477 |
});
|
478 |
-
|
|
|
479 |
// postbox sorting
|
480 |
jQuery('.meta-box-sortables').livequery(function(){
|
481 |
jQuery(this).sortable({
|
@@ -539,7 +530,7 @@ jQuery(document).ready( function () {
|
|
539 |
});
|
540 |
});
|
541 |
|
542 |
-
jQuery('.closeimagesettings').livequery(function(){
|
543 |
jQuery(this).click( function() {
|
544 |
jQuery('.image_settings_box').hide();
|
545 |
});
|
@@ -857,9 +848,9 @@ function hideOptionElement(id, option) {
|
|
857 |
|
858 |
|
859 |
function wpsc_save_postboxes_state(page, container) {
|
860 |
-
//
|
861 |
var closed = jQuery(container+' .postbox').filter('.closed').map(function() { return this.id; }).get().join(',');
|
862 |
-
jQuery.post(
|
863 |
action: 'closed-postboxes',
|
864 |
closed: closed,
|
865 |
closedpostboxesnonce: jQuery('#closedpostboxesnonce').val(),
|
195 |
axis: 'y',
|
196 |
containment: 'table#wpsc_checkout_list',
|
197 |
placeholder: 'checkout-placeholder',
|
|
|
198 |
|
199 |
});
|
200 |
jQuery(this).bind('sortupdate', function(event, ui) {
|
433 |
wpsc_save_postboxes_state('store_page_wpsc-edit-products', '#poststuff');
|
434 |
});
|
435 |
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
436 |
|
437 |
|
438 |
+
|
439 |
+
|
440 |
jQuery('a.add_new_form_set').livequery(function(){
|
441 |
jQuery(this).click( function() {
|
442 |
jQuery(".add_new_form_set_forms").toggle();
|
465 |
postboxes.save_state('store_page_wpsc-edit-products');
|
466 |
});
|
467 |
});
|
468 |
+
|
469 |
+
|
470 |
// postbox sorting
|
471 |
jQuery('.meta-box-sortables').livequery(function(){
|
472 |
jQuery(this).sortable({
|
530 |
});
|
531 |
});
|
532 |
|
533 |
+
jQuery('a.closeimagesettings').livequery(function(){
|
534 |
jQuery(this).click( function() {
|
535 |
jQuery('.image_settings_box').hide();
|
536 |
});
|
848 |
|
849 |
|
850 |
function wpsc_save_postboxes_state(page, container) {
|
851 |
+
//console.log(container);
|
852 |
var closed = jQuery(container+' .postbox').filter('.closed').map(function() { return this.id; }).get().join(',');
|
853 |
+
jQuery.post(postboxL10n.requestFile, {
|
854 |
action: 'closed-postboxes',
|
855 |
closed: closed,
|
856 |
closedpostboxesnonce: jQuery('#closedpostboxesnonce').val(),
|
wpsc-includes/ajax.functions.php
CHANGED
@@ -213,7 +213,6 @@ function wpsc_empty_cart() {
|
|
213 |
});
|
214 |
";
|
215 |
}
|
216 |
-
|
217 |
exit();
|
218 |
}
|
219 |
|
@@ -364,30 +363,24 @@ function wpsc_update_shipping_price() {
|
|
364 |
global $wpdb, $wpsc_cart;
|
365 |
$quote_shipping_method = $_POST['key1'];
|
366 |
$quote_shipping_option = $_POST['key'];
|
367 |
-
|
368 |
-
//If no $_POST key variable means it is activated through shipping same as billing
|
369 |
if($quote_shipping_method == '' && $quote_shipping_option == ''){
|
370 |
$quote_shipping_method = $wpsc_cart->selected_shipping_method;
|
371 |
-
|
372 |
-
|
|
|
|
|
|
|
373 |
foreach($wpsc_cart->cart_items as $cart_item){
|
374 |
$product_ship = $cart_item->calculate_shipping($quote_shipping_method);
|
375 |
|
376 |
echo "jQuery('#shipping_".$i."').html('".htmlspecialchars(nzshpcrt_currency_display($product_ship, false,true))."');\n\r";
|
377 |
$i++;
|
378 |
}
|
379 |
-
|
380 |
-
|
381 |
-
echo "jQuery('.pricedisplay.checkout-shipping').html('".wpsc_cart_shipping()."');\n\r";
|
382 |
-
echo "jQuery('.pricedisplay.checkout-total').html('".wpsc_cart_total()."');\n\r";
|
383 |
-
exit();
|
384 |
-
}
|
385 |
-
|
386 |
-
//if(count($wpsc_cart->shipping_quotes) > 0 && $_POST['key1'] == '' && $_POST['key'] == ''){
|
387 |
while (wpsc_have_shipping_methods()) : wpsc_the_shipping_method();
|
388 |
if (!wpsc_have_shipping_quotes()) { continue; } // Don't display shipping method if it doesn't have at least one quote
|
389 |
-
|
390 |
-
$output .="<tr><td class='shipping_header' colspan='5'>".wpsc_shipping_method_name().__('- Choose a Shipping Rate', 'wpsc')."</td></tr>";
|
391 |
while (wpsc_have_shipping_quotes()) : wpsc_the_shipping_quote();
|
392 |
$output .="<tr class='shipping_quotes'>";
|
393 |
$output .="<td colspan='3'>";
|
@@ -408,15 +401,11 @@ function wpsc_update_shipping_price() {
|
|
408 |
endwhile;
|
409 |
endwhile;
|
410 |
$output = str_replace(Array("\n","\r") , Array("\\n","\\r"),addslashes($output));
|
411 |
-
echo "
|
412 |
-
echo "
|
413 |
-
echo "shipping.parent().append(\"".$output."\");\n\r";
|
414 |
-
echo "shipping.empty();";
|
415 |
// }
|
416 |
-
|
417 |
-
|
418 |
-
|
419 |
-
if(wpsc_cart_tax(false) > 0){
|
420 |
echo "jQuery(\"tr.total_tax\").show();\n\r";
|
421 |
echo "jQuery('#checkout_tax').html(\"<span class='pricedisplay'>".wpsc_cart_tax()."</span>\");\n\r";
|
422 |
}
|
@@ -522,16 +511,14 @@ function wpsc_update_location() {
|
|
522 |
}
|
523 |
|
524 |
//exit();
|
525 |
-
if($
|
526 |
exit();
|
527 |
}
|
528 |
}
|
529 |
|
530 |
// execute on POST and GET
|
531 |
-
|
532 |
if($_REQUEST['wpsc_ajax_actions'] == 'update_location') {
|
533 |
-
add_action('init', 'wpsc_update_location'
|
534 |
-
|
535 |
}
|
536 |
|
537 |
|
213 |
});
|
214 |
";
|
215 |
}
|
|
|
216 |
exit();
|
217 |
}
|
218 |
|
363 |
global $wpdb, $wpsc_cart;
|
364 |
$quote_shipping_method = $_POST['key1'];
|
365 |
$quote_shipping_option = $_POST['key'];
|
366 |
+
// exit('<pre>'.print_r($wpsc_cart, true).'</pre>');
|
|
|
367 |
if($quote_shipping_method == '' && $quote_shipping_option == ''){
|
368 |
$quote_shipping_method = $wpsc_cart->selected_shipping_method;
|
369 |
+
|
370 |
+
}
|
371 |
+
$wpsc_cart->update_shipping($quote_shipping_method, $quote_shipping_option);
|
372 |
+
if($_POST['key1'] == '' && $_POST['key'] == ''){
|
373 |
+
$i=0;
|
374 |
foreach($wpsc_cart->cart_items as $cart_item){
|
375 |
$product_ship = $cart_item->calculate_shipping($quote_shipping_method);
|
376 |
|
377 |
echo "jQuery('#shipping_".$i."').html('".htmlspecialchars(nzshpcrt_currency_display($product_ship, false,true))."');\n\r";
|
378 |
$i++;
|
379 |
}
|
380 |
+
}
|
381 |
+
// if(count($wpsc_cart->shipping_quotes) > 0 && $_POST['key1'] == '' && $_POST['key'] == ''){
|
|
|
|
|
|
|
|
|
|
|
|
|
382 |
while (wpsc_have_shipping_methods()) : wpsc_the_shipping_method();
|
383 |
if (!wpsc_have_shipping_quotes()) { continue; } // Don't display shipping method if it doesn't have at least one quote
|
|
|
|
|
384 |
while (wpsc_have_shipping_quotes()) : wpsc_the_shipping_quote();
|
385 |
$output .="<tr class='shipping_quotes'>";
|
386 |
$output .="<td colspan='3'>";
|
401 |
endwhile;
|
402 |
endwhile;
|
403 |
$output = str_replace(Array("\n","\r") , Array("\\n","\\r"),addslashes($output));
|
404 |
+
echo "jQuery('tr.shipping_quotes').remove();";
|
405 |
+
echo "jQuery('#wpsc_shopping_cart_container .productcart :first').append(\"".$output."\");\n\r";
|
|
|
|
|
406 |
// }
|
407 |
+
$tax = $wpsc_cart->calculate_total_tax();
|
408 |
+
if($tax >0){
|
|
|
|
|
409 |
echo "jQuery(\"tr.total_tax\").show();\n\r";
|
410 |
echo "jQuery('#checkout_tax').html(\"<span class='pricedisplay'>".wpsc_cart_tax()."</span>\");\n\r";
|
411 |
}
|
511 |
}
|
512 |
|
513 |
//exit();
|
514 |
+
if($_GET['ajax'] == 'true') {
|
515 |
exit();
|
516 |
}
|
517 |
}
|
518 |
|
519 |
// execute on POST and GET
|
|
|
520 |
if($_REQUEST['wpsc_ajax_actions'] == 'update_location') {
|
521 |
+
add_action('init', 'wpsc_update_location');
|
|
|
522 |
}
|
523 |
|
524 |
|
wpsc-includes/cart.class.php
CHANGED
@@ -481,9 +481,7 @@ function wpsc_have_morethanone_shipping_quote(){
|
|
481 |
$wpsc_cart->rewind_shipping_methods();
|
482 |
$wpsc_cart->update_shipping('flatrate', $name);
|
483 |
return false;
|
484 |
-
|
485 |
}
|
486 |
-
|
487 |
return true;
|
488 |
}
|
489 |
|
@@ -595,7 +593,7 @@ class wpsc_cart {
|
|
595 |
}
|
596 |
$this->update_location();
|
597 |
$this->get_tax_rate();
|
598 |
-
$this->unique_id = sha1(uniqid(rand(),true));
|
599 |
|
600 |
$this->get_shipping_method();
|
601 |
}
|
@@ -657,7 +655,7 @@ class wpsc_cart {
|
|
657 |
|
658 |
$this->shipping_methods = get_option('custom_shipping_options');
|
659 |
$this->shipping_method_count = count($this->shipping_methods);
|
660 |
-
|
661 |
if((get_option('do_not_use_shipping') != 1) && (count($this->shipping_methods) > 0) ) {
|
662 |
if(array_search($this->selected_shipping_method, (array)$this->shipping_methods) === false) {
|
663 |
//unset($this->selected_shipping_method);
|
@@ -670,7 +668,6 @@ class wpsc_cart {
|
|
670 |
$this->shipping_quotes = $wpsc_shipping_modules[$this->selected_shipping_method]->getQuote();
|
671 |
}
|
672 |
} else {
|
673 |
-
// exit('Here <pre>'.print_r($custom_shipping, true).'</pre>');
|
674 |
// otherwise select the first one with any quotes
|
675 |
foreach((array)$custom_shipping as $shipping_module) {
|
676 |
// if the shipping module does not require a weight, or requires one and the weight is larger than zero
|
@@ -685,7 +682,7 @@ class wpsc_cart {
|
|
685 |
|
686 |
}
|
687 |
}
|
688 |
-
|
689 |
//echo('<pre>'.print_r($custom_shipping,true).'</pre>');
|
690 |
}
|
691 |
|
@@ -717,25 +714,20 @@ class wpsc_cart {
|
|
717 |
*/
|
718 |
function update_shipping($method, $option) {
|
719 |
global $wpdb, $wpsc_shipping_modules;
|
720 |
-
|
721 |
-
// if($method == 'weightrate') {
|
722 |
-
// exit("<pre>".print_r(debug_backtrace(),true)."</pre>");
|
723 |
-
// }
|
724 |
$this->selected_shipping_method = $method;
|
725 |
-
|
726 |
$this->shipping_quotes = $wpsc_shipping_modules[$method]->getQuote();
|
727 |
-
|
728 |
//exit('<pre>'.print_r($this->shipping_quotes,true).'</pre> quotes');
|
729 |
$this->selected_shipping_option = $option;
|
730 |
|
731 |
foreach($this->cart_items as $key => $cart_item) {
|
732 |
-
$this->cart_items[$key]->
|
733 |
}
|
734 |
$this->clear_cache();
|
735 |
$this->get_shipping_option();
|
736 |
}
|
737 |
|
738 |
-
|
739 |
/**
|
740 |
* get_tax_rate method, gets the tax rate as a percentage, based on the selected country and region
|
741 |
* @access public
|
@@ -1048,7 +1040,6 @@ class wpsc_cart {
|
|
1048 |
$this->subtotal = null;
|
1049 |
$this->total_price = null;
|
1050 |
$this->uses_shipping = null;
|
1051 |
-
$this->shipping_quotes = null;
|
1052 |
$this->get_shipping_option();
|
1053 |
}
|
1054 |
|
@@ -1962,4 +1953,4 @@ class wpsc_cart_item {
|
|
1962 |
}
|
1963 |
|
1964 |
}
|
1965 |
-
?>
|
481 |
$wpsc_cart->rewind_shipping_methods();
|
482 |
$wpsc_cart->update_shipping('flatrate', $name);
|
483 |
return false;
|
|
|
484 |
}
|
|
|
485 |
return true;
|
486 |
}
|
487 |
|
593 |
}
|
594 |
$this->update_location();
|
595 |
$this->get_tax_rate();
|
596 |
+
$this->unique_id = sha1(uniqid(rand(), true));
|
597 |
|
598 |
$this->get_shipping_method();
|
599 |
}
|
655 |
|
656 |
$this->shipping_methods = get_option('custom_shipping_options');
|
657 |
$this->shipping_method_count = count($this->shipping_methods);
|
658 |
+
|
659 |
if((get_option('do_not_use_shipping') != 1) && (count($this->shipping_methods) > 0) ) {
|
660 |
if(array_search($this->selected_shipping_method, (array)$this->shipping_methods) === false) {
|
661 |
//unset($this->selected_shipping_method);
|
668 |
$this->shipping_quotes = $wpsc_shipping_modules[$this->selected_shipping_method]->getQuote();
|
669 |
}
|
670 |
} else {
|
|
|
671 |
// otherwise select the first one with any quotes
|
672 |
foreach((array)$custom_shipping as $shipping_module) {
|
673 |
// if the shipping module does not require a weight, or requires one and the weight is larger than zero
|
682 |
|
683 |
}
|
684 |
}
|
685 |
+
|
686 |
//echo('<pre>'.print_r($custom_shipping,true).'</pre>');
|
687 |
}
|
688 |
|
714 |
*/
|
715 |
function update_shipping($method, $option) {
|
716 |
global $wpdb, $wpsc_shipping_modules;
|
|
|
|
|
|
|
|
|
717 |
$this->selected_shipping_method = $method;
|
718 |
+
if(is_callable(array($wpsc_shipping_modules[$method]), "getQuote" )) {
|
719 |
$this->shipping_quotes = $wpsc_shipping_modules[$method]->getQuote();
|
720 |
+
}
|
721 |
//exit('<pre>'.print_r($this->shipping_quotes,true).'</pre> quotes');
|
722 |
$this->selected_shipping_option = $option;
|
723 |
|
724 |
foreach($this->cart_items as $key => $cart_item) {
|
725 |
+
$this->cart_items[$key]->calculate_shipping();
|
726 |
}
|
727 |
$this->clear_cache();
|
728 |
$this->get_shipping_option();
|
729 |
}
|
730 |
|
|
|
731 |
/**
|
732 |
* get_tax_rate method, gets the tax rate as a percentage, based on the selected country and region
|
733 |
* @access public
|
1040 |
$this->subtotal = null;
|
1041 |
$this->total_price = null;
|
1042 |
$this->uses_shipping = null;
|
|
|
1043 |
$this->get_shipping_option();
|
1044 |
}
|
1045 |
|
1953 |
}
|
1954 |
|
1955 |
}
|
1956 |
+
?>
|
wpsc-includes/checkout.class.php
CHANGED
@@ -367,9 +367,9 @@ class wpsc_checkout {
|
|
367 |
|
368 |
function form_name() {
|
369 |
if($this->form_name_is_required() && ($this->checkout_item->type != 'heading')){
|
370 |
-
return stripslashes($this->checkout_item->name).'
|
371 |
}else{
|
372 |
-
return stripslashes($this->checkout_item->name)
|
373 |
}
|
374 |
}
|
375 |
|
367 |
|
368 |
function form_name() {
|
369 |
if($this->form_name_is_required() && ($this->checkout_item->type != 'heading')){
|
370 |
+
return stripslashes($this->checkout_item->name).' * ';
|
371 |
}else{
|
372 |
+
return stripslashes($this->checkout_item->name);
|
373 |
}
|
374 |
}
|
375 |
|
wpsc-includes/display.functions.php
CHANGED
@@ -169,7 +169,7 @@ function wpsc_product_url($product_id, $category_id = null, $escape = true) {
|
|
169 |
}
|
170 |
|
171 |
|
172 |
-
|
173 |
if((($wp_rewrite->rules != null) && ($wp_rewrite != null)) || (get_option('rewrite_rules') != null)) {
|
174 |
$url_name = get_product_meta($product_id, 'url_name', true);
|
175 |
$url_name = htmlentities(stripslashes($url_name), ENT_QUOTES, 'UTF-8');
|
169 |
}
|
170 |
|
171 |
|
172 |
+
|
173 |
if((($wp_rewrite->rules != null) && ($wp_rewrite != null)) || (get_option('rewrite_rules') != null)) {
|
174 |
$url_name = get_product_meta($product_id, 'url_name', true);
|
175 |
$url_name = htmlentities(stripslashes($url_name), ENT_QUOTES, 'UTF-8');
|
wpsc-includes/install_and_update.functions.php
CHANGED
@@ -436,10 +436,8 @@ function wpsc_create_upload_directories() {
|
|
436 |
);
|
437 |
foreach ($folders as $folder) {
|
438 |
wp_mkdir_p($folder);
|
439 |
-
|
440 |
-
// echo 'Folder:'.$folder.' Creation attempted';
|
441 |
}
|
442 |
-
|
443 |
//wpsc_copy_themes_to_uploads();
|
444 |
}
|
445 |
|
436 |
);
|
437 |
foreach ($folders as $folder) {
|
438 |
wp_mkdir_p($folder);
|
439 |
+
@ chmod( $folder, 0775 );
|
|
|
440 |
}
|
|
|
441 |
//wpsc_copy_themes_to_uploads();
|
442 |
}
|
443 |
|
wpsc-includes/merchant.class.php
CHANGED
@@ -115,28 +115,18 @@ class wpsc_merchant {
|
|
115 |
'billing' => array(),
|
116 |
'shipping' => array()
|
117 |
);
|
118 |
-
|
119 |
foreach((array)$collected_form_data as $collected_form_row) {
|
120 |
$address_data_set = 'billing';
|
121 |
$address_key = array_search($collected_form_row['unique_name'], $address_keys['billing']);
|
122 |
-
if($address_key
|
123 |
$address_data_set = 'shipping';
|
124 |
-
// exit('<pre>'.print_r($collected_form_row,true).'</pre>');
|
125 |
$address_key = array_search($collected_form_row['unique_name'], $address_keys['shipping']);
|
126 |
}
|
127 |
if($address_key == null) {
|
128 |
continue;
|
129 |
}
|
130 |
-
|
131 |
-
$country = maybe_unserialize($collected_form_row['value']);
|
132 |
-
$address_data[$address_data_set][$address_key] =$country[0];
|
133 |
-
}elseif($collected_form_row['unique_name'] == 'shippingstate'){
|
134 |
-
$address_data[$address_data_set][$address_key] = wpsc_get_state_by_id($collected_form_row['value'], 'code');
|
135 |
-
}else{
|
136 |
-
$address_data[$address_data_set][$address_key] = $collected_form_row['value'];
|
137 |
-
}
|
138 |
}
|
139 |
-
// exit('<pre>'.print_r($address_data,true).'</pre>');
|
140 |
if(count($address_data['shipping']) < 1) {
|
141 |
$address_data['shipping'] = $address_data['billing'];
|
142 |
}
|
115 |
'billing' => array(),
|
116 |
'shipping' => array()
|
117 |
);
|
|
|
118 |
foreach((array)$collected_form_data as $collected_form_row) {
|
119 |
$address_data_set = 'billing';
|
120 |
$address_key = array_search($collected_form_row['unique_name'], $address_keys['billing']);
|
121 |
+
if($address_key === null) {
|
122 |
$address_data_set = 'shipping';
|
|
|
123 |
$address_key = array_search($collected_form_row['unique_name'], $address_keys['shipping']);
|
124 |
}
|
125 |
if($address_key == null) {
|
126 |
continue;
|
127 |
}
|
128 |
+
$address_data[$address_data_set][$address_key] = $collected_form_row['value'];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
129 |
}
|
|
|
130 |
if(count($address_data['shipping']) < 1) {
|
131 |
$address_data['shipping'] = $address_data['billing'];
|
132 |
}
|
wpsc-includes/misc.functions.php
CHANGED
@@ -121,20 +121,15 @@ add_filter('single_post_title','wpsc_post_title_seo');
|
|
121 |
*/
|
122 |
function wpsc_change_canonical_url($url) {
|
123 |
global $wpdb, $wpsc_query, $post;
|
124 |
-
//
|
125 |
-
if(preg_match("/\[productspage\]/",$post->post_content)
|
126 |
if(!is_numeric($_GET['product_id'])) {
|
127 |
$product_id = $wpdb->get_var("SELECT `product_id` FROM `".WPSC_TABLE_PRODUCTMETA."` WHERE `meta_key` IN ( 'url_name' ) AND `meta_value` IN ( '".$wpsc_query->query_vars['product_url_name']."' ) ORDER BY `product_id` DESC LIMIT 1");
|
128 |
} else {
|
129 |
$product_id = absint($_GET['product_id']);
|
130 |
}
|
131 |
-
|
132 |
-
if($product_id > 0){
|
133 |
$url = wpsc_product_url($product_id);
|
134 |
-
}else{
|
135 |
-
$url = get_option('product_list_url');
|
136 |
-
}
|
137 |
-
|
138 |
} else {
|
139 |
if($wpsc_query->query_vars['category_id'] > 0) {
|
140 |
$url = wpsc_category_url($wpsc_query->query_vars['category_id']);
|
@@ -158,13 +153,12 @@ add_filter('aioseop_canonical_url', 'wpsc_change_canonical_url');
|
|
158 |
|
159 |
function wpsc_insert_canonical_url() {
|
160 |
$wpsc_url = wpsc_change_canonical_url(null);
|
161 |
-
// exit($wpsc_url);
|
162 |
echo "<link rel='canonical' href='$wpsc_url' />\n";
|
163 |
}
|
164 |
|
165 |
function wpsc_canonical_url() {
|
166 |
$wpsc_url = wpsc_change_canonical_url(null);
|
167 |
-
if(
|
168 |
remove_action( 'wp_head', 'rel_canonical' );
|
169 |
add_action( 'wp_head', 'wpsc_insert_canonical_url');
|
170 |
}
|
@@ -751,28 +745,4 @@ function wpsc_clear_stock_claims( ) {
|
|
751 |
$wpdb->query("DELETE FROM `".WPSC_TABLE_CLAIMED_STOCK."` WHERE `last_activity` < '{$old_claimed_stock_datetime}' AND `cart_submitted` IN ('0')");
|
752 |
}
|
753 |
add_action('wpsc_daily_cron_tasks', 'wpsc_clear_stock_claims');
|
754 |
-
|
755 |
-
/**
|
756 |
-
* Description Check PHP version to Compare
|
757 |
-
* @access public
|
758 |
-
*
|
759 |
-
* @param string of version to compare
|
760 |
-
* @return boolean true or false
|
761 |
-
*/
|
762 |
-
function phpMinV($v)
|
763 |
-
{
|
764 |
-
$phpV = PHP_VERSION;
|
765 |
-
|
766 |
-
if ($phpV[0] >= $v[0]) {
|
767 |
-
if (empty($v[2]) || $v[2] == '*') {
|
768 |
-
return true;
|
769 |
-
} elseif ($phpV[2] >= $v[2]) {
|
770 |
-
if (empty($v[4]) || $v[4] == '*' || $phpV[4] >= $v[4]) {
|
771 |
-
return true;
|
772 |
-
}
|
773 |
-
}
|
774 |
-
}
|
775 |
-
|
776 |
-
return false;
|
777 |
-
}
|
778 |
?>
|
121 |
*/
|
122 |
function wpsc_change_canonical_url($url) {
|
123 |
global $wpdb, $wpsc_query, $post;
|
124 |
+
// exit('<pre>'.print_r($post,true).'</pre>');
|
125 |
+
if(preg_match("/\[productspage\]/",$post->post_content)) {
|
126 |
if(!is_numeric($_GET['product_id'])) {
|
127 |
$product_id = $wpdb->get_var("SELECT `product_id` FROM `".WPSC_TABLE_PRODUCTMETA."` WHERE `meta_key` IN ( 'url_name' ) AND `meta_value` IN ( '".$wpsc_query->query_vars['product_url_name']."' ) ORDER BY `product_id` DESC LIMIT 1");
|
128 |
} else {
|
129 |
$product_id = absint($_GET['product_id']);
|
130 |
}
|
131 |
+
|
|
|
132 |
$url = wpsc_product_url($product_id);
|
|
|
|
|
|
|
|
|
133 |
} else {
|
134 |
if($wpsc_query->query_vars['category_id'] > 0) {
|
135 |
$url = wpsc_category_url($wpsc_query->query_vars['category_id']);
|
153 |
|
154 |
function wpsc_insert_canonical_url() {
|
155 |
$wpsc_url = wpsc_change_canonical_url(null);
|
|
|
156 |
echo "<link rel='canonical' href='$wpsc_url' />\n";
|
157 |
}
|
158 |
|
159 |
function wpsc_canonical_url() {
|
160 |
$wpsc_url = wpsc_change_canonical_url(null);
|
161 |
+
if($wpsc_url != null) {
|
162 |
remove_action( 'wp_head', 'rel_canonical' );
|
163 |
add_action( 'wp_head', 'wpsc_insert_canonical_url');
|
164 |
}
|
745 |
$wpdb->query("DELETE FROM `".WPSC_TABLE_CLAIMED_STOCK."` WHERE `last_activity` < '{$old_claimed_stock_datetime}' AND `cart_submitted` IN ('0')");
|
746 |
}
|
747 |
add_action('wpsc_daily_cron_tasks', 'wpsc_clear_stock_claims');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
748 |
?>
|
wpsc-includes/productfeed.php
CHANGED
@@ -108,9 +108,9 @@ function wpsc_generate_product_feed() {
|
|
108 |
$purchase_link = wpsc_product_url($product['id']);
|
109 |
|
110 |
$output .= " <item>\n\r";
|
111 |
-
$output .= " <title><![CDATA[".stripslashes($product['name'])."]]></title>\n\r";
|
112 |
$output .= " <link>$purchase_link</link>\n\r";
|
113 |
-
$output .= " <description><![CDATA[".stripslashes($product['description'])."]]></description>\n\r";
|
114 |
$output .= " <pubDate>".date("r")."</pubDate>\n\r";
|
115 |
$output .= " <guid>$purchase_link</guid>\n\r";
|
116 |
|
@@ -156,7 +156,7 @@ function wpsc_generate_product_feed() {
|
|
156 |
foreach ($google_elements as $gelement) {
|
157 |
|
158 |
$output .= " <".$gelement['meta_key'].">";
|
159 |
-
$output .= "<![CDATA["
|
160 |
$output .= "</".$gelement['meta_key'].">\n\r";
|
161 |
|
162 |
if ($gelement['meta_key'] == 'g:condition')
|
108 |
$purchase_link = wpsc_product_url($product['id']);
|
109 |
|
110 |
$output .= " <item>\n\r";
|
111 |
+
$output .= " <title><![CDATA[".htmlentities(stripslashes($product['name']), ENT_NOQUOTES, 'UTF-8')."]]></title>\n\r";
|
112 |
$output .= " <link>$purchase_link</link>\n\r";
|
113 |
+
$output .= " <description><![CDATA[".htmlentities(stripslashes($product['description']), ENT_NOQUOTES, 'UTF-8')."]]></description>\n\r";
|
114 |
$output .= " <pubDate>".date("r")."</pubDate>\n\r";
|
115 |
$output .= " <guid>$purchase_link</guid>\n\r";
|
116 |
|
156 |
foreach ($google_elements as $gelement) {
|
157 |
|
158 |
$output .= " <".$gelement['meta_key'].">";
|
159 |
+
$output .= "<![CDATA[".htmlentities($gelement['meta_value'])."]]>";
|
160 |
$output .= "</".$gelement['meta_key'].">\n\r";
|
161 |
|
162 |
if ($gelement['meta_key'] == 'g:condition')
|
wpsc-includes/theme.functions.php
CHANGED
@@ -182,7 +182,7 @@ function wpsc_enqueue_user_script_and_css() {
|
|
182 |
wp_enqueue_style( 'wpsc-theme-css', $theme_url, false, $version_identifier, 'all');
|
183 |
wp_enqueue_style( 'wpsc-theme-css-compatibility', WPSC_URL. '/themes/compatibility.css', false, $version_identifier, 'all');
|
184 |
wp_enqueue_style( 'wpsc-product-rater', WPSC_URL.'/js/product_rater.css', false, $version_identifier, 'all');
|
185 |
-
wp_enqueue_style( 'wp-e-commerce-dynamic'
|
186 |
wp_enqueue_style( 'wpsc-thickbox', WPSC_URL.'/js/thickbox.css', false, $version_identifier, 'all');
|
187 |
|
188 |
|
182 |
wp_enqueue_style( 'wpsc-theme-css', $theme_url, false, $version_identifier, 'all');
|
183 |
wp_enqueue_style( 'wpsc-theme-css-compatibility', WPSC_URL. '/themes/compatibility.css', false, $version_identifier, 'all');
|
184 |
wp_enqueue_style( 'wpsc-product-rater', WPSC_URL.'/js/product_rater.css', false, $version_identifier, 'all');
|
185 |
+
wp_enqueue_style( 'wp-e-commerce-dynamic', $siteurl."/index.php?wpsc_user_dynamic_css=true&category=$category_id" , false, $version_identifier, 'all' );
|
186 |
wp_enqueue_style( 'wpsc-thickbox', WPSC_URL.'/js/thickbox.css', false, $version_identifier, 'all');
|
187 |
|
188 |
|
wpsc-includes/wpsc_query.php
CHANGED
@@ -303,12 +303,11 @@ function wpsc_the_product_permalink( $category_id = null ) {
|
|
303 |
return wpsc_product_url( $wpsc_query->product['id'], $category_id );
|
304 |
}
|
305 |
|
306 |
-
|
307 |
/**
|
308 |
* wpsc product price function
|
309 |
* @return string - the product price
|
310 |
*/
|
311 |
-
function wpsc_the_product_price(
|
312 |
global $wpsc_query;
|
313 |
$price = calculate_product_price($wpsc_query->product['id'], $wpsc_query->first_variations);
|
314 |
if(($wpsc_query->product['special_price'] > 0) && (($wpsc_query->product['price'] - $wpsc_query->product['special_price'] ) >= 0) && ($variations_output[1] === null)) {
|
@@ -316,10 +315,11 @@ function wpsc_the_product_price($no_decimals = false) {
|
|
316 |
} else {
|
317 |
$output = nzshpcrt_currency_display($price, $wpsc_query->product['notax'], true);
|
318 |
}
|
319 |
-
if(
|
320 |
-
|
321 |
}
|
322 |
-
//
|
|
|
323 |
//echo "<pre>".print_r($wpsc_query->product,true)."</pre>";
|
324 |
return $output;
|
325 |
}
|
@@ -751,52 +751,6 @@ function wpsc_the_variation_name() {
|
|
751 |
return stripslashes($wpsc_query->variation['name']);
|
752 |
}
|
753 |
|
754 |
-
/**
|
755 |
-
* wpsc the variation stock function
|
756 |
-
* @return string - HTML attribute to disable select options and radio buttons
|
757 |
-
*/
|
758 |
-
function wpsc_the_variation_stock() {
|
759 |
-
global $wpsc_query, $wpdb;
|
760 |
-
$out_of_stock = false;
|
761 |
-
if(($wpsc_query->variation_group_count == 1) && ($wpsc_query->product['quantity_limited'] == 1)) {
|
762 |
-
$product_id = $wpsc_query->product['id'];
|
763 |
-
$variation_group_id = $wpsc_query->variation_group['variation_id'];
|
764 |
-
$variation_id = $wpsc_query->variation['id'];
|
765 |
-
|
766 |
-
|
767 |
-
$priceandstock_id = $wpdb->get_var("SELECT `priceandstock_id` FROM `".WPSC_TABLE_VARIATION_COMBINATIONS."` WHERE `product_id` = '{$product_id}' AND `value_id` IN ( '$variation_id' ) AND `all_variation_ids` IN('$variation_group_id') LIMIT 1");
|
768 |
-
|
769 |
-
$variation_stock_data = $wpdb->get_var("SELECT `stock` FROM `".WPSC_TABLE_VARIATION_PROPERTIES."` WHERE `id` = '{$priceandstock_id}' LIMIT 1");
|
770 |
-
|
771 |
-
}
|
772 |
-
return $variation_stock_data;
|
773 |
-
}
|
774 |
-
|
775 |
-
|
776 |
-
/**
|
777 |
-
* wpsc the variation price function
|
778 |
-
* @return string - the variation price
|
779 |
-
*/
|
780 |
-
function wpsc_the_variation_price() {
|
781 |
-
global $wpdb, $wpsc_query;
|
782 |
-
|
783 |
-
if(count($wpsc_query->variation_groups) == 1) {
|
784 |
-
//echo "<pre>".print_r($wpsc_query->variation, true)."</pre>";
|
785 |
-
$product_id = $wpsc_query->product['id'];
|
786 |
-
$variation_group_id = $wpsc_query->variation_group['variation_id'];
|
787 |
-
$variation_id = $wpsc_query->variation['id'];
|
788 |
-
|
789 |
-
$priceandstock_id = $wpdb->get_var("SELECT `priceandstock_id` FROM `".WPSC_TABLE_VARIATION_COMBINATIONS."` WHERE `product_id` = '{$product_id}' AND `value_id` IN ( '$variation_id' ) AND `all_variation_ids` IN('$variation_group_id') LIMIT 1");
|
790 |
-
|
791 |
-
$variation_price = $wpdb->get_var("SELECT `price` FROM `".WPSC_TABLE_VARIATION_PROPERTIES."` WHERE `id` = '{$priceandstock_id}' LIMIT 1");
|
792 |
-
|
793 |
-
$output = nzshpcrt_currency_display($variation_price, $wpsc_query->product['notax'], true);
|
794 |
-
} else {
|
795 |
-
$output = false;
|
796 |
-
}
|
797 |
-
|
798 |
-
return $output;
|
799 |
-
}
|
800 |
/**
|
801 |
* wpsc the variation ID function
|
802 |
* @return integer - the variation ID
|
@@ -1592,9 +1546,7 @@ class WPSC_Query {
|
|
1592 |
$order_by = "`".WPSC_TABLE_PRODUCT_LIST."`.`name` $order";
|
1593 |
} else if (get_option('wpsc_sort_by') == 'price') {
|
1594 |
$order_by = "`".WPSC_TABLE_PRODUCT_LIST."`.`price` $order";
|
1595 |
-
}
|
1596 |
-
$order_by = "`".WPSC_TABLE_PRODUCT_ORDER."`.`order` ASC";
|
1597 |
-
}else {
|
1598 |
if( $order == 'ASC'){
|
1599 |
$order = 'DESC';
|
1600 |
}else{
|
@@ -1602,7 +1554,6 @@ class WPSC_Query {
|
|
1602 |
}
|
1603 |
$order_by = "`".WPSC_TABLE_PRODUCT_LIST."`.`id` $order";
|
1604 |
}
|
1605 |
-
|
1606 |
$rowcount = $wpdb->get_var("SELECT COUNT( DISTINCT `".WPSC_TABLE_PRODUCT_LIST."`.`id`) AS `count` FROM `".WPSC_TABLE_PRODUCT_LIST."`,`".WPSC_TABLE_ITEM_CATEGORY_ASSOC."` WHERE `".WPSC_TABLE_PRODUCT_LIST."`.`publish`='1' AND `".WPSC_TABLE_PRODUCT_LIST."`.`active`='1' AND `".WPSC_TABLE_PRODUCT_LIST."`.`id` = `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`product_id` $no_donations_sql $group_sql");
|
1607 |
|
1608 |
if(!is_numeric($products_per_page) || ($products_per_page < 1)) { $products_per_page = $rowcount; }
|
@@ -1610,22 +1561,16 @@ class WPSC_Query {
|
|
1610 |
$startnum = 0;
|
1611 |
}
|
1612 |
|
1613 |
-
$sql = "SELECT DISTINCT `".WPSC_TABLE_PRODUCT_LIST."
|
1614 |
-
LEFT JOIN `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."` ON `".WPSC_TABLE_PRODUCT_LIST."`.`id` = `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`product_id`
|
1615 |
-
LEFT JOIN `".WPSC_TABLE_PRODUCT_ORDER."` ON `".WPSC_TABLE_PRODUCT_LIST."`.`id` = `".WPSC_TABLE_PRODUCT_ORDER."`.`product_id`
|
1616 |
-
WHERE `".WPSC_TABLE_PRODUCT_LIST."`.`publish`='1' AND `".WPSC_TABLE_PRODUCT_LIST."`.`active`='1' $no_donations_sql $group_sql ORDER BY `".WPSC_TABLE_PRODUCT_LIST."`.`special`, $order_by LIMIT $startnum, $products_per_page";
|
1617 |
-
if(get_option('wpsc_sort_by') == 'dragndrop'){
|
1618 |
-
$sql = "SELECT `products`.* FROM `".WPSC_TABLE_PRODUCT_LIST."` AS `products` LEFT JOIN `".WPSC_TABLE_PRODUCT_ORDER."` AS `order` ON `products`.`id`= `order`.`product_id` WHERE `products`.`active`='1' AND `products`.`publish`='1' AND `order`.`category_id`='0' $search_sql ORDER BY `order`.`order`";
|
1619 |
-
}
|
1620 |
}
|
1621 |
}
|
1622 |
|
1623 |
-
|
1624 |
|
1625 |
//echo "{$sql}";
|
1626 |
$this->category = $this->query_vars['category_id'];
|
1627 |
$this->products = $wpdb->get_results($sql,ARRAY_A);
|
1628 |
-
|
1629 |
$this->total_product_count = $rowcount;
|
1630 |
|
1631 |
if($rowcount > $products_per_page) {
|
303 |
return wpsc_product_url( $wpsc_query->product['id'], $category_id );
|
304 |
}
|
305 |
|
|
|
306 |
/**
|
307 |
* wpsc product price function
|
308 |
* @return string - the product price
|
309 |
*/
|
310 |
+
function wpsc_the_product_price() {
|
311 |
global $wpsc_query;
|
312 |
$price = calculate_product_price($wpsc_query->product['id'], $wpsc_query->first_variations);
|
313 |
if(($wpsc_query->product['special_price'] > 0) && (($wpsc_query->product['price'] - $wpsc_query->product['special_price'] ) >= 0) && ($variations_output[1] === null)) {
|
315 |
} else {
|
316 |
$output = nzshpcrt_currency_display($price, $wpsc_query->product['notax'], true);
|
317 |
}
|
318 |
+
if(get_option('display_pnp') == 1) {
|
319 |
+
//$output = nzshpcrt_currency_display($wpsc_query->product['pnp'], 1);
|
320 |
}
|
321 |
+
//echo $price;
|
322 |
+
$output = apply_filters('wpsc_price_display_changer', $output);
|
323 |
//echo "<pre>".print_r($wpsc_query->product,true)."</pre>";
|
324 |
return $output;
|
325 |
}
|
751 |
return stripslashes($wpsc_query->variation['name']);
|
752 |
}
|
753 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
754 |
/**
|
755 |
* wpsc the variation ID function
|
756 |
* @return integer - the variation ID
|
1546 |
$order_by = "`".WPSC_TABLE_PRODUCT_LIST."`.`name` $order";
|
1547 |
} else if (get_option('wpsc_sort_by') == 'price') {
|
1548 |
$order_by = "`".WPSC_TABLE_PRODUCT_LIST."`.`price` $order";
|
1549 |
+
} else {
|
|
|
|
|
1550 |
if( $order == 'ASC'){
|
1551 |
$order = 'DESC';
|
1552 |
}else{
|
1554 |
}
|
1555 |
$order_by = "`".WPSC_TABLE_PRODUCT_LIST."`.`id` $order";
|
1556 |
}
|
|
|
1557 |
$rowcount = $wpdb->get_var("SELECT COUNT( DISTINCT `".WPSC_TABLE_PRODUCT_LIST."`.`id`) AS `count` FROM `".WPSC_TABLE_PRODUCT_LIST."`,`".WPSC_TABLE_ITEM_CATEGORY_ASSOC."` WHERE `".WPSC_TABLE_PRODUCT_LIST."`.`publish`='1' AND `".WPSC_TABLE_PRODUCT_LIST."`.`active`='1' AND `".WPSC_TABLE_PRODUCT_LIST."`.`id` = `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`product_id` $no_donations_sql $group_sql");
|
1558 |
|
1559 |
if(!is_numeric($products_per_page) || ($products_per_page < 1)) { $products_per_page = $rowcount; }
|
1561 |
$startnum = 0;
|
1562 |
}
|
1563 |
|
1564 |
+
$sql = "SELECT DISTINCT `".WPSC_TABLE_PRODUCT_LIST."`.* FROM `".WPSC_TABLE_PRODUCT_LIST."`,`".WPSC_TABLE_ITEM_CATEGORY_ASSOC."` WHERE `".WPSC_TABLE_PRODUCT_LIST."`.`publish`='1' AND `".WPSC_TABLE_PRODUCT_LIST."`.`active`='1' AND `".WPSC_TABLE_PRODUCT_LIST."`.`id` = `".WPSC_TABLE_ITEM_CATEGORY_ASSOC."`.`product_id` $no_donations_sql $group_sql ORDER BY `".WPSC_TABLE_PRODUCT_LIST."`.`special`, $order_by LIMIT $startnum, $products_per_page";
|
|
|
|
|
|
|
|
|
|
|
|
|
1565 |
}
|
1566 |
}
|
1567 |
|
1568 |
+
|
1569 |
|
1570 |
//echo "{$sql}";
|
1571 |
$this->category = $this->query_vars['category_id'];
|
1572 |
$this->products = $wpdb->get_results($sql,ARRAY_A);
|
1573 |
+
|
1574 |
$this->total_product_count = $rowcount;
|
1575 |
|
1576 |
if($rowcount > $products_per_page) {
|