Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • LewisParkinson 9 posts 49 karma points
    Jan 11, 2022 @ 17:39
    LewisParkinson
    0

    ContentAtXPath() - "Error parsing NaN value. Path '', line 1, position 1."

    I have been using the following method on four websites (all using version 8.15.1) to get all pages that haven't been marked to be hidden from the sitemap and on one of the sites, I get the "Error parsing NaN value. Path '', line 1, position 1.", error. This has worked on this site before. But, I have checked recent changes and can't see anything that would affect this.

    IEnumerable<IPublishedContent> umbracoPages = Umbraco.ContentAtXPath("//*[./seoHideFromSitemap='0']")
                                                                    .OrderByDescending(p => p.UpdateDate);
    
                if (umbracoPages.Any())
                {
    
                }
    

    Has anyone got any ideas to why this would be happening?

Please Sign in or register to post replies

Write your reply to:

Draft