Jump to content

Modifying Product.tpl have not effect


Recommended Posts

Hi everybody,

 

I'll do my best to write a good english (I'm French), but I'm sorry if I write with some mistakes.

 

I want to had a simple text (like "hello") just below the price of a product in my shop.

I've check with my friend Google who told me to change the file "Product.tpl". I did, and, at line 301, I wrote:

<p>Hello</p>

.

 

But nothing append. Of course, I "unchecked" the cache's box in the preferences.

 

Could any of you help me ? :)

 

Thanks in advance !

 

 

Julian

Link to comment
Share on other sites

Hi,

 

Sorry to answer so late, I didn't check for new post !

Thanks for your help, it's working.?

 

Although, I still have a little problem with attributes on a product. Let me explain:

I've got a product with differents choices (attributes) and I'd like to write some text under the price if one option is taken in a dropdownlist.

 

Example (because I'm not sure that you can understand me right now :) )

I've got a Jeans to sell, and customers can choose between 3 sizes (S, M, L).

I'd like, when the customers choose, let say, the size "M", that the line "M is the size" goes under the price ?

 

I've tried a lot of things, and I'm not sure anymore if I have to change something in product.tpl or product.ps or both. A bit confused, and I hope you coule help me a bit on it :rolleyes:

 

Thanks anyway for your previous post !

 

 

Julian

Link to comment
Share on other sites

Hello !

 

Thanks for your answer.

I've been to there (on product.tpl):

<select name="{$groupName}" id="group_{$id_attribute_group|intval}" onchange="javascript:findCombination();javascript:test();{if $colors|@count > 0}$('#wrapResetImages').show('slow');{/if};">

 

But I don't understand how to write something in Javascript and that it can "understand" where to put the text.

In fact, I don't know how to tell him, in javascript: "Put the text I want here".

 

For product.js, I'm here:

Function test()
{
style.display = "" ;
}

 

 

I presume that javascript is working with id but I'm not sure how. Could you help me with this (I promise: I'm looking on Google too :-) )

Link to comment
Share on other sites

Done !

 

I've just put this line in product.tpl:

<div id="leprix" style="color: red; font-size: small;"></div>

 

And those in product.ps:

document.getElementById('leprix').innerHTML="Hello World!";

 

Quite easy finally!

 

Thanks for you both who helped me !

 

 

Hum... How to mark 'SOLVED' this post ?

Link to comment
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
×
×
  • Create New...