- Posts: 222
- Thank you received: 1
How can I display a short description?
Vero
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
I have added in this place:
<!-- PRODUCT NAME -->
<span class="hikashop_product_name">
<?php echo preg_replace('#<hr*id="system-readmore"*/>.*#is',",$this->row->product_description);?>
<?php if($this->params->get('link_to_product_page',1)){ ?>
P.S. I show my products in tabel and I wil under the product name to show a short description (listing_img_title)
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
(product listing_table)
In which place of file exactly have I to add this code?
Vero
Please Log in or Create an account to join the conversation.
I am not a prof. Can you, please, explain, in which place of file have I to add this code.
Vero
Please Log in or Create an account to join the conversation.
Where you have placed it was ok.
Had you an error returned ? (thanks to set the Joomla error reporting to maximum)
Please Log in or Create an account to join the conversation.
Xavier wrote: Hi,
Where you have placed it was ok.
Had you an error returned ? (thanks to set the Joomla error reporting to maximum)
I had no error message. Just my website was on white background, all the items in a row as a list, with other sizes and font family.
Vero
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
The problem is that you should not at it at the beginning or at the end of the listing_table file.
You should add the line
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Thanks to use this code:
Please Log in or Create an account to join the conversation.
Xavier wrote: Hi,
Thanks to use this code:Code:<?php echo preg_replace('#<hr*id="system-readmore"*/>.*#is','',$this->row->product_description); ?>
I don't understand what you mean. I use this code. That can you see on image. I have placed above 3 images. Sorry, but I don't understand.
Vero
Please Log in or Create an account to join the conversation.
It's not exactly the same code. Try this one instead of the one given by Nicolas and it should work
Please Log in or Create an account to join the conversation.
Who can I have just a short description in product listing? A short description has to be not a link. Links are image and the name of product. Because my link is of pink color, than is enough just the name us a link. A short description I wil in normal grey color. Others the all text pink is not nice and too much pink color.
Can you help me?
Vero
Vero
Please Log in or Create an account to join the conversation.
If you want the full description, then simply use that code instead:
<?php echo $this->row->product_description; ?>
Please Log in or Create an account to join the conversation.
nicolas wrote: The code proposed by Xavier will display the short description.
If you want the full description, then simply use that code instead:
<?php echo $this->row->product_description; ?>
I know that my Englisch is not good, I try again.
I wil only! short description on product listig table pages. With the code proposed by Xavier I have a short description + black line + a long description on those pages. So I have all! on those pages, but I wil only! a short description that is above the readmore link.
That is the image what I have now:
you see the black line and under this line the whole description is shown. I need only the first three lines of text and don't need this black line and the rest of the text under that line.
Please Log in or Create an account to join the conversation.
Please make sure that it uses:
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Here the right line, sorry about the first mistakes:
Please Log in or Create an account to join the conversation.