1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Links with & or ?

Discussion in 'Google Sitemaps' started by qwikad.com, Jun 25, 2017.

  1. #1
    I get an error when I try to add links containing & or ?. Is there a way to add those links anyway with a sitemap?
    SEMrush
    As an example:

    http:/ /somesite.com/index.php?search=&category
     
    qwikad.com, Jun 25, 2017 IP
    SEMrush
  2. John Martinez 2

    John Martinez 2 Greenhorn

    Messages:
    10
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    21
    Digital Goods:
    1
    #2
    You have to properly escape them - https://www.w3schools.com/html/html_entities.asp - i.e. you should use & instead of & in your URLs.

    You have to do the same think when you use them in HTML - so I recommend validating your website too - https://validator.w3.org/.
     
    John Martinez 2, Aug 14, 2017 IP
  3. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,615
    Likes Received:
    713
    Best Answers:
    150
    Trophy Points:
    420
    #3
    No, you don't. A sitemap is XML, which demands that you encode them. But HTML does NOT demand that. There is no harm in doing it, of course, but there is no demand for it.
     
    PoPSiCLe, Aug 15, 2017 IP