Jump to content
Jack_mcs

Sitemap SEO

Recommended Posts

Do you know how to edit the following file includes/module/sitemap.php to get queries from TABLE_MANUFACTURERS_INFO with additional choice of correct language?

Share this post


Link to post
Share on other sites

Assuming you mean this line of code

 $manufacturers_query = tep_db_query("select manufacturers_id, manufacturers_name from " . TABLE_MANUFACTURERS . " order by manufacturers_name");

you could try this

 $manufacturers_query = tep_db_query("select m.manufacturers_id, m.manufacturers_name from " . TABLE_MANUFACTURERS . " m left join " . TABLE_MANUFACTURERS_INFO . " mi on m.manufacturers_id = mi.manufacturers_id and mi.languages_id = '" . (int)$languages_id . "' order by manufacturers_name");

 

Jack

Share this post


Link to post
Share on other sites

Ok, its good for default language, but in other languages it still show manufacturers in default lang.

 

How change code:

 

$manufacturers_query = tep_db_query("select m.manufacturers_id, m.manufacturers_name from " . TABLE_MANUFACTURERS . " m left join " . TABLE_MANUFACTURERS_INFO . " mi on m.manufacturers_id = mi.manufacturers_id and mi.languages_id = '" . (int)$languages_id . "' order by manufacturers_name");

 

so as to use only TABLE_MANUFACTURERS_INFO?

Share this post


Link to post
Share on other sites

Hi Jack,

 

It seems I messed something up on the installation. I tried searching for a similar error but didn't find anything. :blush:

 

As soon as I go to - Admin > Sitemap SEO I receive this error message:

 

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home3/handesho/public_html/admin/includes/functions/sitemap.php on line 302

Line 302 = chdir ($path);

--EDIT--

Also when I clicked on Box Control I recieved this error:

 

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home3/handesho/public_html/admin/includes/functions/sitemap.php on line 18

 

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home3/handesho/public_html/admin/includes/functions/sitemap.php on line 185

 

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home3/handesho/public_html/admin/includes/functions/sitemap.php on line 167

Lines reference = chdir ($locn);

Any idea what I did wrong?

 

:blink:

Edited by jhande

- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Share this post


Link to post
Share on other sites

This may seem strange but maybe it will help figure out what I screwed up??

 

Now when I click on Admin > Catalog I receive this error message:

 

Error: Catalog images directory does not exist: /images/

 

It's there, so I don't know what's boogered besides me being on Percocets. :unsure:


- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Share this post


Link to post
Share on other sites
Hi Jack,

 

It seems I messed something up on the installation. I tried searching for a similar error but didn't find anything. :blush:

 

As soon as I go to - Admin > Sitemap SEO I receive this error message:

 

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home3/handesho/public_html/admin/includes/functions/sitemap.php on line 302

It's saying it can't find the file. Are you sure you uploaded the new files? Is there a sitemap.php file in the admin/includes/functions directory?

 

Jack

Share this post


Link to post
Share on other sites
It's saying it can't find the file. Are you sure you uploaded the new files? Is there a sitemap.php file in the admin/includes/functions directory?

 

Jack

 

Yes, the file is there with permission of 644.


- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Share this post


Link to post
Share on other sites

Could it have anything to do with my site being installed in the root and not catalog folder?

 

Maybe a setting in my configure.php files?

 

Admin:

define('HTTP_SERVER', 'http://handeshobbies.com'); // eg, [url="http://localhost"]http://localhost[/url] or - [url="https://localhost"]https://localhost[/url] should not be NULL for productive servers
 define('HTTP_CATALOG_SERVER', 'http://handeshobbies.com');
 define('HTTPS_CATALOG_SERVER', 'https://secure.bluehost.com/~handesho');
 define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog module
 define('DIR_FS_DOCUMENT_ROOT', $DOCUMENT_ROOT); // where your pages are located on the server. if $DOCUMENT_ROOT doesnt suit you, replace with your local path. (eg, /usr/local/apache/htdocs)
 define('DIR_WS_ADMIN', '/admin/'); // Used to be /catalog/admin/
 define('DIR_FS_ADMIN', DIR_FS_DOCUMENT_ROOT . DIR_WS_ADMIN);
 define('DIR_WS_CATALOG', '/'); // Used to be /catalog/
 define('DIR_FS_CATALOG', DIR_FS_DOCUMENT_ROOT . DIR_WS_CATALOG);
 define('DIR_WS_IMAGES', 'images/');
 define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
 define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');
 define('DIR_WS_INCLUDES', 'includes/');
 define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
 define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
 define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
 define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
 define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
 define('DIR_WS_CATALOG_LANGUAGES', DIR_WS_CATALOG . 'includes/languages/');
 define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
 define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
 define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
 define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');


- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Share this post


Link to post
Share on other sites

I'm sorry. The error isn't saying it can't find that file. It is saying it can't find the one it is trying to change to. That could be caused by your configure file. Try changing

define('DIR_FS_DOCUMENT_ROOT', $DOCUMENT_ROOT);

to

/home3/handesho/public_html/

 

Jack

Share this post


Link to post
Share on other sites
I'm sorry. The error isn't saying it can't find that file. It is saying it can't find the one it is trying to change to. That could be caused by your configure file. Try changing
define('DIR_FS_DOCUMENT_ROOT', $DOCUMENT_ROOT);

to

/home3/handesho/public_html/

 

Jack

 

Thank you, thank you, thank you! :D

 

You the man Jack!!! ;)

 

I appreciate your help as always.

 

Me thinks it's recovery time for me before I mess with anything else.

Percocets may take the pain away, but they sure mess up other things LOL. :wacko:

 

Hope you have a good weekend.


- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Share this post


Link to post
Share on other sites

You're welcome. I'm glad you got it working even with my mistake. But for anyone following this that has the same problem, I should have said to change this

define('DIR_FS_DOCUMENT_ROOT', $DOCUMENT_ROOT);

to this

define('DIR_FS_DOCUMENT_ROOT', '/home3/handesho/public_html/');

 

Jack

Share this post


Link to post
Share on other sites

When I went to the catalog side and loaded the Sitemap page I noticed there was no pageHeading.

I checked other files and noticed that line 192 of the sitemap.php file was different.

 

Sitemap.php:

<?php echo $settings['heading_title']; ?>

Product_info.php

<?php echo HEADING_TITLE; ?>

So I changed it to match product_info.php and the pageHeading now appears.

You made mention that I didn’t setup Sitemap SEO properly.

What have I screwed up now, any ideas?


- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Share this post


Link to post
Share on other sites

It's not a matter of doing something wrong. You just didn't set it up, or that's what it sounds like, at least. Go to admin->Sitemap SEO->Settings Control and enter in the names of the section headings that you are going to use.

 

Jack

Share this post


Link to post
Share on other sites
It's not a matter of doing something wrong. You just didn't set it up, or that's what it sounds like, at least. Go to admin->Sitemap SEO->Settings Control and enter in the names of the section headings that you are going to use.

 

Jack

 

Oh my God I'm so retarded!

 

Thank you so much Jack for putting up with me and my ignorance lately. :blush:

 

settingscontrol.gif

 

DUH... :(

 

Me thinks it's time to go fishing.


- :: Jim :: -

- My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -

Share this post


Link to post
Share on other sites

Hi all

first, thanks for the great contrib.

 

Just some questions.Using sitemap SEO 1.2.

 

in my english version of the site

 

http://www.kupuvalnik.com/sitemap.php?language=en

 

i can see EVERY subpage listed in the map. Please note the top of the right column. ther are

 

Advanced Search

Conditions

Contact Us

Index

Privacy

Product Info

.

.

.

 

in my bulgarian version of the site

 

http://www.kupuvalnik.com/sitemap.php?language=bg

 

some subpages are missing: again see top of the right column. the missing pages are the above ones.

 

Any help welcome.

Thanks.


OSC beginner

Share this post


Link to post
Share on other sites

Since you haven't made any changes to settings control, my guess is that that language isn't filled in properly in the page control section either. Have you tried looking at that section for bulgarian?

 

Jack

Share this post


Link to post
Share on other sites
Since you haven't made any changes to settings control, my guess is that that language isn't filled in properly in the page control section either. Have you tried looking at that section for bulgarian?

 

Jack

 

 

sorry could you make this a bit clearer, you lost me.....

thanks a lot


OSC beginner

Share this post


Link to post
Share on other sites
sorry could you make this a bit clearer, you lost me.....

thanks a lot

- go to admin and login

- click on Sitemap SEO in the left column

- click on Page Control in the left column

- scroll to the bottom of the page and click update after verifying all of your languages are displayed

- click on Box Control in the left column

- select any box from the dropdown in the Boxes Individual Control section

- click update once that box loads

- click on Settings Control in the left column

- Fill in the various headings for all languages in use

- go to the configuration group

- click on Sitemap SEO

- change the settings to what you want

 

Jack

Share this post


Link to post
Share on other sites

Hi Jack,

 

Can I please ask why I am unable to exclude the following:

 

* Checkout Success

* Create Account Success

* Product Reviews Info

* Product Reviews Write

* Product Reviews

* Reviews

* Shopping Cart

* Ssl Check

* Tell A Friend

 

I ticked the box for each one but when I update it the ticks disappear and they still show in the site map.

 

Also if I click the information in Boxes Individual Control the page goes blank and all you see is the url at the top

 

Sue

Edited by a12c4magic

Share this post


Link to post
Share on other sites

What version of the contribution are you using? What version of php/mysql are you using?

 

Jack

Edited by Jack_mcs

Share this post


Link to post
Share on other sites

Hi Jack I am using the following versions

 

contribution version is 1.4

Php version 5

Mysql version 5

Apache version 2.2

Share this post


Link to post
Share on other sites
Hi Jack I am using the following versions

 

contribution version is 1.4

Php version 5

Mysql version 5

Apache version 2.2

It's working fine under those versions here. You said you can't exclude certain pages. What about other pages? Can exclude any? The problem with the page going blank indicates a problem with the code in the box file. Does it do for all of your boxes? Are you running a standard oscommerce shop or one of the forks?

 

Jack

Share this post


Link to post
Share on other sites
- go to admin and login

- click on Sitemap SEO in the left column

- click on Page Control in the left column

- scroll to the bottom of the page and click update after verifying all of your languages are displayed

- click on Box Control in the left column

- select any box from the dropdown in the Boxes Individual Control section

- click update once that box loads

- click on Settings Control in the left column

- Fill in the various headings for all languages in use

- go to the configuration group

- click on Sitemap SEO

- change the settings to what you want

 

Jack

 

that worked

thanks a lot.


OSC beginner

Share this post


Link to post
Share on other sites

Jack I have a question for you or whoever can explain this to me. I believe there is a table missing ('sitemap_seo_exclude')

 

In includes/database_tables.php you have:

 

ADD:
 /***** Begin Sitemap_SEO *****/
 define('TABLE_SITEMAP_SEO_BOX_LINKS', 'sitemap_seo_box_links');
 define('TABLE_SITEMAP_SEO_BOXES', 'sitemap_seo_boxes');
 define('TABLE_SITEMAP_SEO_EXCLUDE', 'sitemap_seo_exclude');
 define('TABLE_SITEMAP_SEO_PAGES', 'sitemap_seo_pages');
 define('TABLE_SITEMAP_SEO_SETTINGS', 'sitemap_seo_settings');
 /***** End Sitemap_SEO *****/

 

BUT THEN HOWEVER IN sitemap_seo.sql you have:

 

DROP TABLE IF EXISTS sitemap_seo_pages;
CREATE TABLE sitemap_seo_pages (
exclude_id INT NOT NULL AUTO_INCREMENT ,
page_file_name VARCHAR (255) NOT NULL ,
alternate_page_name VARCHAR (255) NOT NULL DEFAULT '',
anchor_text VARCHAR (255) NOT NULL DEFAULT '',
excluded_page TINYINT (1) NOT NULL DEFAULT 0,
registered_only TINYINT (1) NOT NULL DEFAULT 0,
sort_order TINYINT (3) NOT NULL DEFAULT 0,
language_id int DEFAULT '1' NOT NULL,
PRIMARY KEY ( exclude_id )
);

DROP TABLE IF EXISTS sitemap_seo_boxes;
CREATE TABLE sitemap_seo_boxes (
box_file_name VARCHAR (50) NOT NULL DEFAULT '',
box_page_name VARCHAR (255) NOT NULL DEFAULT '',
pseudo_page_name VARCHAR (255) NOT NULL DEFAULT '',
excluded_box TINYINT (1) NOT NULL DEFAULT 0,
registered_box TINYINT (1) NOT NULL DEFAULT 0,
language_id int DEFAULT '1' NOT NULL,
PRIMARY KEY ( box_file_name, language_id )
);

DROP TABLE IF EXISTS sitemap_seo_box_links;
CREATE TABLE sitemap_seo_box_links (
box_link_id INT NOT NULL AUTO_INCREMENT,
box_file_name VARCHAR (50) NOT NULL DEFAULT '',
page_link_name VARCHAR (255) NOT NULL DEFAULT '',
pseudo_page_link_name VARCHAR (255) NOT NULL DEFAULT '',
anchor_text VARCHAR (255) NOT NULL DEFAULT '',
excluded_link TINYINT (1) NOT NULL DEFAULT 0,
registered_link TINYINT(1) NOT NULL DEFAULT 0,
sort_order TINYINT (3) NOT NULL DEFAULT 0,
language_id int DEFAULT '1' NOT NULL,
PRIMARY KEY ( box_link_id )
);

DROP TABLE IF EXISTS sitemap_seo_settings;
CREATE TABLE sitemap_seo_settings (
enable_articles_manager TINYINT (1) NOT NULL DEFAULT 0,
enable_infopages TINYINT (1) NOT NULL DEFAULT 0,
enable_page_manager TINYINT (1) NOT NULL DEFAULT 0,
heading_title VARCHAR (40) NOT NULL DEFAULT 'Site Map',
heading_sub_text TEXT NOT NULL,
heading_articles_manager VARCHAR (50) NOT NULL DEFAULT '',
heading_categories VARCHAR (50) NOT NULL DEFAULT '',
heading_infopages VARCHAR (50) NOT NULL DEFAULT '',
heading_manufacturers VARCHAR (50) NOT NULL DEFAULT '',
heading_page_manager VARCHAR (50) NOT NULL DEFAULT '',
heading_standard_boxes VARCHAR (50) NOT NULL DEFAULT '',
heading_standard_pages VARCHAR (50) NOT NULL DEFAULT '',
language_id int DEFAULT '1' NOT NULL,
PRIMARY KEY ( language_id )
);

....

// INSERT QUERIES

 

So my question is where do you create 'sitemap_seo_exclude' as referred in includes/database_tables.php???

 

I am not able to exclude any pages therefore I am wondering if this may be the cause please let me know what does table 'sitemap_seo_exclude' suppose to contain.

 

Thanks

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×