osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 

Must Agree to Terms Mod?

This is a discussion on Must Agree to Terms Mod? within the osCMax v2 Customization/Mods forums, part of the osCMax v2.0 Forums category; Hi, A client for whom I built an OSCMax site is being required by the mfg. of products he sells ...


Go Back   osCommerce and osCMax shopping cart software forums > osCMax v2.0 Forums > osCMax v2 Customization/Mods

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Reply

 

LinkBack Thread Tools
  #1  
Old 02-11-2008, 09:07 AM
Lurker
 
Join Date: Apr 2007
Posts: 3
Thanks: 2
Thanked 0 Times in 0 Posts
Rep Power: 0
virtbizGuy is on a distinguished road
Default Must Agree to Terms Mod?

Hi,

A client for whom I built an OSCMax site is being required by the mfg. of products he sells to have a checkbox that states that the product being sold is only for home use before the order is permitted to go through.

I found a contribution in the OSC contributions that will work for me. It is called "Must Agree to Terms" and can be found at: osCommerce Community Add-Ons

1. Is there a mod available for OSCMax that would do the same thing? (note that I will change the text from "I have read the conditions, etal" to "I certify this purchase is for home use, etal," a simple fix.)

2. If not, here is my problem. It wants me to insert javascript functions into the <head> in the file: catalog/checkout_confirmation.php, after the line: <link rel="stylesheet" type="text/css" href="stylesheet.css">

Well, there is not <head> in that OSCMax file. The file opens with a php include, so I am assuming the head content is provide from elsewhere through another include.

If it is "OK" to use this OSC contribution for this OSCMax site, then where can I add the javascript functions?


The other changes, adding two files and modifying 2 others seems easy and straight forward and the code I am to look for (after which additional code is to be added) is easily found.

Thank you,

Klaus
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2  
Old 02-12-2008, 08:31 AM
osCMax Testing Team
 
Join Date: Oct 2006
Location: Atlanta GA
Posts: 143
Thanks: 8
Thanked 13 Times in 9 Posts
Rep Power: 2
ALElder
Default Re: Must Agree to Terms Mod?

I have used this mod with oscmax osCommerce Community Add-Ons

No change needed in the code
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
The Following User Says Thank You to ALElder For This Useful Post:
virtbizGuy (02-12-2008)
  #3  
Old 02-12-2008, 09:36 AM
Lurker
 
Join Date: Apr 2007
Posts: 3
Thanks: 2
Thanked 0 Times in 0 Posts
Rep Power: 0
virtbizGuy is on a distinguished road
Default Re: Must Agree to Terms Mod?

Thanks for that!

When you say that there is no change needed in the code, I am not sure what you mean. Of course the code that is called for to be added in the contribution needs to be added, right? Or?

I had actually planned to use this one first yesterday, but got a little off track when it called for a change in line 355 of the code of catalog/checkout_payment.php, as that file in OSCMax is much shorter. But then I recalled that a lot of the code from many OSCMax files has been moved to the template folder, and I did find the code that is to be added beneath in templates/fallback/content/checkout_payment.tpl.php. Do you happen to know whether that is the correct file, the one that needs the code added.

I ask because I did try to add the other contribution, the one I linked to in my original post, and while all appeared to go well, when I tested, there was no change. No check box appeared in checkout. As I have not previously had need to mod any of those files in the templates directory, I am not sure I am doing the right thing.

I will likely go ahead and back out those changes and try this one. I'll post my results.

Thanks, Klaus
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4  
Old 02-12-2008, 09:38 AM
Active Member
 
Join Date: Oct 2005
Location: wherever I happen to be at the moment
Posts: 409
Thanks: 3
Thanked 64 Times in 62 Posts
Rep Power: 6
met00 is a jewel in the roughmet00 is a jewel in the roughmet00 is a jewel in the roughmet00 is a jewel in the rough
Default Re: Must Agree to Terms Mod?

1) javascript does NOT have to be in the <head> it can appear anywhere before it is called. I have a number of mods in OSC where I load a specific javascript in certain pages, but not in others (ie: loded in the details page, but not in a listings page).

2) CSS additions can be made to the template stylesheet.css with almost no overhead
__________________
so endith the lesson
<think>sometimes I just sit's and thinks</think>
"Here you are with a hand full of holes, a thumb up your ass, and a big grin to pass the time of day with." - TWB
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
The Following User Says Thank You to met00 For This Useful Post:
virtbizGuy (02-12-2008)
  #5  
Old 02-12-2008, 09:44 AM
Active Member
 
Join Date: Oct 2005
Location: wherever I happen to be at the moment
Posts: 409
Thanks: 3
Thanked 64 Times in 62 Posts
Rep Power: 6
met00 is a jewel in the roughmet00 is a jewel in the roughmet00 is a jewel in the roughmet00 is a jewel in the rough
Default Re: Must Agree to Terms Mod?

Quote:
Originally Posted by virtbizGuy View Post
Thanks for that!
I had actually planned to use this one first yesterday, but got a little off track when it called for a change in line 355 of the code of catalog/checkout_payment.php, as that file in OSCMax is much shorter. But then I recalled that a lot of the code from many OSCMax files has been moved to the template folder, and I did find the code that is to be added beneath in templates/fallback/content/checkout_payment.tpl.php. Do you happen to know whether that is the correct file, the one that needs the code added.
copy the tpl.php file from templates/fallback/content/ to templates/[your template directory]/content/

Then you can make any modifications that will differentiate the program in that new file

The nicest part about this is that you can easily turn the file on and off when testing new functionality by using a rename on the file you are working on, when it is named correctly it will be run, but when you rename it (ie: from checkout_payment.tpl.php to _checkout_payment.tpl.php ) it is not seen and the fallback will run.
__________________
so endith the lesson
<think>sometimes I just sit's and thinks</think>
"Here you are with a hand full of holes, a thumb up your ass, and a big grin to pass the time of day with." - TWB
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6  
Old 02-12-2008, 09:56 AM
Lurker
 
Join Date: Apr 2007
Posts: 3
Thanks: 2
Thanked 0 Times in 0 Posts
Rep Power: 0
virtbizGuy is on a distinguished road
Default Re: Must Agree to Terms Mod?

Thank you!

Both your posts are GREAT. I have only done 2 sites in OSCMax (about 25-30 in OSC and 15 or so in Cartweaver) and since neither required much in mods, until now, I had not gone into the template structure. I have moved away from OSC in the last year in favor of Cartweaver because of its 100% css layout and the ease with which I can build sites with any design I have in mind in CW versus the "same old look" of OSC. But, now that I am getting into this OSCMax a little deeper, it's interesting. Plus, CW requires a lot of writing .php for options not included in the software, whereas OSC has all those contributions. I might do the next shop in OSCMax again, just to dig a little deeper into it.

Thanks again for the great input. I will use it, with appreciation.

Klaus
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7  
Old 02-28-2008, 03:57 PM
osCMax Testing Team
 
Join Date: Nov 2002
Location: Orlando
Posts: 200
Thanks: 10
Thanked 22 Times in 14 Posts
Rep Power: 7
JohnW will become famous soon enoughJohnW will become famous soon enough
Default Re: Must Agree to Terms Mod?

Quote:
Originally Posted by met00 View Post
copy the tpl.php file from templates/fallback/content/ to templates/[your template directory]/content/

Then you can make any modifications that will differentiate the program in that new file

The nicest part about this is that you can easily turn the file on and off when testing new functionality by using a rename on the file you are working on, when it is named correctly it will be run, but when you rename it (ie: from checkout_payment.tpl.php to _checkout_payment.tpl.php ) it is not seen and the fallback will run.
I'm embarrassed to admit this but somehow I never caught on to this until now. Of course, now it seems so obvious but still a great idea.
__________________
John
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8  
Old 03-05-2008, 08:52 AM
rkah's Avatar
New Member
 
Join Date: Feb 2008
Location: Midwest
Posts: 21
Thanks: 2
Thanked 2 Times in 2 Posts
Rep Power: 0
rkah is on a distinguished road
Default Re: Must Agree to Terms Mod?

Would anyone know which file I need to point this line to in the mustagree mod that was mentioned?
File:/catalog/Checkout_Fail.PHP

Around line 29
<!-- header //-->
<?php require(DIR_WS_INCLUDES . 'header.php'); ?>
<!-- header_eof //-->

There is a footer.php file missing also. I copied these over from osCommerce, and changed a few paths for the images, but the fail page is still missing some layout info. (borders and such) I just wondered if there was someone who knew this off the top of their head.

Last edited by rkah; 03-05-2008 at 08:58 AM. Reason: Bad grammar....
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Must agree to terms michael_s New osCommerce Contributions 0 07-27-2007 06:51 AM
Must agree to terms michael_s New osCommerce Contributions 0 05-09-2007 03:20 AM
Must agree to terms michael_s New osCommerce Contributions 0 03-22-2007 10:50 AM
Must agree to terms michael_s New osCommerce Contributions 0 03-16-2007 09:04 PM
Must agree to Terms michael_s New osCommerce Contributions 0 01-16-2007 03:00 AM


All times are GMT -8. The time now is 10:08 PM.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO
Copyright 2008 osCMax