Public class rss
{
Public string title;
Public string image_title;
Public string image_link;
Public string image_url;
Public string description;
Public string link;
Public string language;
Public string generator;
Public string ttl;
Public string copyright;
Public string pubdate;
Public string category;
Public rss ()
{}
Public rss (string stitle, string simage_title, string simage_link, string simage_url, string sdescription,
String slink, string slanguage, string sgenerator, string sttl, string scopyright, string spubdate, string scategory)
{
Title = stitle;
Image_title = simage_title;
Image_link = simage_link;
Image_url = simage_url;
Description = sdescription;
Link = slink;
Language = slanguage;
Generator = sgenerator;
Ttl = sttl;
Copyright = scopyright;
Pubdate = spubdate;
Category = scategory;
}
Public void create_xml (string filename, DataSet ds, string http)
{
XmlDocument doc = new XmlDocument (); // Add a header Node
XmlDeclaration delinoleic = doc. CreateXmlDeclaration ("1.0", "UTF-8", "no ");
Doc. AppendChild (decia );
XmlElement stitle = doc. CreateElement ("title ");
Stitle. InnerText = title;
XmlElement simage_title = doc. CreateElement ("title ");
Simage_title.InnerText = image_title;
XmlElement simage_link = doc. CreateElement ("link ");
Simage_link.InnerText = image_link;
XmlElement simage_url = doc. CreateElement ("url ");
Simage_url.InnerText = image_url;
XmlElement sdescription = doc. CreateElement ("description ");
Sdescription. InnerText = description;
XmlElement slink = doc. CreateElement ("link ");
Slink. InnerText = link;
XmlElement slanguage = doc. CreateElement ("language ");
Slanguage. InnerText = language;
XmlElement sgenerator = doc. CreateElement ("generator ");
Sgenerator. InnerText = generator;
XmlElement sttl = doc. CreateElement ("ttl ");
Sttl. InnerText = ttl;
XmlElement scopyright = doc. CreateElement ("copyright ");
Scopyright. InnerText = copyright;
XmlElement spubdate = doc. CreateElement ("pubdate ");
Spubdate. InnerText = pubdate;
XmlElement scategory = doc. CreateElement ("category ");
XmlElement image = doc. CreateElement ("image ");
XmlElement rss = doc. CreateElement ("rss ");
Doc. AppendChild (rss );
XmlAttribute version = doc. CreateAttribute ("version ");
Version. Value = "2.0 ";