If you are a beginner with the shop system, you should start with the step by step tutorial which is available under the extension key tut_ttproducts_de.
Example of a configuration from Inter-Photo A/S (www.inter-photo.dk):
xxxxx.xxxx {10.title = Dankort, VISA-Dankort
10.image.file = media/logos/dankort.gif
10.image.params = align=absmiddle vspace=2
10.handleScript = media/scripts/payment_DIBS.php
10.handleScript {merchant = xxxxx
test = 0
k1 = xxxxx
k2 = xxxxx
currency = 208
addOrderInfo = 1
account =
cardType = DK,V-DK
relayURL = http://www.inter-photo.dk/index.php?id=204
}
10.handleURL = index.php?id=204
10.handleTarget = _top
20 < .10
20.title = Unibank e-betaling
20.image.file = media/logos/soloe.gif
20.handleScript.soloe=1
}
Example in product view make product title the page's title
If you want to fetch the product title into some marker, i.e. for use in automake_template or similar, try this code:
Code Listing:
# first set pagetitle to the page's title
temp.pagetitle = TEXT
temp.pagetitle.field = title
# now overwrite with the product's title in case it's non-empty
[globalVar = GP:tt_products > 0]
temp.pagetitle = COA
temp.pagetitle {10 = RECORDS
10 {source.data = GPvar:tt_products
tables = tt_products
conf.tt_products = TEXT
conf.tt_products {field = title
}
}
}
// For single record display, cache has to be disabled.
config.no_cache = 1
[global]
temp.mainTemplate = TEMPLATE
temp.mainTemplate {# Feeding the content from the Auto-parser to the TEMPLATE cObject:
template =< plugin.tx_automaketemplate_pi1
# Select only the content between the <body>-tags
workOnSubpart = DOCUMENT_BODY
subparts.title < temp.pagetitle
....
Example templates
Here comes the template part, when a new user has been registered automatically as front end user.
<BR><BR><BR><BR><HR><BR><BR><BR> <h3>EMAIL_NEWUSER_TEMPLATE</h3> <em> Subpart used as template for the account-creation-emails. First line is used as subject for the mail.<br> </em><br> <pre> <!-- ###EMAIL_NEWUSER_TEMPLATE### begin Subpart used as template for the account-creation-emails First line is used as subject for the mail. --> New user account created Dear ###PERSON_NAME###, you have made an order at http://..................../ for the first time. To make orders in the future more easy a user account has been created. Your account data: user name: ###USERNAME### password: ###PASSWORD### Regards,
the Shopmaster <!-- ###EMAIL_NEWUSER_TEMPLATE### end --> </pre>
Example bananaGuard
(see file example_template_bill_de.tmpl delivered from http://bananaguard.de)
This example includes special price calculations and the automatic creation of a bill and delivery sheet. You have to install the extensions feuser_admin and conf_userts if you want to build a similar shop. Move the example_template_bill_de.tmpl to fileadmin/tmpl_files/products_eur_.tmp. To use this template you have to search for '?id=' in your text and substitute to following PIDs with those of your system.
The pages and plugins for the page tree are:
- 'BananaGuard' with main template of your choice and
Constants:
plugin.tx_srfeuserregister_pi1.email = info@shopms.de
plugin.tx_srfeuserregister_pi1.confirmPID = 83 ... You have to use your confirm PID.
styles.content.loginform.pid = 108 ... Your Users sysfolder PID.
-- 'Home' which is a shortcut to BananaGuard
-- 'Preise und Versand' with special information about the prices and shipping
-- 'BananaShop' which has its own template especially for usage with the shopping system
Constants:
plugin.tt_products.file.templateFile = typo3/ext/tt_products/pi/products_eur_.tmpl
plugin.tt_products.TAXpercentage = 16
plugin.tt_products.priceDecPoint = .
plugin.tt_products.maxW_list = 80
plugin.tt_products.outputfolder = fileadmin/data
plugin.tt_products.color2 = #003399
plugin.tt_products.color1 = #FFFFFF
plugin.tt_products.wrap2 = <font face="verdana" size=2 color=white> | </font>
content.tableCellColor = #003399
Setup:
plugin.tt_products.code.field = select_key
plugin.tt_products.alwaysInStock = 1
plugin.tt_products.statusCodes.1 = Bestellungseingang
plugin.tt_products.statusCodes.11 = Der bananaSHOP wartet auf Ihren Zahlungseingang
plugin.tt_products.statusCodes.20 = Ihre Ware wird versendet
plugin.tt_products.statusCodes.101 = Bestellung abgeschlossen
plugin.tt_products.statusCodes.200 = Bestellung storniert
plugin.tt_products.orderEmail_from = info@bananaguard.de
plugin.tt_products.orderEmail_fromName = bananaGUARD.de
plugin.tt_products.orderEmail_to = info@bananaguard.de
orderNumberPrefix = order2005_
plugin.tt_products.discountGroupName = Team
plugin.tt_products.lockLoginUserInfo=true
plugin.tt_products.conf.tt_products.LIST.displayColumns = 3
plugin.tt_products.outputFolder = {$plugin.tt_products.outputfolder} plugin.tt_products {payment >
payment {radio = 1
TAXpercentage = 16
10.title = Vorkasse
20.title = PayPal
20.percentOfTotalShipping = 0.04
30.title = Nachnahme
30.discountDeactive = 1
30.price.1 = 4
30.price.6 = 5.8
30.showLimit = 99
}
shipping {radio = 1
TAXpercentage = 16
10.title = Deutschland
10.image.file =
10.price.type = count
10.price.1 = 2.5
10.price.6 = 4.8
10.price.50 = 10
10.price.100 = 25
10.price.120 = 30
10.price.300 = 150
10.percentOfGoodstotal = 0
20.title = Europa (nicht Deutschland)
20.image.file =
20.price.type = count
20.price.1 = 8.8
20.price.6 = 11.8
20.price.50 = 11.8
20.price.100 = 25
20.price.120 = 30
20.price.300 = 150
20.percentOfGoodstotal = 0
30.title = Selbstabholung
30.image.file =
30.price.1 = 0
30.percentOfGoodstotal = 0
}
pricecalc {type = count
field = price
10.prod.1 = 4.99
10.prod.2 = 8.99
10.prod.5 = 19.99
20.prod.1 = 6.99
20.prod.2 = 13.98
20.prod.5 = 29.99
}
discountprice {10.type = count
10.field = price 10.additive = 1
10.where =
10.prod.1 = 4.99
10.prod.100 = 2.89
10.prod.1050 = 2.77
20.type = count
20.field = price 20.where =
20.prod.1 = 6.99
20.prod.100 = 3.00
20.prod.1050 = 2.89
}
}
plugin.tt_products.basketImage.imageLinkWrap.height = 800
plugin.tt_products.listImage.file.maxW = 150
plugin.tt_products.shipping.40 >
plugin.tt_products.PIDagb =
plugin.tt_products.createUsers = 1
plugin.tt_products.orderEmail_htmlmail = 1
Plugin:
Products, CODE: LIST
The next pages are:
--- 'Shopping Basket'
Plugin:
Products, CODE: BASKET, At the BORDER a login content type with send to page 'Warenkorb'
--- 'Cash Box'
Plugin:
Products, CODE: PAYMENT, FINALIZE, INFO
--- 'Order Status'
Plugin:
Products, CODE: TRACKING
--- 'Invoicing'
Plugin:
Products, CODE: BILL
--- 'Delivery'
Plugin:
Products, CODE: DELIVERY
--- 'Articles' Sysfolder
Plugin:
Products, CODE: LIST
-- 'Contact/Order' contains a form, text and login
-- 'BananaINSIDER' only visible after frontend login, contains a login plugin at the right margin
Access of the visibility settings is the group 'Team'
--- 'My profile'
Plugin:
Frontend User Registration
--- 'INSIDER Infos'
--- 'bananaBOARD'
Plugin:
Board, Tree, CODE: FORUM, POSTFORM
-- 'Users'Sysfolder of the group 'Team'