Link to home
Start Free TrialLog in
Avatar of ANAT2403
ANAT2403Flag for Israel

asked on

convert a sitemap file to xmlfile

In asp.net 2.0 with C#
I have a sitempafile that I want to convert to a regular XML file.
How do I do it?
Anat
Avatar of slado2
slado2

Sitemap is a regular XML file. You don't have to convert it. Maybe just define <?xml...> declaration at the beginning.
ASKER CERTIFIED SOLUTION
Avatar of McExp
McExp
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ANAT2403

ASKER

what about the line:
<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" >
I have another sitempa in the project and I don't want to get mixed
anat
That is the xml namespace it features in many XML files what do you mean by don't want to get mixed?
Namespace declaration is fine however the sitemap file is always xml. Regardless of xmlns declaration. You don't need to convert it to validate whether it is correct xml. If you want to validate it against schema, you will have to add the xmlns as you posted before.
for mor info on the purpose of this attribute: -

http://www.w3schools.com/xml/xml_namespaces.asp