Title Missing from Product Pages

  • Posts: 39
  • Thank you received: 0
13 years 1 day ago #31128

Hi,

Everything was working fine until recently. I have been adding new products without any problem, and then for some reason, every product that I added today is missing the product title at the top of the product page. I haven't made any changes to the code in any way in the meantime, so I don't think that's the issue.

Here is a page that I added last week:

bledsoe.cloudaccess.net/lavina-tooling/polish/nato.html

Here is a page that I just added today (title missing at the top):

bledsoe.cloudaccess.net/lavina-machines/edgers/lavina-7.html

I've played around with this all day, and I can't seem to figure out what I'm doing wrong... Help!

Thanks!

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

  • Posts: 82908
  • Thank you received: 13378
  • MODERATOR
13 years 21 hours ago #31148

Hi,

The problem probably comes from the span processing of your template. You should deactivate it and that will solve the problem.
If you use a Gantry based template, in the Gantry Control Panel for that template you should find the option called "Build Title Spans" that you should turn off.

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

  • Posts: 39
  • Thank you received: 0
13 years 2 hours ago #31230

I turned that off, but the titles are still missing on some of the pages, as before. Any other thoughts?

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

  • Posts: 82908
  • Thank you received: 13378
  • MODERATOR
12 years 11 months ago #31256

From what I can see it seems that there is just no name being displayed in the page because there is no name in the product or that you altered the view in some way that it wouldn't show the product name in some cases.
I don't have any other explanation.

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

  • Posts: 39
  • Thank you received: 0
12 years 11 months ago #31310

I went back and double-checked everything. I haven't made any changes to the code since adding the previous products (in which the titles are still being displayed). I also compared my product pages and menu items for each of these new items (without a product title) just to be sure I didn't enter anything differently. I do have a product name entered into the "product" section of HikaShop, so that cannot be the issue either. I also played around with the existing product titles by editing them, etc, and they are working fine. Do you have any other suggestions for correcting this? I am out of ideas...

Thanks!

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

  • Posts: 82908
  • Thank you received: 13378
  • MODERATOR
12 years 11 months ago #31330

You should try to revert the customization (make a backup of it before so that you don't loose your changes) you did in the file "show" of the view "product" vi the menu Display->Views.

There is a delete icon on the listing for that. If then you see all the product titles (which should be the case) it means that the problem comes from the customization you did.

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

  • Posts: 39
  • Thank you received: 0
12 years 11 months ago #31707

Hi,

It took a while, but I backed up and re-entered all of my customization. I'm not sure where I originally went wrong with the code, but it's corrected now. Thanks for the help!!!

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

  • Posts: 39
  • Thank you received: 0
12 years 11 months ago #32955

Hi. I am again having trouble with my titles. I just realized that they are again missing from some of my product pages. Before, to correct the problem, I deleted all of the customization from the product>show section. This brought back all of the titles. Then, when I went back into all of my previous posts, I again copied the instructions I was provided to rearrange the product page, and again some of the titles disappeared. These were the instructions that I was provided...is there something incorrect there? I can't figure out why they keep disappearing! Thanks!



That cannot be done via CSS.You need to edit the file "show" of the view "product" via the menu Display>Views and move the image block of code before the price block of code.

The image block of code is (for 1.5.4):
<div id="hikashop_product_image_main" >
<div id="hikashop_main_image_div" class="hikashop_main_image_div">
<?php
$image = null;
if(!empty($this->element->images)){
$image = reset($this->element->images);
}
if(!$this->config->get('thumbnail')){
if(!empty($image)){
echo '<img src="'.$this->image->uploadFolder_url.$image->file_path.'" alt="'.$image->file_name.'" id="hikashop_main_image" style="margin-top:10px;margin-bottom:10px;display:inline-block;vertical-align:middle" />';
}
}else{

$height = $this->config->get('thumbnail_y');
$style='';
if(!empty($this->element->images) && count($this->element->images)>1){
if(!empty($height)){
$style=' style="height:'.($height+5).'px;"';
}
} ?>
<div class="hikashop_product_main_image_thumb" id="hikashop_main_image_thumb_div" <?php echo $style;?> >
<?php echo $this->image->display(@$image->file_path,true,@$image->file_name,'id="hikashop_main_image" style="margin-top:10px;margin-bottom:10px;display:inline-block;vertical-align:middle"','id="hikashop_main_image_link"'); ?>
</div>
<?php }
?>
</div><div id="hikashop_small_image_div" class="hikashop_small_image_div"><?php
if(!empty($this->element->images) && count($this->element->images)>1){
foreach($this->element->images as $image){
echo $this->image->display($image->file_path,'hikashop_main_image',$image->file_name,'class="hikashop_child_image"');
}
}
?>
</div>
</div>



The price block of code is:
<span id="hikashop_product_price_main" class="hikashop_product_price_main">
<?php
if($this->params->get('show_price')){
$this->row =& $this->element;
$this->setLayout('listing_price');
echo $this->loadTemplate();
}
?>
</span>

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

  • Posts: 82908
  • Thank you received: 13378
  • MODERATOR
12 years 11 months ago #32975

That change is not related to your problem.

Did you change something around the lines below in that file ?

<span id="hikashop_product_name_main" class="hikashop_product_name_main">
<?php
echo $this->element->product_name;
?>
</span>

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

  • Posts: 39
  • Thank you received: 0
12 years 11 months ago #33169

Mine reads:

<span id="hikashop_product_name_main" class="hikashop_product_name_main">
<?php
echo $this->element->main->product_name;
?>
</span>
<span id="hikashop_product_code_main" class="hikashop_product_code_main">
<?php
echo $this->element->product_code;
?>
</span>

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

  • Posts: 82908
  • Thank you received: 13378
  • MODERATOR
12 years 11 months ago #33199

The code echo $this->element->main->product_name; will only display the name of the main product when you have characteristics for your product. If you don't have characteristics to your product, it won't display anything.

Please revert that modification and it will work properly.

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

  • Posts: 39
  • Thank you received: 0
12 years 11 months ago #33304

I made this change because I was under the impression that it would keep the main characteristic from appearing with the title (as it was before). This is what I'm looking for: I never want the characteristics to appear in the title, and I always want the title to appear. Can you please tell me what I should change that code to for reflecting these changes?

Thanks!!!

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

  • Posts: 82908
  • Thank you received: 13378
  • MODERATOR
12 years 11 months ago #33334

If you don't want the characteristics to appear in the product name, you can turn off the option "append characteristics values to product name" in the Display tab of the configuration.

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

  • Posts: 39
  • Thank you received: 0
12 years 11 months ago #33396

Thanks! You're the best! That seems to have fixed it!

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

Time to create page: 0.077 seconds
Powered by Kunena Forum