Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Header Tags SEO


Jack_mcs

Recommended Posts

Hmm, that's strange. I could see that happenning if it were loading in all of the categories/products but it is only loading six. I don't see anything wrong with the code though.

Jack. There isn't anything wrong with your code, it works perfectly. Since I have a large shop, I needed to reduce the amount of queries so the pages can load faster. On a much smaller shop the code is perfect. I have over a thousand categories. There was some code that was querying the DB for each category separately. The code that was suggested to me simplifies this.

 

Here's the suggested code for your viewing:

 $products_query = tep_db_query("SELECT pd.products_head_title_tag, p.products_id FROM " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c INNER JOIN " . TABLE_PRODUCTS_DESCRIPTION . " pd ON pd.products_id = p2c.products_id AND pd.language_id = '" . (int)$languages_id . "' INNER JOIN " . TABLE_PRODUCTS . " p ON p.products_id = p2c.products_id AND p.products_status = '1' WHERE p2c.categories_id = '" . (int)$catID . "' ORDER BY p.products_ordered LIMIT " . (int)$silo['max_links'] . "");

 

I was worried about losing possible buyers due to slow page loads. I imagine if I only had 25,000 products or less then the page load times would be minimal.

 

Thanks

Link to comment
Share on other sites

I have not been able to get product-specific information to populate title and meta tags (except Canonical) on my product info pages and would greatly appreciate help. I have seen past references to similar problems in this thread but have not found a solution after much searching. Here are the symptoms:

 

Header tags working perfectly on all index.php pages...including populating the category paths plus default tags. But on all product_info.php pages, I only get default and root tags to appear. I have checked my database using phpmyadmin and all header tags fields are populated for all products. I am checking my results by using "View Source" on my actual website. To keep things simple, for my HT SEO page control for product_info.php, I have these settings: Include Root (order 1), include Product (order 2). I typed in some root text for Description and that is the only data showing up in the meta tags, except...I also have the Canonical meta tags selected, and it is being populated perfectly with product-specific data.

 

I am using STS 4.5.2 and Ultimate SEO URLs. I had a working version of HTC 2.6.3 and followed all of the upgrade instructions step by step to go to HT SEO 3.0.0 all the way up to HT SEO 3.1.8. In my STS settings, I removed "headertags.php" from the files to be included box in admin. The STS "Product info" module is not installed because I use my "Default" sts template. My STS template does have "<!--$headcontent-->" in it.

 

Thanks in advance for any help!

-Mark

Link to comment
Share on other sites

I have not been able to get product-specific information to populate title and meta tags (except Canonical) on my product info pages and would greatly appreciate help. I have seen past references to similar problems in this thread but have not found a solution after much searching. Here are the symptoms:

Wow, impressive post. Thank you for being so specific. It sure beats the many "It's broke" type of posts. Hopefully others will take a hint. :)

 

As for the problem, I don't have an answer for you. It sounds like you covered all of the bases. If you type in something in the boxes for product_info in page control, which you said you did, and that shows up on the product page in the shop, then it would seem the basic code is working but it can't get the product data from the database. If you go to the products edit page in admin, are the title and meta tags boxes filled in? If not, then your code can't load the database correctly, or maybe the database isn't populated as you thought. Also, what are the results of the test function? And, lastly, I'm not sure that that version of STS is compatible with this contribution. It should be but I've never actually tried it so you will need to remove that as a possibility. To do that, add the header tags code to the head section of product_info.php and then turn STS off in admin. If the title and tags show up, the problem is with STS. Otherwise it is with the basic Header Tags code.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Wow, impressive post. Thank you for being so specific. It sure beats the many "It's broke" type of posts. Hopefully others will take a hint. :)

 

As for the problem, I don't have an answer for you. It sounds like you covered all of the bases. If you type in something in the boxes for product_info in page control, which you said you did, and that shows up on the product page in the shop, then it would seem the basic code is working but it can't get the product data from the database. If you go to the products edit page in admin, are the title and meta tags boxes filled in? If not, then your code can't load the database correctly, or maybe the database isn't populated as you thought. Also, what are the results of the test function? And, lastly, I'm not sure that that version of STS is compatible with this contribution. It should be but I've never actually tried it so you will need to remove that as a possibility. To do that, add the header tags code to the head section of product_info.php and then turn STS off in admin. If the title and tags show up, the problem is with STS. Otherwise it is with the basic Header Tags code.

 

Thanks for your quick response! I will try those things and report back.

- Mark

Link to comment
Share on other sites

Jack, thanks...I ran those tests. Here were my results:

 

Wow, impressive post. Thank you for being so specific. It sure beats the many "It's broke" type of posts. Hopefully others will take a hint. :)

 

As for the problem, I don't have an answer for you. It sounds like you covered all of the bases. If you type in something in the boxes for product_info in page control, which you said you did, and that shows up on the product page in the shop, then it would seem the basic code is working but it can't get the product data from the database. If you go to the products edit page in admin, are the title and meta tags boxes filled in? If not, then your code can't load the database correctly, or maybe the database isn't populated as you thought.

I went to the products edit page in admin, and all meta tags boxes were filled in with product-specific data as desired.

And, lastly, I'm not sure that that version of STS is compatible with this contribution. It should be but I've never actually tried it so you will need to remove that as a possibility. To do that, add the header tags code to the head section of product_info.php and then turn STS off in admin. If the title and tags show up, the problem is with STS. Otherwise it is with the basic Header Tags code.

Same result...title and tags did not have the product-specific data included. So it looks like the problem is not with STS.

Also, what are the results of the test function?

Here's where it gets weird. When I click on Test under Header Tags SEO in the left hand navigation column in admin, I get an incorrectly formatted header_tags_test.php screen, with this text at the top:

":html dir="ltr" lang="en"> :head> :meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> :title>osCommerce :link rel="stylesheet" type="text/css" href="includes/stylesheet.css"> :style type="text/css"> td.HTC_Head {font-family: Verdana, Arial, sans-serif; color: sienna; font-size: 18px; font-weight: bold; } td.HTC_subHead {font-family: Verdana, Arial, sans-serif; color: sienna; font-size: 12px; } .HTC_title {background: #fof1f1; text-align: center;} Transfer-Encoding: chunked 1B68 .popup { color: yellow; cursor: pointer; text-decoration: none } "

Also, it seems to be waiting for itself to load endlessly.

I do see the Test button, and if I click on it, I get an Internet Explorer error page: "The website cannot display the page - HTTP 500 Internal Server Error"

Edited by mballoun
Link to comment
Share on other sites

Here's where it gets weird. When I click on Test under Header Tags SEO in the left hand navigation column in admin, I get an incorrectly formatted header_tags_test.php screen, with this text at the top:

":html dir="ltr" lang="en"> :head> :meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> :title>osCommerce :link rel="stylesheet" type="text/css" href="includes/stylesheet.css"> :style type="text/css"> td.HTC_Head {font-family: Verdana, Arial, sans-serif; color: sienna; font-size: 18px; font-weight: bold; } td.HTC_subHead {font-family: Verdana, Arial, sans-serif; color: sienna; font-size: 12px; } .HTC_title {background: #fof1f1; text-align: center;} Transfer-Encoding: chunked 1B68 .popup { color: yellow; cursor: pointer; text-decoration: none } "

That kind of problem indicates a corrupted file. You should replace it with the one in the contribution. That makes me think too that maybe you didn't replace the files in your HTC installation. Some of the files are named the same but they are not the same. I suggest you upload the complete contents of the catalog directory. That only contains files specific to this contribution.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Sorry if this has been asked somewhere before in here, but I'm just wondering is it possible to add the default title tag for index.php after manufacturer and category titles?

 

Ie:

 

Widget Category 1 - Widget.com online store

 

Where "Widget.com online store" is set as the default title tag

 

instead of what I have currently:

 

Widget.com online store - Widget Category 1

 

Same for manufacturers list.

 

Thanks,

 

Grant

Link to comment
Share on other sites

Sorry if this has been asked somewhere before in here, but I'm just wondering is it possible to add the default title tag for index.php after manufacturer and category titles?

In Page Control->index.php, check the default title box and set the sort order to higher than the others.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

That kind of problem indicates a corrupted file. You should replace it with the one in the contribution. That makes me think too that maybe you didn't replace the files in your HTC installation. Some of the files are named the same but they are not the same. I suggest you upload the complete contents of the catalog directory. That only contains files specific to this contribution.

 

I checked all of my files and they are identical to the ones in the catalog folder from the download of HT SEO V3.1.8 (with the exception of catalog/includes/header_tags.php because it has been populated with some of my new pages by the admin tool). I deleted my copy of admin/header_tags_test.php and reloaded it from the original V3.1.8 copy just to be sure. Unfortunately still getting the above results. The results indicate that starting with line 573 in admin/header_tags_test.php, the first "<" character at the beginning of the next few lines is being replaced with ":". This always started on line 573, which should be <head> but it's getting corrupted into :head> Any ideas?

Link to comment
Share on other sites

This always started on line 573, which should be <head> but it's getting corrupted into :head> Any ideas?

No, I can't guess as to why it is failing like that. The contribution comes with a complete setup of files so I suggest uploading those (just the admin section). If it still fails, then there is something wrong with your shop/server. If not, you can replace your orginal files one at a time to isolate the reason.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

There are two sections in your shop: the shop side and the admin side. You can't mix the files. You mentioned earlier the problem was in the shop but now you are saying you are copying admin files. Copying files to the wrong place can cause the magic quotes problem. So you need to be sure you have the correct files in the correct place.

 

You can send me the language files if you like. I don't even try to maintain them, not knowing the language, so they probably wouldn't be accurate for long. The ones in the shop are small changes so that shouldn't really need it. The ones in admin would be nice though.

 

Ok maybe I wasn't clear, but thats what I was saying all along. There is no "header_tags_seo.php" in the catalog part of my file. In fact there is only catalog/includes/

No languages folder at all.

 

Can I suggest something so I don't waste your time any further? You PM me the right file (the header_tags_seo.php for the shop side [catalog/includes/languages/german]) AND the admin file that you yould like translated and hopefully we both will be happy :)

 

Thank you again so much for your patience!

Open Source Newsletter: PhPList

Open Source Questionnaire: Lime Survey

Link to comment
Share on other sites

No, I can't guess as to why it is failing like that. The contribution comes with a complete setup of files so I suggest uploading those (just the admin section). If it still fails, then there is something wrong with your shop/server. If not, you can replace your orginal files one at a time to isolate the reason.

 

Ok, I have made some progress. It turns out my version of the store did not have the tep_hide_session_id function defined in html_output.php. I added it and now I can use the test feature. Here is the result I am getting:

 

Database/File Mismatch Error:

The number of file entries in the database (27) does not match the number in the includes/header_tags.php file (26).

Files not in the includes/header_tags.php file:

allprods.php

Link to comment
Share on other sites

Ok maybe I wasn't clear, but thats what I was saying all along. There is no "header_tags_seo.php" in the catalog part of my file. In fact there is only catalog/includes/

No languages folder at all.

There aren't any language files on the shop side. All language entries are created on the admin side.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Ok, I have made some progress. It turns out my version of the store did not have the tep_hide_session_id function defined in html_output.php.

That's mentioned in the install instructions. Skipping instructions will cause such problems.

 

I added it and now I can use the test feature. Here is the result I am getting:

 

Database/File Mismatch Error:

The number of file entries in the database (27) does not match the number in the includes/header_tags.php file (26).

Files not in the includes/header_tags.php file:

allprods.php

Run the add missing pages option in page control or use the uninstall and install scripts.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

That's mentioned in the install instructions. Skipping instructions will cause such problems.Run the add missing pages option in page control or use the uninstall and install scripts.

 

Thanks Jack. I have everything cleaned up on the admin side now. I ran the database uninstall script and then the install script, and then repopulated all of my tags in the database, which I verified in phpmyadmin and looking at products in the catalog section of admin. Every product is populated with a title, meta keywords, and meta description. The Test tool reports no errors. I am still having my original problem of not seeing any of the product-specific tags in my product_info pages, which I am checking with View Source. I also noticed another symptom which may be helpful: my product titles are not showing up in the breadcrumb on product_info pages. Also, fyi here is my server info:

 

Server OS: SunOS 5.10 Database: MySQL 4.1.22-log

Server Date: 11/25/2009 11:09:51 Datebase Date: 11/25/2009 11:09:51

Server Up Time: up ??:?? load: 0.00 0.00 0.00

 

HTTP Server: ConcentricHost-Ashurbanipal/1.8 (XO® Web Site Hosting)

PHP Version: 4.4.8 (Zend: 1.3.0)

Link to comment
Share on other sites

There aren't any language files on the shop side. All language entries are created on the admin side.

 

OK, so why did I get this error message?

The error is saying it can't find the includes/languages/german/header_tags_seo.php.

And where EXACTLY is the file that I need to upload there?

Open Source Newsletter: PhPList

Open Source Questionnaire: Lime Survey

Link to comment
Share on other sites

I am still having my original problem of not seeing any of the product-specific tags in my product_info pages, which I am checking with View Source. I also noticed another symptom which may be helpful: my product titles are not showing up in the breadcrumb on product_info pages. Also, fyi here is my server info:

I don't have an answer for the first problem. I would need to look at the code for that. For the second, the breadcrumb is controlled by the code in the application_top file. Be sure that code has been changed.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

OK, so why did I get this error message?

 

And where EXACTLY is the file that I need to upload there?

There was such a file in the Header Tags Controller contribution. If you had that installed, then you've probably missed a step in the conversion.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Hi Jack,

I am new here.

Today I have installed Header Tags SEO.

And everything are good except http://www.bhl-trade.com/index.php?cPath=21 in my catalogue, i can't see product.

even the new catalogue I build http://www.bhl-trade.com/index.php?cPath=21

Therefore, i find those product link or catalog link from http://www.bhl-trade.com/products_new.php

Did you know why?

Or something wrong in my Index.php file or?

Link to comment
Share on other sites

And everything are good except http://www.bhl-trade.com/index.php?cPath=21 in my catalogue, i can't see product.

even the new catalogue I build http://www.bhl-trade.com/index.php?cPath=21

Therefore, i find those product link or catalog link from http://www.bhl-trade.com/products_new.php

Did you know why?

Or something wrong in my Index.php file or?

This contribution doesn't alter the url's so your problem is caused by something else.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

There was such a file in the Header Tags Controller contribution. If you had that installed, then you've probably missed a step in the conversion.

 

The original file in the Header Tags Contrib (2.6.3) in the folder \catalog\includes\languages\german is called "header_tags.php" and not "header_tags_seo.php" which is what the error message asks for...

I found no mentioning of that file anywhere in the Update from 2.6.3 to 3.0.0 Textfile.

Open Source Newsletter: PhPList

Open Source Questionnaire: Lime Survey

Link to comment
Share on other sites

I'm installing the Header Tags SEO contribution and see a reference to STS USERS ONLY and BTS USERS ONLY. How can I tell which is applicable to our installation?

For STS, there will be an includes/sts_templates directory. For BTS, there will be a templates directory.

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Hi jack,

 

i installed header tags seo (fresh install)

now afterwards i added dutch language in

catalog/inlcudes/languages/dutch

and the file catalog/includes/languages/dutch.php

but now when i hit the "update" button in admin->header tag

seo->page control->show all files i get a message that i don't

have permissions to access admin/header_ tags_seo.php - however

everything else seems to work, update in index.php update in

page control-show all files right column also, only left column

in header tags seo-page control-show all files not? help?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...