if the goods are less than 6000grams, it will show error.....look at the photo
there is "Continue" button at right side
if order is less than 6000 grams, the button will be disable & below button there will be a note
"Sorry, cannot continue, Your order is less than 6000 grams"
PLEASE ANY CODER, DEVELOPER, ADMINISTRATOR I NEED HELP HERE
THANKS
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
If you are interested, PM me, it shouldn't take me more than a working day to implement, at a low cost.
Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig
i think i have to edit the basket page...
http://demo.opencart.com/index.php?controller=cart
can anybody tell me where is that page located ??
i think
in this page if i set validation for weight, that if weight is less than 6000 grams then "Checkout" button should be disabled
and below the button there will be note "Buy atleast 6000 grams of goods."
i think i just have to edit these in basket page
am i right

if yes how can i do that

please i need help
Thank you,
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
catalog\template\default\content\cart.tpl you need to put some logic in here to optionally display the checkout button.
The problem is larger though because the checkout button is still displayed in the header. You will have to put a similar test for a valid order amount in
catalog\controller\checkout_payment.php and redirect back to cart if the order is not valid.

tell me, how much time it may take

Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
Insert the following lines into function __construct :
Add the following function after the __construct :$this->config =& $locator->get('config');
$this->weight =& $locator->get('weight');
Code: Select all
function getWeight() {
$language = $this->language;
$languageId = $language->languages[$language->code]['language_id'];
$total = 0;
foreach ($this->cart->products as $product) {
$productId = $product['product_id'];
$weight = $this->weight->convert($product['weight'] * $product['quantity'], $product['weight_class_id'], $this->config->get('config_weight_class_id'));
$total += $weight;
}
$defaultWeightClassId = $this->config->get('config_weight_class_id');
$kgWeightClassId = 0;
if ($row = $this->database->getRow( "select weight_class_id from `weight_class` where `unit`='kg' and language_id=$languageId;" )) {
$kgWeightClassId = $row['weight_class_id'];
}
if ($kgWeightClassId == 0) {
$error = $this->language->get('text_zone_error_unit' );
}
$weight = $this->weight->convert( $total, $defaultWeightClassId, $kgWeightClassId );
return $weight;
}
Code: Select all
$weight = $this->getWeight();
$method_data = array();
if ($quote_data) {
$method_data = array(
'id' => 'zone',
'title' => $this->language->get('text_zone_title'),
'quote' => $quote_data,
'tax_class_id' => $this->config->get('zone_tax_class_id'),
'sort_order' => $this->config->get('zone_sort_order'),
'error' => ($weight < 6.0) ? $this->language->get('text_zone_error_weight' ) : false
);
}
return $method_data;
Code: Select all
$_['text_zone_error_unit'] = "Unable to convert product weights in 'kg' units";
$_['text_zone_error_weight'] = "No products can be shipped until the total minimum weight is at least 6 kg";
Code: Select all
<td colspan="2" class="g"><div class="warning"><?php $hasError=true; echo $method['error']; ?></div></td>
Code: Select all
<?php if ((!isset($hasError)) || (!$hasError)) { ?>
<td align="right"><input type="submit" value="<?php echo $button_continue; ?>"></td>
<?php } ?>
Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig
very much
it also works on 7.7 version
i want to know how can i get my username & password ??
i forgot it
how can i get it back or reset it
??
thank you
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
i add new product & set its weight in 20KG
it should proceed for checkout but it shows error of 6kg
also i want to add 1 thing....
if weight is 6kg, then $12 will be charged
if weight is 7kg, then $14 will be charged
if weight is 8kg, then $16 will be charged
if weight is 9kg, then $20 will be charged
like that
i am using 0.7.7 version
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
i cannot edit any products weight
when i changes & re checks , it shows 999.99 Grams
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
In your OpenCart's admin panel, select Extensions > Shipping.
This will list the installed shipping modules. If the 'zone' shipping module hasn't yet been installed, click on the Insert button and fill in the details, as follows:
General:
Extension Name: whatever you like
Description: a brief description
Data:
Code: zone
Directory: shipping
Filename: zone.php (or whatever the name of your modified zone-shipping file)
Controller: shipping_zone
Now click on the List icon. The list will now include your zone-shipping module. Click on its Configure-icon (located at the right) and enter the following:
Shipping Zone 1 Status: Enabled
Shipping Zone 1 Cost: 6:12,7:14,8:16,9:20 etc.
Also select tax zones and tax classes as appropriate for your area.
The format of the shipping zone costs basically is a comma-separated list of
weight1:cost1,weight2:cost2,weight3:cost3 etc.
meaning this: any shipment up to 6.000 kg costs $12.00, between 6.001kg up to 7.000kg costs $14.00, between 7.001kg up to 8.000kg costs $16.00 etc.
I haven't tested the zone-shipping, I just gathered this information from other forum posts, corrections welcome if I am wrong.
Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig
Admin > Configuration > Localization > Geo Zone
Each zone defined will be included in your zone shipping module, provided you enable them in there.
Also, your tax classes are to be defined in your OpenCart's admin panel under the menu:
Admin > Configuration > Localization > Tax Class
The tax class is to be selected when configuring your zone shipping module, or your can select none.
Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig
actually i am in india and i want to export food products all over the world
here is my demo site
http://www.tempdemo.66ghz.com/
i am using 0.7.7
in 0.7.8, i cannot see anything in modules ......
so in forum, some admin told me to use 0.7.7
and sir, the code which you gave me is working
but i buy products of 12kg but still error "No products can be shipped until the total minimum weight is at least 6 kg"
appears
you told me that use this on 0.7.8 , but i am using 0.7.7
please sir i need your serious help
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
i want that 6 KG error
>> if products weight is less that 6 KG , it will show error
i want zone shipping tax which varies from country to country....
>> USA citizen will have to pay tax of $12 , Australian citizen will have to tax of $17
i want to use 6KGs weight charges
>> if goods weight is 6kg, then customer should pay $17
if goods weight is 7kg, then customer should pay $19
if goods weight is 8kg, then customer should pay $11
if goods weight is 9kg, then customer should pay $17
and so on till 20KG
well when zone tax and above 6 KGs weight rate will added, then there comes final amount which consumer should pay
i got that 6 KGs criteria and coding which is in 0.7.8
finally which version i have to choose

PLEASE SIR I NEED HELP
Thank you
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
Go with version 0.7.8. There are some issues which are all documented on this forum:so finally which version i have to choose ??
1) Edit the zone-module for the 6KG limit as per my previous message on this forum thread.
2) Edit file /library/environment/url.php. In function create, the last line should be:
Code: Select all
return $server . $link;
Code: Select all
# Please ensure register_globals is Off by uncommenting this line
#php_flag register_globals Off
# URL Alias - see install.txt
Options +FollowSymlinks
<IfModule mod_rewrite.c>
RewriteEngine On
#OPENCART REWRITES START
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*) index.php
#OPENCART REWRITES END
</IfModule>
If you use different shipping zones, you can edit and/or create them via OpenCart's admin panel:
Admin > Configuration > Localisation > Geo Zones
If you use different tax classes, you can edit and/or create them via OpenCart's admin panel:
Admin > Configuration > Localisation > Tax Class
The tax classes are based on a selected geo zones.
The zone-shipping module should pick up are your geo-zones automatically.
You still need to enable them in there and add your weights:prices lists for each geo-zone.
Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig
return $server . $link;
i am confused that where should i post..
Sir, can you send me the whole page code ??
please sir
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
there is a Zone tab
but i want paypal
how can i do that ??
Website Hosting Mumbai Domain Registration Mumbai
Web Hosting India
It's in file /library/environment/url.php, whose create function should look like this:ankur0101 wrote: i gott everything except
return $server . $link;
i am confused that where should i post..
Sir, can you send me the whole page code ??
please sir
Code: Select all
function create($server, $controller, $action = NULL, $query = array()) {
$link = 'controller=' . $controller;
foreach ($query as $key => $value) {
if ($value) {
$link .= '&' . $key . '=' . $value;
}
}
if ($action) {
$link .= '&action=' . $action;
}
if (isset($this->data[$link])) {
$link = $this->data[$link];
} else {
$link = 'index.php?' . $link;
}
//remastered URLs out
if (!preg_match('/\/admin\/index.php/',$_SERVER['PHP_SELF'])) { // not admin area
$link=str_replace('controller=','',$link);
$link=str_replace('&','/',$link);
$link=str_replace('=','/',$link);
$link=str_replace('index.php?','',$link);
}
return $server . $link;
}
Export/Import Tool * SpamBot Buster * Unused Images Manager * Instant Option Price Calculator * Number Option * Google Tag Manager * Survey Plus * OpenTwig
Users browsing this forum: No registered users and 4 guests