donb because passing xml can be much smaller then passing the data
with html wrapped around it.

On May 17, 6:41 pm, donb <falconwatc...@comcast.net> wrote:
> I can't figure out why you want to pass data in a non-usable format so
> you have to whack away at it with lots of code to turn it into what
> you need. Why not generate what you need to start with, so the task is
> reduced to simply requesting a chunk of html and inserting it into the
> DOM.
>
> On May 17, 3:09 pm, KrushRadio - Doc <drega...@gmail.com> wrote:
>
> > Hey Guys/Gals,
>
> > I have been able to use JQuery in the past, for simple things, and
> > after much hacking around, i have been able to get it to work.  I want
> > to embrace this technology, but I can't get past the examples.
> > They're very basic, and I can't wrap my head around how to move them
> > into real world scenarios.  I'm a dev, but not a javascript dev.  I
> > mean, i know how to do this in Javascript, using xpath and filters,
> > but i really want to use JQuery as the engine, to keep it consistant
> > with the rest of the project.
>
> > using Javascript, I would just do a
> > var tDay = Document.DOM.selectSinglenode("/schedule/day
> > [...@name="Monday"])
> > and then loop thru there and list out everything into my table, and
> > display the html
>
> > But i want to do this using JQuery.
>
> > Here is the sample xml:
>
> > <schedule>
> >         <day name="Monday">
> >                 <show>
> >                         <time>0800-1000</time>
> >                         <dj>nonstop rock</dj>
> >                         <showname>nonstop music</showname>
> >                 </show>
> >                 <show>
> >                         <time>1000-1200</time>
> >                         <dj>nonstop rock</dj>
> >                         <showname>nonstop music</showname>
> >                 </show>
> >         </day>
> >         <day name="Tuesday">
> >                 <show>
> >                         <time>0800-1000</time>
> >                         <dj>nonstop rock</dj>
> >                         <showname>nonstop music</showname>
> >                 </show>
> >                 <show>
> >                         <time>1000-1200</time>
> >                         <dj>nonstop rock</dj>
> >                         <showname>nonstop music</showname>
> >                 </show>
> >                 <show>
> >                         <time>1200-1400</time>
> >                         <dj>nonstop rock</dj>
> >                         <showname>nonstop music</showname>
> >                 </show>
> >         </day>
> > </schedule>
>
> > So, here's what i want to see... I can understand the code when i see
> > it, but i'd like to see the specific code.
> > So, the first part would be to isolate the attribute of "name" for the
> > "day" element,
> > Then how it loops thru each 'show' element, and find the 'time', the
> > 'dj' and the 'showname'.  once i get that, i can add them together
> > with the html and post it to the .append code.  I just don't
> > understand how the daisy chain would work from here.
>
> > Thanks for you help.  The application on this, will be end up being an
> > ajax app, where i pass it the day of the week (monday/tuesday/
> > wednesday) and it will display the shows for that day in order of
> > time.
>
> > ~Doc

Reply via email to