Closed (fixed)
Project:
XML sitemap
Version:
7.x-2.x-dev
Component:
xmlsitemap.module
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
15 Feb 2013 at 19:42 UTC
Updated:
16 Jul 2018 at 17:04 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
murzHow to reproduce:
And after this we will see in sitemap.xml:
Comment #2
murzI have solve this problem for me via this patch for function xmlsitemap_generate_chunk(stdClass $sitemap, XMLSitemapWriter $writer, $chunk) {
Comment #3
Anonymous (not verified) commentedComment #4
mh86 commentedEncountered the same issue (query parameter was encoded by url() and thus did not work any more).
Made a patch out of #2. Maybe there is a nicer way to do that.
Comment #5
mh86 commentedUpdated my patch. The $loc_query variable needs to be re-initialized on every iteration.
Comment #6
Anonymous (not verified) commentedYou misspelled the word "twice" in your comments as "twiche".
Comment #7
mh86 commented+ "Readd". Two typos in two comments ;-)
Thanks for that note. The patch needs an update.
Comment #8
Ari Linn commentedI've run into the same problem, so thanks for telling me where to look for the issue. However, I suggest using parse_url() to determine whether a url has a query part.
Comment #9
murz@Ari Linn, thanks for the hint, your version is more simple and works well. Here is updated patch with your version of solution. Please re-test it and commit to head.
Comment #10
wojtha commentedComment #11
ivan.lewas commentedWhat about hash attributes? So a link like this: node/50/#comment10 can be rendered correctly.
Comment #12
ULikeApples commentedUpdate patch for version "7.x-2.2"
Comment #14
firewaller commentedUpdate patch for version 7.x-2.3. Also leverages url() query and fragment keys with drupal_parse_url() rather than appending to string.
Comment #15
artem_sylchuk@firewaller thanks for a patch, it helped me a lot.
Unfortunately you've created a p0 patch and it should be p1, see: https://www.drupal.org/node/707484
Attached the updated patch version.
Comment #16
pifagor commentedComment #18
pifagor commentedComment #19
alex_optimLooks good
Comment #20
pifagor commentedPatch Failed to Apply, I recreate patch
Comment #22
pifagor commented