Jump to content
Sign in to follow this  
LisaT

Giftwrap option not showing?

Recommended Posts

I've installed the giftwrap cont. and it's Ok except on checkout_shipping.php, the customer is not offered the choice of giftwrap or not. Please see Get the Giftand you will see what I mean. The giftwrap box is there, but not the radio selection button.

Any idea what I've missed?

Share this post


Link to post
Share on other sites

Are there any known conflicts between this giftwrap cont. and STS? I successfully added teh giftwrap cont. to another site, but on my present site I find that the radio buttons and message areas are not shown in checkout_shipping.php. I've checked the code over and over and cannot see anything wrong. I've now had to remove the giftwrap code from my files. The only difference between the 2 sites is that the present one has STS installed.

Any ideas??

Share this post


Link to post
Share on other sites
Are there any known conflicts between this giftwrap cont. and STS? I successfully added teh giftwrap cont. to another site, but on my present site I find that the radio buttons and message areas are not shown in checkout_shipping.php. I've checked the code over and over and cannot see anything wrong. I've now had to remove the giftwrap code from my files. The only difference between the 2 sites is that the present one has STS installed.

Any ideas??

Lisa, I'm having the same problem and I don't have STS installed, so I don't think that's your problem. I'll let you know when I find an answer.

 

Regards,

 

Grayson


Grayson Morris

Share this post


Link to post
Share on other sites

Alright, I've found the problem. In catalog/includes/modules/giftwrap, open up giftwrap.php and nogiftwrap.php. You'll see that they're pretty much the same, except that in nogiftwrap.php, a few lines still have "shipping" in them, which is clearly wrong (leftover from the copy-and-change, I presume). Make the following fixes in nogiftwrap.php:

 

Change (about line 25):

 

if ( ($this->enabled == true) && ((int)MODULE_SHIPPING_FLAT_ZONE > 0) ) {

 

to

 

if ( ($this->enabled == true) && ((int)MODULE_GIFT_ZONE > 0) ) {

 

and change (about line 67):

 

tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('NoGiftWrap Zone', 'MODULE_SHIPPING_ZONE', '0', 'If a zone is selected, only enable this giftwrap method for that zone.', '6', '0', 'tep_get_zone_class_title', 'tep_cfg_pull_down_zone_classes(', now())");

 

to

 

tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('NoGiftWrap Zone', 'MODULE_GIFT_ZONE', '0', 'If a zone is selected, only enable this giftwrap method for that zone.', '6', '0', 'tep_get_zone_class_title', 'tep_cfg_pull_down_zone_classes(', now())");

 

 

That should do the trick (it did for me).

 

Regards,

 

Grayson


Grayson Morris

Share this post


Link to post
Share on other sites

Hi Grayson,

 

No. I've looked through my files and I don't see any reference to SHIPPING at all. I must have a different gremlin in my system!!

Share this post


Link to post
Share on other sites

That's too bad, Lisa! I hope you find your gremlin soon ;-). Please do post your fix here when you find one--it'll help folks who have your same problem in the future.

 

Regards,

 

Grayson


Grayson Morris

Share this post


Link to post
Share on other sites
Hi Grayson,

 

No. I've looked through my files and I don't see any reference to SHIPPING at all. I must have a different gremlin in my system!!

 

 

I have the same problem. :huh:

So I make these changes:

 

 

add a second javascript function after the function selectRowEffect:

 

function selectRowEffectGift(object, buttonSelect) {

if (!selected) {

if (document.getElementById) {

selected = document.getElementById('defaultSelected');

} else {

selected = document.all['defaultSelected'];

}

}

 

if (selected) selected.className = 'moduleRow';

object.className = 'moduleRowSelected';

selected = object;

 

// one button is not an array

if (document.checkout_address.giftwrap[0]) {

document.checkout_address.giftwrap[buttonSelect].checked=true;

} else {

document.checkout_address.giftwrap.checked=true;

}

}

 

 

change:

 

if ( ($quotes1[$i]['id'] . '_' . $quotes1[$i]['methods'][$j]['id'] == $giftwrap_info['id']) || (tep_count_giftwrap_modules() == (int)1) ) {

echo ' <tr id="defaultSelected" class="moduleRowSelected" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="selectRowEffect(this, ' . $radio_buttons . ')">' . "\n";

} else {

echo ' <tr class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="selectRowEffect(this, ' . $radio_buttons . ')">' . "\n";

}

 

 

to

 

if ( ($quotes1[$i]['id'] . '_' . $quotes1[$i]['methods'][$j]['id'] == $giftwrap_info['id']) || (tep_count_giftwrap_modules() == (int)1) ) {

echo ' <tr id="defaultSelected" class="moduleRowSelected" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="selectRowEffectGift(this, ' . $radio_buttons . ')">' . "\n";

} else {

echo ' <tr class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="selectRowEffectGift(this, ' . $radio_buttons . ')">' . "\n";

}

 

 

 

Best Regards

Frank

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×