X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Adding a line break to product title (https://forum.x-cart.com/showthread.php?t=47199)

joannet 04-27-2009 04:35 AM

Adding a line break to product title
 
Is it possible to add a line break to a product title via admin?

I want product titles to look neat and would like to be able to add a <br> to a product's name.

Can anyone please advice?

Thanks

RichieRich 04-28-2009 07:09 AM

Re: Adding a line break to product title
 
You can modify the /skin1/customer/main/product.tpl via the admin edit templates, search from the product-title and add a </ br> line-break.

balinor 04-28-2009 07:12 AM

Re: Adding a line break to product title
 
I think they mean adding a break in the actual title, which isn't possible as the product name can't accept html.

RichieRich 04-28-2009 07:42 AM

Re: Adding a line break to product title
 
How about possibly modify somehow to have after x letters line-break in the template?

joannet 04-28-2009 11:25 AM

Re: Adding a line break to product title
 
Thanks for your responses.

Yes, I am referring to the actual product title.

Is there a way to have it wrap after a certain number of characters, if html is not possible here?

RichieRich 04-28-2009 11:43 AM

Re: Adding a line break to product title
 
you can truncate the product title after a number of characters, this would be like "product tit..." so you would miss some letters. Otherwise there could be a smarty template method to achieve this

joannet 04-28-2009 11:45 AM

Re: Adding a line break to product title
 
Sounds great. Any idea of the code to use?

gb2world 04-28-2009 02:10 PM

Re: Adding a line break to product title
 
Maybe you could try putting the title in a fixed container width - then it will break when it does not fit in the container. Something like:

<div style="width:150px;">
<h2>This is a test title - if it does not fit in this div width - it will break to a new line</h2>
</div>

Jon 04-28-2009 02:21 PM

Re: Adding a line break to product title
 
^ Fixed div is the way to go.

joannet 04-28-2009 11:30 PM

Re: Adding a line break to product title
 
Thanks a lot.


All times are GMT -8. The time now is 06:39 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.