How to make characteristics align vertically

  • Posts: 34
  • Thank you received: 0
13 years 7 months ago #12978

Can someone help me to work out how to align characteristics in the product display page vertically rather the the default horizontal? In my case its a range of sizes.


David Craig
Hikashop 1.5.0 Business edition
www.charitycanvasprints.com

Please Log in or Create an account to join the conversation.

  • Posts: 34
  • Thank you received: 0
13 years 7 months ago #12980

Solved this myself!
1. Go to the Characteristics edit screen
2. Edit the value(s) of the characteristic
3. At the end of the 'name' field add '<br />'
4. If your using other languages, add the same to the name field on each language tab.

Note: Adding '<br />' to the name field in the 'Main Information' tab dosen't seem to get saved - Nicolas?


David Craig
Hikashop 1.5.0 Business edition
www.charitycanvasprints.com

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
13 years 7 months ago #12988

You will have to change the code:
$element->$column = strip_tags($value);

to:
$safeHtmlFilter = & JFilterInput::getInstance(null, null, 1, 1);
$element->$column = $safeHtmlFilter->clean($value, 'string');

in the file administrator/components/com_hikashop/classes/characteristic.php

Please Log in or Create an account to join the conversation.

  • Posts: 34
  • Thank you received: 0
13 years 7 months ago #13268

A more elegant solutions is to use CSS:

table.hikashop_product_characteristics_table label {
float:left;
clear:right;
font-weight:normal;
}

table.hikashop_product_characteristics_table .inputbox {
margin-top:5px;
margin-right: 10px;
float:left;
clear:left;
}

This does not affect the product title as the embedded <br /> does and no core code changed


David Craig
Hikashop 1.5.0 Business edition
www.charitycanvasprints.com

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
13 years 7 months ago #13270

Thank you for that solution, I'm sure it will help others.

Please Log in or Create an account to join the conversation.

Time to create page: 0.065 seconds
Powered by Kunena Forum