Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Dynamic SiteMap


Jack_mcs

Recommended Posts

Are they php files?  If not, that's why since the code only looks for php files. 

 

Jack

 

Just to add to Jacks statement...

I believe the contrib only looks into a couple of folders for these php's (boxes being one of them).

define('PROJECTS', 'Something that goes on forever!');

Link to comment
Share on other sites

  • 2 weeks later...

Hi, I had this installed and it was working great until i switched hosts. Everything remained the same such as subdomain name and so on. I made sure to chmodd the the cache folder and place set it up in the admin panel but it still doesn't work. Any help would be great. Here is the link to the site http://shop.westernstudios.net . Click on any product pic or category link and you will see what i mean. Thanks :)

Link to comment
Share on other sites

  • 2 weeks later...

Hi!

 

Would it be possible to display on the sitemap the current language file HEADBAR_TITLE value instead of the filenames (which are english, so not language specific and contain ugly underscores)? I guess there is something to be changed at:

 

		   $files['path'][] = $file;
	   $name = explode(".php", $file);
	   $files['name'][] = ucfirst($name[0]);

 

Any help would be greatly appreciated!

Link to comment
Share on other sites

Yes, this is possible and was suggested already. I plan to make the change but have not had the time. You'll just need to find where the current name is generated and replace it with the name of the page.

 

Jack

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

Well i think its a bit more difficult so that there should be a cycle to make all the necessary language files required. I didnt succed yet, is it the $file variant which contains the filenames from the catalog directory? Does it includes the extension (.php)? Another way could be to create a language file with the given names of the files displayed but of course its not automatic however seems simplier.

Link to comment
Share on other sites

Yes, it is the $file variable. The code involved is at the bottom of the includes/modules/dynamic_sitemap.php file.

 

Jack

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

I've uploaded a new version. It should display the file names in the proper language. Only the includes/modules/dunamic_sitemap.php file changed so you just need to copy that to upgrade.

 

Jack

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

Hello Jack,

 

I just tried your new version 1.5, but I have the following problem:

 

The links to the separate pages on the right of the sitemap show the wrong links for the description shown. It seems, that the wrong filename or the wrong pagetitle is used for every entry.

 

Do you have any ideas, what it could cause?

 

Thank you very much

 

 

Markus

Link to comment
Share on other sites

Can you provide more details please? For example, the link says bob but when you click on it it displays the sam page.

 

Jack

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

Hello Jack, thanks for your quick reply :-)

 

you got me right. But here are some more examples:

 

First link goes to advanced_search.php, but shows "New Products",

seceond then goes to "products_new.php", but shows "Privacy",

third goes to "privacy.php", but shows "Specials"

 

From this examples I would say that the first pagename is missing from the list and the others are "one down the list", but later this sequenz is changed. The change seems to start with a link to "index.php". After that, every pagename ist "down two lines the list".

 

I hope you understand what I mean.

 

Once again thanks for your help.

 

Markus

Link to comment
Share on other sites

In includes/modules/dynamic_sitemap.php, find this line

if (strpos($fp[$idx], "define('NAVBAR_TITLE'") !== FALSE)

and change it to

if (strpos($fp[$idx], "define('NAVBAR_TITLE") !== FALSE)

That will fix the alignment problem. But some of the titles may not be as you expect. Try changing it to

if (strpos($fp[$idx], "define('HEADIN_TITLE") !== FALSE)

The results might be better. Some of the pages should be added to the exclude list anyway though.

 

Jack

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

In includes/modules/dynamic_sitemap.php, find this line
if (strpos($fp[$idx], "define('NAVBAR_TITLE'") !== FALSE)

and change it to

if (strpos($fp[$idx], "define('NAVBAR_TITLE") !== FALSE)

Works great here, thanks!

 

Before submitting to searchengines I've applied Chemo's Ult SEF URL's v2.0b (because I'm hosting on Windows).

If I follow a link from the sitemap I'll end up in index.php?cPath=14.

How can I change dynamic_sitemap that it will show index.php?cName=audio-algemeen?

I discoverd this because MSN showed me many links in th cPath style wich is'nt good for ranking I think (duplicated pages) :huh:

 

TIA

Link to comment
Share on other sites

Before submitting to searchengines I've applied Chemo's Ult SEF URL's v2.0b (because I'm hosting on Windows).

If I follow a link from the sitemap I'll end up in index.php?cPath=14.

How can I change dynamic_sitemap that it will show index.php?cName=audio-algemeen?

I discoverd this because MSN showed me many links in th cPath style wich is'nt good for ranking I think (duplicated pages) :huh:

Jack,

I found out that the first categorie does show the SEO url but all sub-categories don't...

If you need a url I'll send it by PM.

Link to comment
Share on other sites

Oh My :o

More problems...

The last link in the sitemap points to the index instead of the related page.

If I follow a link in a sub-category the breadcrumbtrail isn't right anymore;

Instead of Home>>Audio>>Algemeen it shows Home>>Algemeen the categorybox stay's default (not showing the category you're in) and the url is index.php?cPath=14 instead of the cName like mentioned before :'(

 

Could anybody please help me despite my bad english?!?

Link to comment
Share on other sites

I'm not seeing the breadcrumb problem here. If you mouse over the link on the site map is the link correct? The url problem isn't a problem with this contribution. I will look at it eventually but no telling when. You may want to ask in the support thread for Ultimate SEO.

 

Jack

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

Check in the language file for that file and see what NAVBAR_TITLE is defined as. Any special characters? It uses that to build the link so that would effect it.

 

Jack

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

Jack,

In the non-dynamic version off another Sitemap contribution there's a solution for Ult. SEO URL's links in that sitemap.

I'm talking about this Sitemap contribution and the modification/solution datted 11 Mar 2005 by Chris LaRocque.

 

I'm a PHP noob so the source in the modified categorie_tree.php is not helping me at all.

Does it make sense to you?

Link to comment
Share on other sites

define('NAVBAR_TITLE', 'Nieuwe artikelen');
define('HEADING_TITLE', 'Nieuwe artikelen');

 

Nothing special there...

Find this line in the includes/modules/dynamic_sitemap.php file

$files['path'][] = $file;

and move it so that it is after this line

				$files['name'][] = ucfirst(substr($fp[$idx], $p_start + 1, $p_stop - $p_start - 1));

Does that fix it?

 

Jack

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

Thanks Jack!

Now the last link in the Sitemap is correct :thumbsup:

 

Hope that all links can point to Ult. SEO URL's also soon...

Did the sourcemodification in categorie_tree for Ult. SEO URL's made sense to you?

 

		 $this->data = array();
	 while ($categories = tep_db_fetch_array($categories_query)) {
		// Ultimate SEO URLs compatibility - Chemo
		# initialize array container for parent_id 
		$p = array();
		tep_get_parent_categories($p, $categories['parent_id']);
		# For some reason it seems to return in reverse order so reverse the array 
		$p = array_reverse($p);
		# Implode the array to get the parent category path
		$cID = (implode('_', $p) ? implode('_', $p) . '_' . $categories['parent_id'] :
		$categories['parent_id']);
		# initialize array container for category_id 
		$c = array();
		tep_get_parent_categories($c, $categories['categories_id']);
		# For some reason it seems to return in reverse order so reverse the array 
		$c = array_reverse($c);
		# Implode the array to get the full category path
		$id = (implode('_', $c) ? implode('_', $c) . '_' . $categories['categories_id'] :
		$categories['categories_id']);

	   $this->data[$cID][$id] = array('name' => $categories['categories_name'], 'count' => 0);
	 } // eof While loop
} //eof Function

Edited by osCshop
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...