how to parse xml parser with many attributes
<p>This is my xml.. formate.</p>

<pre><code> &lt;events&gt;
    &lt;event id="237" title="HotFridayz" description="Club home / Amsterdam / N" date="17/12/2010" time="23:00 - 05:00" location="Club Nouvelle" street="Uilenstede 9-3018" city="Amstelveen" visitors="10" organisation="VSSA" price="13" minimum_age="" picture="" genre="Hip Hop" lineup="Dj Wily - Waxfiend" website=""/&gt;
    &lt;event id="238" title="Bassline" description="Jimmy woo/ Amsterdam / Nl" date="17/12/2010" time="23:55 - 03:00" location="P60" street="Katrijpstraat 126" city="Amsterdam" visitors="1000" organisation="first priority" price="15" minimum_age="" picture="" genre="Reggae" lineup="Chucky" website=""/&gt;
    ....
    ....
    ....
    &lt;/events&gt;
</code></pre>

<p>I worked on this code.....</p>

<pre><code>#import "XMLParser.h"
#import "PartyDemoProjectAppDelegate.h"
#import "CityInfo.h"

@implementation XMLParser
@synthesize currentElementValue;
@synthesize currentElement;

-(XMLParser *)initXMLParser{
    [super init];
    appDelegate = (PartyDemoProjectAppDelegate *)[[UIApplication sharedApplication] delegate];  
    return self;
}
- (void)parser:(NSXMLParser *)parser didStartElement:(NSString *)elementName 
  namespaceURI:(NSString *)namespaceURI qualifiedName:(NSString *)qualifiedName 
    attributes:(NSDictionary *)attributeDict{
    self.currentElement=elementName;
    currentElementValue=@"";
    if ([elementName isEqualToString:@"events"]) {
        appDelegate.cityInfoListArray=[[NSMutableArray alloc]init];

        return;
    }
    if ([elementName isEqualToString:@"event"]) {
    aCityInfo=[[CityInfo alloc] init];
    aCityInfo.event_ID=[attributeDict objectForKey:@"id"];
    aCityInfo.event_Title=[attributeDict objectForKey:@"title"];
    aCityInfo.event_Description=[attributeDict objectForKey=@"description"];
    }
}
- (void)parser:(NSXMLParser *)parser didEndElement:(NSString *)elementName 
  namespaceURI:(NSString *)namespaceURI qualifiedName:(NSString *)qName{
if ([elementName isEqualToString:@"events"]) {
    return;
}

    if ([elementName isEqualToString:@"event"]) {
        [appDelegate.cityInfoListArray addObject:aCityInfo];
        [aCityInfo release];
        aCityInfo=nil;
NSLog(@"Data",appDelegate.cityInfoListArray);
    }
}


- (void)parser:(NSXMLParser *)parser foundCharacters:(NSString *)string { 

//  currentElementValue =  [currentElementValue stringByAppendingString:string];
}

-(void)dealloc{

    [currentElementValue release];
    [currentElement release];
    [super dealloc];
}
@end
</code></pre>

<p>When i am printing in console
 NSLog(@"Data",appDelegate.cityInfoListArray);
It making iterations.......... </p>

<p>example:
Data &lt;0X1></p>

<p>Data &lt;0X1>
Data &lt;0X2></p>

<p>Data &lt;0x1>
Data &lt;0x2>
Data &lt;0x3>
......</p>

<p>I need to know this approach doing parsing is good?????</p>

<p>@Thanks in advance...........happy xmas... advance new year.. to all the people.</p>
