Support Forums

Old 04-01-2007, 09:08 PM   #1
68 Evangelist & Developer
 
 
Join Date: Jan 2007
Location: Pennsylvania, USA
Posts: 1,522
Rep Power: 44
Mike-N-Tosh is just really niceMike-N-Tosh is just really nice
Default Custom checkout templates?

Greetings,

Curious if any has already done this or if anyone knows how this could be done. As there are categories that don't need a price or that there is an extra field to be used instead of the default price field, is there a way to make custom template pages for the checkout portion of placing the ad.

For instance, I have category, "Real Estate" with a subcategory, "For Sale" in it. I have several extra fields included in this subcategory including, "Listing Price". I would like to be able to make a template that would make more sense to the seller when placing the ad. Things like not including the default "Price" field which is not used and putting the "Listing Price" instead. In addition, placing the extra fields in a table that makes sense like as the are listed when the ad is viewed. (Like grouping all of the extra fields together that relate to the physical property, then grouping the extra fields together that relate to location and legals, etc.)

A much more simple example is a "Personals" ad which obviously doesn't require a price. (If it does require a price, it would most likely be deleted as a violation of our TOS ) So, I would like to be able to somehow send the user to a different checkout template based on which category the end user selects in the first step of the checkout process. Something like this:
PHP Code:
        if($lDisplay==1)
            switch(
$section)
            {
                case 
16//Personals
                
case 26//Wanted
                       
case 27//Announcements
                    
$class_tpl->assign('body','nopricecheckout.tpl.php');
                break;
                case 
32//Vehicles-Cars
                    
$class_tpl->assign('body','vehiclecheckout.tpl.php');
                break;
                case 
73//Real Estate-For Rent
                    
$class_tpl->assign('body','realrentcheckout.tpl.php');
                break;
                case 
74//Real Estate-For Sale
                    
$class_tpl->assign('body','realsale.tpl.php');
                break;
                   }
              else
             {
            
$class_tpl->assign('body','step3.tpl.php'); 
Anyone done something like this? Anyone know if this is even possible?

Thanks,
Mike
__________________
Mike-N-Tosh
IndianaPC.org - A community website (v3.1.10 Developer - heavily modified)
Sandbox (v3.1.10, v4.0.9, 4.1.3)
Visit My blog for tips, tricks, tutorials, reviews for 68 Classifieds as well as my store with Templates, Mods & Docs
Web Hosting | Web Design & Development | 68 Classifieds Customizations
I am not a 68C employee, just a user and try to help out
Mike-N-Tosh is offline   Reply With Quote
Old 04-02-2007, 12:52 AM   #2
Senior Member
 
midi510's Avatar
 
Join Date: Mar 2007
Location: Mammoth Lakes, Ca
Posts: 135
Rep Power: 13
midi510 is a jewel in the rough
Default

I've been thinking about that a lot lately, too. Do I go through all the work to learn how and then set up custom checkout tpls and corresponding show/viewlistings or wait to see what V4 has to offer. What I would like to see is something like the listing packages section in admin. You define the fields and select which categories use each one.
If V4 isn't going to have anything like that, I'll be doing a lot of work in this area and post any positive results I have
__________________
Kirk
V3.1.7 Developer
May you & your loved ones be blessed with
Grace, Peace, Forgiveness, Love, Wisdom, & Joy
midi510 is offline   Reply With Quote
Old 04-02-2007, 04:34 AM   #3
Senior Member
 
midi510's Avatar
 
Join Date: Mar 2007
Location: Mammoth Lakes, Ca
Posts: 135
Rep Power: 13
midi510 is a jewel in the rough
Default

Ya know, step 2 in checkout is picking a package. In admin you get to pick which categories use which packages. I don't know PHP yet, but if you can call different step 3s (bulletinboard_st3.tpl.php, joblisting_st3.tpl.php, etc.) by the package you select, you can get your custom checkout. If your showlisting(2).tpl.php is kept real basic you wouldn't need to customize. Setting up custom viewlisting pages should be easy enough, but I don't know how you would call them out.

In my last post I realize you can assign categories in extra fields, but it would be really nice to be able to do it in the defaults. To be able to Pick categories for display and required. And to have the option of currency for extra fields. I think this would eliminate the need for all this custom coding.

I highly recommend the Price Descriptor mod by http://www.mods.auscity.com. Chaslie also showed me how to replace a default $0.00 price with whatever I wanted. N/A now shows up if nothing or a non integer is entered in the price field in checkout.
PHP Code:
{$listingprice|replace:'$0.00':'N/A'
__________________
Kirk
V3.1.7 Developer
May you & your loved ones be blessed with
Grace, Peace, Forgiveness, Love, Wisdom, & Joy
midi510 is offline   Reply With Quote
Old 04-02-2007, 08:32 AM   #4
68 Evangelist & Developer
 
 
Join Date: Jan 2007
Location: Pennsylvania, USA
Posts: 1,522
Rep Power: 44
Mike-N-Tosh is just really niceMike-N-Tosh is just really nice
Default

Quote:
Originally Posted by midi510 View Post
If your showlisting(2).tpl.php is kept real basic you wouldn't need to customize. Setting up custom viewlisting pages should be easy enough, but I don't know how you would call them out.
I haven't done any custom showlisting.tpl.php templates yet, but I realize that since the default price field isn't needed in some categories I am now going to be looking at that.

I already use custom viewlisting.tpl.php pages and that works great. The code posted in my first post in this thread is actually from my "viewlisting.php" file which is what is making the call to use the custom view templates that I created.

My post is whether I can use this same logic in the checkout as well.

-Mike
__________________
Mike-N-Tosh
IndianaPC.org - A community website (v3.1.10 Developer - heavily modified)
Sandbox (v3.1.10, v4.0.9, 4.1.3)
Visit My blog for tips, tricks, tutorials, reviews for 68 Classifieds as well as my store with Templates, Mods & Docs
Web Hosting | Web Design & Development | 68 Classifieds Customizations
I am not a 68C employee, just a user and try to help out

Last edited by Mike-N-Tosh; 04-02-2007 at 12:07 PM.
Mike-N-Tosh is offline   Reply With Quote

Bookmarks

Thread Tools
Display Modes

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
Smarty Templates and You. Posted BY Lhotch Eric Barnes HTML, CSS, and Design Help 13 10-02-2007 08:06 AM
Where is the custom field search function? MrSpandex v3.1 Modules & Modifications 3 12-08-2006 06:33 PM
Custom Payment Mod pruffin v3.1 Questions & Support 0 12-06-2006 12:34 AM
Adding viewlisting and showlisting templates sleepy HTML, CSS, and Design Help 2 04-08-2006 05:56 PM


All times are GMT -4. The time now is 12:52 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0