Author |
Topic |
|
daveycrockett
Starting Member
11 Posts |
Posted - April 10 2008 : 07:47:12
|
Hello all,
Please have a look at my extended product display:
http://lupicia-com-au.officialsitepreview.com/shop/shopexd.asp?id=13
Note its a work in progress, not everything is working as it should....
I cant figure out why the [SPECIAL_ORDERBUTTON] sub which generates the product features / quantity / order button is displaying them all in the centre?
I found code in shop$colors.asp which allowed me to tweak the positoin of the 3 elements but cant seem to find which code ?css is displaying this all in the centre.
Ideally I'd like the whole thing over on the left aligned with everything above, including the "Quantity" bit aligned to the left...
Here's the code from shop$colors I found and managed to tweak to get it looking better than it was before:
const Templatetable="<table cellspacing=""1"" cellpadding=""2"" border=""0"">" const TemplateQuantityRow="<tr>" const TemplateQuantityColumn="<td class=""ac"">Quantity" const TemplateQuantityColumnEnd="</td>" const TemplateButtonRow="<tr>" const TemplateButtonColumn="<td class=""ac"">" const TemplateCheckBoxRow="<tr>" const TemplateCheckboxColumn="<td>" const TemplateCheckBoxColumnEnd="</td>" const TemplateFeaturesRow="<tr>" const TemplateFeaturesColumn="<td class=""al"">" const TemplateFeaturesColumnEnd="</td>"
Hope someone can help, its starting to bug me!!!
Thanks,
Davey
|
|
carfin
VP-CART Expert
United Kingdom
948 Posts |
Posted - April 10 2008 : 09:09:39
|
Hi Davey,
have you had a look in the file tmp_product.htm to see where the [SPECIAL_ORDERBUTTON] code is placed in the table? Just open this file with a text or html editor and check that it is aligned left on that row.
Regards,
Carrol www.deanston-electrical.co.uk |
|
|
daveycrockett
Starting Member
11 Posts |
Posted - April 10 2008 : 22:03:04
|
Hi Carrol,
I wish it was that simple!
Seems to be something over-riding everything else.
I manages to align the Quantity to the left by changing the "ac" to "al" in the code on shop$colors but still as a whole it wants to sit in the centre, even if i force it into a separate table and align that table on the left!
I have noticed this behaviour with other "sub" type code, where it seems to have a mind of its own, and I would just love to know why and how to fix it!
Anyone out there can help, please do!
Thanks,
Davey
|
|
|
devshb
Senior Member
United Kingdom
1904 Posts |
Posted - April 11 2008 : 03:44:26
|
The SPECIAL_ORDERBUTTON templatefield does quite a lot; it might be that there are other html bits within it that are causing the alignment to go wrong. You could break it into smaller bits, try replacing the special_orderbutton with these instead in your product template (tmp_product.htm), then you can move them around a bit:
[add_formstart] [add_productfeatures] [add_quantity] [add_orderbutton] [add_product] [add_formend]
(take backups first)
Simon Barnaby Developer [email protected] www.BigYellowZone.com Web Design, Online Marketing and VPASP addons |
|
|
daveycrockett
Starting Member
11 Posts |
Posted - April 11 2008 : 08:31:28
|
Thanks Simon,
I feel like I'm getting closer.
But still confused.
When I played around with the smaller bits it certainly changed things, but in a rather bizarre way.
For example I inserted the text "Quantity" before [add_quantity] but the result was totally weird: it placed the word "Quantity" AFTER [add_quantity] and indeed after all the other [elements].
And for some reason it displayed everything way over on the left way outside the margins of the html code in my template.
Thats the bit that bugs me.
Can you tell me where the code is being generated from, I mean these bits such as [add_quantity] ... where are they in the code.. then perhaps i can get a handle on this?!
Thanks,
Davey
|
|
|
carfin
VP-CART Expert
United Kingdom
948 Posts |
Posted - April 16 2008 : 09:12:16
|
Hi Davey,
most of the subs for the templates are stored in shopfileio.asp eg
Sub Add_Button (ivalue, parsearray) (about line 890)
Sub Add_Quantity (ivalue, parsearray) (about line 950)
Regards
Carrol www.deanston-electrical.co.uk |
|
|
Trial_and_Error
Starting Member
36 Posts |
Posted - November 03 2008 : 18:16:37
|
Hello,
I have succeeded to add the word "quantity" in front of the quantity box in the template tmp_product.htm by adding the commands
[add_formstart] [add_productfeatures] [add_quantity] [add_orderbutton] [add_product] [add_formend]
as proposed by devshb. But I don't succeed in doiing the same for the productinvent_htm template. If I use the separate add commands as stated above, I don't appearing the check boxes with the different inventory products. Is there any additional "add" command to display the list of inventory products? Or is there another way to display the word "quantity" (or getlang langproductquantity) in front of the quantity box?
Thanks for any assistance.
Trial_and_error
|
|
|
Trial_and_Error
Starting Member
36 Posts |
Posted - November 04 2008 : 15:26:07
|
Hello,
I did find an acceptable solution.
I had to add [add_inventoryproducts] instead of [add_product].
Trial and Error |
|
|
|
Topic |
|