Latest News: (loading..)
Jack_mcs

Dynamic SiteMap

859 posts in this topic

This is the support thread for the Dynamic SiteMap contribution. Based on the SiteMap MS2 contribution, it allows the full shop to be automatically listed and updated dynamically.

 

Jack

 

Jack, are you saying that if I currently use SiteMap MS2, I can add this contribution and it will work correctly?

Share this post


Link to post
Share on other sites

Hi Jack,

 

Thanks for this contribution ! I did not have something as a sitemap in my shop yet and when I found yours this morning I thought it a good time to work on it rightaway.

I just installed it but (yes, there it is) I get a whole bunch of

Warning: strpos(): Empty delimiter. in /home/httpd/vhosts/wheeloftime.nl/httpdocs/osctest/includes/functions/dynamic_sitemap.php on line 35

at the top of my page.

After that I do see the sitemap but in the right column it all says things like

# About_us

# Account

# Account_edit

# Account_history

# Account_history_info

# Account_newsletters

etc.

Then at the end I find

Error!

Unable to determine the page link!

The only thing I can add right now is that the links in my information box are being repeated for a second time in the right column of the sitemap page. The second occurence is only partly as there seems to be the break.

 

I hope you can give me a clue where to look for !

 

Thanks,

Howard

Share this post


Link to post
Share on other sites
Jack, are you saying that if I currently use SiteMap MS2, I can add this contribution and it will work correctly?

You could instal them both if you renamed the link one of them adds to the information box but that is not a good idea since you would have two sitemap pages.

 

Jack

Share this post


Link to post
Share on other sites
Hi Jack,

 

Thanks for this contribution ! I did not have something as a sitemap in my shop yet and when I found yours this morning I thought it a good time to work on it rightaway.

I just installed it but (yes, there it is) I get a whole bunch of

Warning: strpos(): Empty delimiter. in /home/httpd/vhosts/wheeloftime.nl/httpdocs/osctest/includes/functions/dynamic_sitemap.php on line 35

at the top of my page.

After that I do see the sitemap but in the right column it all says things like

 

Then at the end I find

Error!

Unable to determine the page link!

The only thing I can add right now is that the links in my information box are being repeated for a second time in the right column of the sitemap page. The second occurence is only partly as there seems to be the break.

 

I hope you can give me a clue where to look for !

 

Thanks,

Howard

Some of the infoboxes should not be added to the sitemap and are automatically excluded by the code. But I built this on a standard shop so it cannot account for each setup. I have uploaded a changed version. Just copy the includes/modules/dynamic_sitemap.php file to your site. It will still fail but should give an error message at the top of the window indicating which infobox is causing the problem. You will then need to add that to the list of known boxes in that same file. That should eliminate the errors.

 

Jack

Share this post


Link to post
Share on other sites
Some of the infoboxes should not be added to the sitemap and are automatically excluded by the code. But I built this on a standard shop so it cannot account for each setup. I have uploaded a changed version. Just copy the includes/modules/dynamic_sitemap.php file to your site. It will still fail but should give an error message at the top of the window indicating which infobox is causing the problem. You will then need to add that to the list of known boxes in that same file. That should eliminate the errors.

 

Jack

 

Many thanks Jack ! I will get and try it immediately and let you know the outcome.

Share this post


Link to post
Share on other sites

Jack,

 

I installed the contribution just now and, clicking in the Site Map entry in the Information Box, I get the following message

 

Warning: strpos(): Empty delimiter. in /home/paradin/public_html/includes/functions/dynamic_sitemap.php on line 35

 

repeated a large number of times, presumably once for every product (although I haven't counted), followed by the SiteMap page (with Column_right which has disappeared), followed by "Error! Unable to determine the page link".

 

If you try the following link, you'll se what I mean

 

my shop

 

Nick

Share this post


Link to post
Share on other sites
Jack,

 

I installed the contribution just now and, clicking in the Site Map entry in the Information Box, I get the following message

 

Warning: strpos(): Empty delimiter. in /home/paradin/public_html/includes/functions/dynamic_sitemap.php on line 35

 

repeated a large number of times, presumably once for every product (although I haven't counted), followed by the SiteMap page (with Column_right which has disappeared), followed by? "Error! Unable to determine the page link".

 

If you try the following link, you'll se what I mean

 

my shop

 

Nick

 

@Nick:

Read above, I had a similar problem ! There is new version at the contribution section which helps solving this problem.

 

@Jack:

Although it didn't show me the name of the culprit infoboxes they were down to two and I figured them out by adding those I have extra one by one until resolved !

One thing stays:

Error!

 

Unable to determine the page link!

at the end of the page where it should list all links in my information box.

It goes until

# Information

 

? ? * Over Wheel of Time

? ? * Verzenden & Retourneren

? ? * Privacy verklaring

? ? * Algemene Voorwaarden

? ? * Neem contact op

? ? * Site Overzicht

? ? * Waar vindt u ons ?

? ? * WoTs FAQ

but I have three more links in there of which I assume one gives the error ?

After WoTs FAQ I have a <hr> tag (removed that to try if that caused the error but that didn't make any difference) followed by a link to my guestbook, ebay link and a Links link.

The link to my guestbook works and shows alright in between the links above the informatonbox section of the sitemap but it looks like it breaks the sitemap output.

Not sure though if that has anything to do with it ?!

Edited by wheeloftime

Share this post


Link to post
Share on other sites

Thanks Howard! I made the change, but I still get these three errors at the top of the page:

 

Invalid code for this module found in the following infobox: Pages

Invalid code for this module found in the following infobox:

Invalid code for this module found in the following infobox: Heading

 

The funny thing is that I don't have any infoboxes with the names of "Pages" or "Heading". Do these errors point to something elase? And what can be the meaning of the second error message?

 

I also get an incomplete "Information" sitemap, beginning with "About us" and missing everything else.

 

Nick

Share this post


Link to post
Share on other sites
Thanks Howard! I made the change, but I still get these three errors at the top of the page:

 

Invalid code for this module found in the following infobox: Pages

Invalid code for this module found in the following infobox:

Invalid code for this module found in the following infobox: Heading

 

The funny thing is that I don't have any infoboxes with the names of "Pages" or "Heading". Do these errors point to something elase? And what can be the meaning of the second error message?

 

I also get an incomplete "Information" sitemap, beginning with "About us" and missing everything else.

 

Nick

 

It seems we are encountering the same things...

I solved the infobox problem by adding my out of the ordinary infoboxes at the exception list you will find within the file catalog/includes/modules/dynamic_sitemap.php.

The names to add you have to pick from the php names you will find inside the boxes directory.

The incomplete Information sitemap part is still a puzzle for me also although I see most of them except the last three.

Share this post


Link to post
Share on other sites

Howard,

 

Did you pull the contribution? I cannot find a sitemap on your site.

 

Nick

Share this post


Link to post
Share on other sites
Howard,

 

Did you pull the contribution? I cannot find a sitemap on your site.

 

Nick

 

It's on my test shop. I'll PM you the address.

Share this post


Link to post
Share on other sites
@Nick:

Read above, I had a similar problem ! There is new version at the contribution section which helps solving this problem.

 

@Jack:

Although it didn't show me the name of the culprit infoboxes they were down to two and I figured them out by adding those I have extra one by one until resolved !

One thing stays:

 

at the end of the page where it should list all links in my information box.

It goes until

 

but I have three more links in there of which I assume one gives the error ?

After WoTs FAQ I have a <hr> tag (removed that to try if that caused the error but that didn't make any difference) followed by a link to my guestbook, ebay link and a Links link.

The link to my guestbook works and shows alright in between the links above the informatonbox section of the sitemap but it looks like it breaks the sitemap output.

Not sure though if that has anything to do with it ?!

The "Unable to determine the page link!" is coming becuase it is reading some link that is confusing it. It could be that the code used in your information boxes is different somehow than what I am testing for. If you will post the section of the information box that has the links in it, I will try it on my setup.

 

Jack

Share this post


Link to post
Share on other sites

I just installed the sitemap and get this error message:

 

"Error!

 

Unable to determine the page link!"

 

Anyone know how to get rid of that?

Share this post


Link to post
Share on other sites
I just installed the sitemap and get this error message:

 

"Error!

 

Unable to determine the page link!"

 

Anyone know how to get rid of that?

tip: read a thread before you post to it :-"

Share this post


Link to post
Share on other sites

@ Jack,

 

I hope the code I am attaching, from the catalog/includes/boxes/information.php is what you want to see. Please let me know if that is not the casae.

 

  $info_box_contents[] = array('text' => '<a href="' . tep_href_link(FILENAME_ABOUT_US) . '">' . BOX_INFORMATION_ABOUT_US .
                                        '</a><br>' .'<a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_PRIVACY) . '">' . BOX_INFORMATION_PRIVACY . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_CONDITIONS) . '">' . BOX_INFORMATION_CONDITIONS . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a><br>' .
'<a href="' . tep_href_link(FILENAME_DYNAMIC_SITEMAP) . '">' . BOX_INFORMATION_DYNAMIC_SITEMAP . '</a>');

 new infoBox($info_box_contents);

 

@ Howard,

 

I think that the right-hand column of entries in your Site map are pages which you may want to remove by adding them to the 2nd exclusion list in the catalog/includes/modules. I have removed mine in that way.

 

Nick

Share this post


Link to post
Share on other sites
The "Unable to determine the page link!" is coming becuase it is reading some link that is confusing it. It could be that the code used in your information boxes is different somehow than what I am testing for. If you will post the section of the information box that has the links in it, I will try it on my setup.

 

Jack

 

Jack,

 

The following I have in my information box:

  $info_box_contents[] = array('text' => '<a href="' . tep_href_link(FILENAME_ABOUT_US) . '">' . BOX_INFORMATION_ABOUT . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_PRIVACY) . '">' . BOX_INFORMATION_PRIVACY . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_CONDITIONS) . '">' . BOX_INFORMATION_CONDITIONS . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_DYNAMIC_SITEMAP) . '">' . BOX_INFORMATION_DYNAMIC_SITEMAP . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_FIND_US) . '">' . BOX_INFORMATION_FIND . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_MY_POINTS_HELP) . '">' . BOX_INFORMATION_MY_POINTS_HELP . '</a><br>' . //Points/Rewards module v1.10
                                        '<hr><a href="' . tep_href_link(FILENAME_GUESTBOOK) . '">' . BOX_INFORMATION_GUESTBOOK . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_EBAY) . '">' . BOX_INFORMATION_EBAY . '</a><br>' .
                                        '<a href="' . tep_href_link(FILENAME_LINKS) . '">' . BOX_INFORMATION_LINKS . '</a>');

It seems to break after BOX_INFORMATION_MY_POINTS_HELP although everything displays normally within the infobox itself.

Share this post


Link to post
Share on other sites
@ Howard,

 

I think that the right-hand column of entries in your Site map are pages which you may want to remove by adding them to the 2nd exclusion list in the catalog/includes/modules. I have removed mine in that way.

 

Nick

 

Nick,

 

Yes, I already took a couple of them out but I wanted to wait with the rest until the information thingie is working. There seems to be a whole lot which can go out.

 

Howard

Share this post


Link to post
Share on other sites

For both of the above problems, it is caused by the leading characters in the string.

 

Howard - Change this code

 '<a href="' . tep_href_link(FILENAME_MY_POINTS_HELP) . '">' . BOX_INFORMATION_MY_POINTS_HELP . '</a><br>' . //Points/Rewards module v1.10
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?'<hr><a href="' . tep_href_link(FILENAME_GUESTBOOK) . '">' . BOX_INFORMATION_GUESTBOOK . '</a><br>' .

to this

 '<a href="' . tep_href_link(FILENAME_MY_POINTS_HELP) . '">' . BOX_INFORMATION_MY_POINTS_HELP . '</a><br><hr>' . //Points/Rewards module v1.10
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?'<a href="' . tep_href_link(FILENAME_GUESTBOOK) . '">' . BOX_INFORMATION_GUESTBOOK . '</a><br>' .

 

Nicholas - Change this code

 $info_box_contents[] = array('text' => '<a href="' . tep_href_link(FILENAME_ABOUT_US) . '">' . BOX_INFORMATION_ABOUT_US .
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?'</a><br>' .'<a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a><br>' .

to

 $info_box_contents[] = array('text' => '<a href="' . tep_href_link(FILENAME_ABOUT_US) . '">' . BOX_INFORMATION_ABOUT_US . '</a><br>' .
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?'<a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a><br>' .

I made those changes after adding your code and it worked.

 

Jack

Edited by Jack_mcs

Share this post


Link to post
Share on other sites
For both of the above problems, it is caused by the leading characters in the string.

 

Howard - Change this code

 '<a href="' . tep_href_link(FILENAME_MY_POINTS_HELP) . '">' . BOX_INFORMATION_MY_POINTS_HELP . '</a><br>' . //Points/Rewards module v1.10
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?'<hr><a href="' . tep_href_link(FILENAME_GUESTBOOK) . '">' . BOX_INFORMATION_GUESTBOOK . '</a><br>' .

to this

 '<a href="' . tep_href_link(FILENAME_MY_POINTS_HELP) . '">' . BOX_INFORMATION_MY_POINTS_HELP . '</a><br><hr>' . //Points/Rewards module v1.10
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?'<a href="' . tep_href_link(FILENAME_GUESTBOOK) . '">' . BOX_INFORMATION_GUESTBOOK . '</a><br>' .

I made those changes after adding your code and it worked.

 

Jack

 

Jack,

 

I moved the <hr> tag to the previous line as you suggested and that indeed did seem to solve the problem. However the information box links are repeating themselves and at the second occurence the same error message comes up.

    * Information

          o Over Wheel of Time

          o Verzenden & Retourneren

          o Privacy verklaring

          o Algemene Voorwaarden

          o Neem contact op

          o Site Overzicht

          o Waar vindt u ons ?

          o WoTs FAQ

          o Gastenboek

          o Veilingen op eBay

          o Links

    * Information

          o Over Wheel of Time

          o Privacy verklaring

          o Algemene Voorwaarden

          o Verzenden & Retourneren

          o Neem contact op

o

 

Thanks for all your help !

Share this post


Link to post
Share on other sites

Howard - Are you sure you don't have two infomation.php files in the boxes directly like a copy named information_orig.php? The links are not showing the same so it appears to be reading two different boxes.

 

Nicholas - Great thanks for letting me know.

 

Jack

Edited by Jack_mcs

Share this post


Link to post
Share on other sites
Howard - Are you sure you don't have two infomation.php files in the boxes directly like a copy named information_orig.php? The links are not showing the same so it appears to be reading two different boxes.

 

Nicholas - Great thanks for letting me know.

 

Jack

 

Problem solved, you did put the hammer right on the nail !

I had a file called information.php.org in that directory (that's what I usually do to keep a safe copy) and after removing it altogether the erroneous second informationbox links dissapeared also.

 

Thanks for your time and efforts Jack, now I can clean it up a bit further and put it into the live shop !

Share this post


Link to post
Share on other sites

You're welcome. Actually, I had put a check in the code to make sure it only read php files but didn't think about the .php_orig type (which I use too). So I have uploaded a new version that will check for that. The only file changed is the modules/dynamic_sitemap.php file so that can just be copied over to install the update.

 

Jack

Share this post


Link to post
Share on other sites

Jack,

 

Thanks for a great contribution and for your help with the very few problems I've had installing it.

 

Regards

 

Nick

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