Click here to Skip to main content
12,253,371 members (52,341 online)
Rate this:
 
Please Sign up or sign in to vote.
See more: C# ASP.NET
Hello....

I am working at eCommerce web site, in this website i want to use sitemap but i couldn't. because i want to use dynamic site map. for example if user select any products than site map should be.

Home>>In-Ear Headphones

where In-Ear Headphones is a product type.

Note : there are at least 5000 produts.


Thanks in advance

Amit Vishwakarma
Posted 17-Nov-12 23:20pm
Edited 3-Dec-12 8:04am
v6
Comments
Developer Amit Vishwakarma 27-Nov-12 9:32am
   
Hi..Ali91Asadi

thanks for your suggestion,i have at least 5000 products and in future there are no limit than how to use that
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

1.Add SiteMapPath1 to pages
2.Add Web.sitemap to project
3.add code to Web.sitemap

<?xml version="1.0" encoding="utf-8" ?>
<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" >
    <siteMapNode url="~/Default.aspx" title="Home"  description="Home">
        <siteMapNode url="~/Default2.aspx" title="In-Ear Headphones"  description="In-Ear Headphones" />
    </siteMapNode>
</siteMap>
  Permalink  
Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 2

I think you need to use StaticSiteMapProvider[^] for that specific kind of job.

Here is an example link to get you started:

Building a dynamic SiteMap in ASP.NET 2.0 for a large website[^]

A bit more advanced technique is using LINQ with derive a class from StaticSiteMapProvider.

An example link:
Creating Dynamic ASP.NET SiteMap using LINQ[^]

Good luck,
OI
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy | Mobile
Web01 | 2.8.160426.1 | Last Updated 3 Dec 2012
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100