Creating
dynamic menu in asp using XML
Creating
dynamic menu in asp using xml is easy if you know how to get the data
from an xml file and also to create an xsl template that is used for the
menu. There are tools in the market that would help you to create a template
in xsl easily. Use tools like Visual Studio .Net or XMLSpy which are easy
in working with xsl files.
_______________________________________________
_______________________________________________
Tools
like XMLSpy also give an option to create an xsl file from the html file
you have. This makes your work easier instead of creating the template
from the scratch.
Extracting
data from xml files can be done by working with the xmldom object which
has the xml file loaded in it. Use the load method to load the xml file
to the xmldom object. If you want to display the content of the xml file
you can get the contents and use the xsl file for transforming them in
the way you want.
For creating
menus, all you need is the Text that is displayed and the hyperlink for
that text. The text and the hyperlink can be got from the xml file using
the xmldom object and the methods available in it.
Now the actual
job of displaying them like a menu is to work with your xsl template and
transform the data that you get from the xml file. You have to work like
in the Classic ASP, but in the ASP.Net you have the menu controls that
would make your job easier.
posted by Eugenia Loli-Queru on Mon 19th Nov 2001 19:44 UTC (New Mobile Computing) Today, OSNews features an interview with Zac Woodall, software design Engineer at Office Data and Developer Services at Microsoft Corporation . Zac, who is also a frequent OSNews reader, talks about the new Office, .NET, WindowsXP, NTFS and how it compares to BFS filesystem, the GPL & open source movement and much more.
FREE
Subscription
Subscribe to our mailing list and receive new articles
through email. Keep yourself updated with latest
developments in the industry.
Note
: We never rent, trade, or sell my email lists to
anyone.
We assure that your privacy is respected
and protected.
_______________________________________
Recommended
XML Books
|
|