Re: possible bug in webView big and small load sizes...
Re: possible bug in webView big and small load sizes...
- Subject: Re: possible bug in webView big and small load sizes...
- From: "Stephen J. Butler" <email@hidden>
- Date: Fri, 2 Oct 2009 01:17:02 -0500
On Thu, Oct 1, 2009 at 6:17 PM, jon <email@hidden> wrote:
> DOMDocument *myDOMDocument = [[offScreeneBayWebView mainFrame]
> DOMDocument];
> DOMNodeList *allTableNodes = [myDOMDocument
> getElementsByTagName:@"table"];
> NSUInteger thelength1 = [allTableNodes length];
>
> DOMNode *node;
> DOMNode *att;
> NSString *attValue;
> DOMNamedNodeMap *attributes;
>
> for (i = 0; i < thelength1; ++i)
> {
> node = [allTableNodes item:i];
> attributes = [node attributes];
>
> att = [attributes item:0];
Does your table element have multiple attributes? The DOM Level 2
specification states that for NamedNodeMap there is no specified order
to the attributes. It could just be coincidence that the larger window
puts attributes in one order, and the smaller in another. If you know
the name of your attribute, why not just call:
attr = [attributes getNamedItem:@"someName"];
> attValue = [att nodeValue];
> if(attValue != nil)
> {
> isItInThere = [attValue rangeOfString:@"nol"];
>
> if (isItInThere.location != NSNotFound)
> //---------- this bothers me, what is the non negative way of asking this
> if statement?
> if (![attValue isEqualToString: @"cmpb nol"])
> {break;}
> }
> }
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden