No H1 tags showing up

For general questions and discussions specific to the AbleCommerce GOLD ASP.Net shopping cart software.
Post Reply
foodsleuth
Commander (CMDR)
Commander (CMDR)
Posts: 139
Joined: Wed Mar 31, 2010 8:59 pm

No H1 tags showing up

Post by foodsleuth » Sat Jun 10, 2017 5:28 am

Bing webmaster tools pointed out my product detail pages have no H1 tags. I checked the productpage.ascx and found the page header div, commented out. I removed the comment tags and I can see H1 tags on the page but the product name is not filling in. So when I view source I see this:
<div class="pageHeader">
<h1><span id="ctl00_ctl00_NestedMaster_PageContent_ctl00_ProductName" itemprop="name"></span></h1>

</div>

There should be the product name filled in next to itemprop-"name">

Any ideas?

Thanks

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: No H1 tags showing up

Post by jmestep » Sun Jun 11, 2017 11:40 pm

I don't know what version of Gold you are using, but one version has this in the ProductPage.ascx:

Code: Select all

	<h1><asp:Label ID="ProductName" runat="server" EnableViewState="false" itemprop="name"></asp:Label></h1> 

Then the name is populated in the ProductPage.ascx.cs

Code: Select all

  if(_Product != null)
            {
                ProductName.Text = _Product.Name;
..............
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

foodsleuth
Commander (CMDR)
Commander (CMDR)
Posts: 139
Joined: Wed Mar 31, 2010 8:59 pm

Re: No H1 tags showing up

Post by foodsleuth » Mon Jun 12, 2017 4:34 am

Hi Judy,
Thanks for the reply. As for my version, latest one except I have not put in: 9/8/2016
Service Release 1 for AbleCommerce Gold R12

It's interesting, in my code I see this: which means it's commented out.

if(_Product != null)
{
//ProductName.Text = _Product.Name;

I wonder why they would have commented this out? I guess I can uncomment both the sections that were commented out, see if it fixes it. Just hoping it does not create another problem.
Thanks again for the assist!
Barb

foodsleuth
Commander (CMDR)
Commander (CMDR)
Posts: 139
Joined: Wed Mar 31, 2010 8:59 pm

Re: No H1 tags showing up

Post by foodsleuth » Mon Jun 12, 2017 4:54 am

Ok, so kind of a good news / bad news thing. I un-commented out the affected areas and now I have h1 tags BUT my product name shows twice on the page which looks lame. I think I know why the developer did it, because of the way my page was customized. I'd think there would be a way to fix, I just don't know how.

If I 'inspect' the code where the first (proper placement) heading shows it shows this:
<span id="ctl00_ctl00_NestedMaster_PageHeader_StoreHeader_H_nameLabel">cascabel chiles </span>

Then, if I inspect where the H1 shows where it doesn't belong:
<span id="ctl00_ctl00_NestedMaster_PageContent_ctl00_ProductName" itemprop="name">cascabel chiles </span>

Any suggestions on how I might alter the code to put the h1 tag in the proper place?

Clearly, I'm not a developer but... I can cut and paste! :-)
Thanks
Barb

Post Reply