xsl-list
[Top] [All Lists]

Re: How do I display data one item at a time?

2005-05-09 16:08:50
I apologize for my tardiness to the list. I was moved to another
project for a while. It happens often here.

I believe I will be getting the baptism by fire here. I am using XSLT
1.0 with the msxml processor. Not my choice but that is what I have.
The elements link together by using ,in my opinion, an idiotic
attribute system. This just makes it all the harder I suspect. Would
my best route be to try and convince them to let me make a new XML
file that would allow me to do an apply-templates match scheme?

Thanks list,

Max

On 5/5/05, JBryant(_at_)s-s-t(_dot_)com <JBryant(_at_)s-s-t(_dot_)com> wrote:
Hi, Max,

A meeting got pushed back a bit, so...

What you have there is a genuine, bona fide grouping problem.

More so than most problems, grouping solutions really depend on the
version of XSLT and the XSLT processor you can use. If you can use XSLT
2.0 (with a processor like Saxon 8), your problem is not too bad. If you
have to use XSLT 1.0, you're going to get a baptism by fire for your first
XSLT project.

So, what XSLT processor are you using? (Forgive me if you told us in an
earlier message.)

Unless you have left some elements out for brevity's sake, I think you'll
also have trouble associating the department info (staffOffice) with the
personal info. They don't seem to share any identifying information. How
do you know what departments Sam and Joe are in?

Jay Bryant
Bryant Communication Services
(presently consulting at Synergistic Solution Technologies)

Max Bronsema <max(_dot_)bronsema(_at_)gmail(_dot_)com>
05/05/2005 12:19 PM
Please respond to
xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com

To
xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
cc

Subject
Re: [xsl] How do I display data one item at a time?


==========================================================
So, please show us a more complete view
of your data (as small as possible but enough to illustrate the current
problem).
==========================================================

No problem with slow replies, it gives me more time to try my own
ideas, maybe I'll get lucky :)

Here is a snapshot of what the structure looks like. I apologize for
not seeing it earlier that what you had posted was different from my
data. <directory> envelopes everything. Then all <staffPersonal> is
grouped together, same with <staffOffice> and <staffTitle>.

<directory>

  <staffPersonal>
    <Person>
      <fName>Sam</fName>
      <lName>Spade</lName>
    </Person>
    <Person>
      <fName>Joe</fName>
      <lName>Bazooka</lName>
    </Person>
  </staffPersonal>

  <staffOffice>
    <Office>
      <dptFull>Biology</dptFull>
      <Location>Boone</Location>
    </Office>
    <Office>
      <dptFull>Business</dptFull>
      <Location>KAIC</Location>
    </Office>
  </staffOffice>

  <staffTitle>
    <Position>
      <phone>123-4567</phone>
      <pEmail>sam(_at_)spade(_dot_)com</pEmail>
    </Position>
    <Position>
      <phone>354-5589</phone>
      <pEmail>joe(_at_)bazooka(_dot_)com</pEmail>
    </Position>
  </staffTitle>

</directory>

From your above description it does appear that I have a grouping
problem. I will study that along with the For-Each examples you sent
earlier and the ones in my books. I'll see what I can come up with
here. Thanks again.

Max Bronsema

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>