beginner guide

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • mick

    #1

    beginner guide

    hello,
    I need to learn enough xml to use a piece of software. can anybody
    point me to a friendly guide. right now I want to know exactly what a
    placeholder is. I kind of understand but not really .

    thanks

    mick
  • Peter Flynn

    #2
    Re: beginner guide

    mick wrote:
    hello,
    I need to learn enough xml to use a piece of software. can anybody
    point me to a friendly guide. right now I want to know exactly what a
    placeholder is. I kind of understand but not really .
    The term placeholder isn't specific to XML: it's used in a lot of
    computing and non-computing fields.

    You haven't told us what the piece of software is that you want to use,
    but in most document contexts I have come across, "placeholde r" means an
    empty element or attribute (or one with a temporary value) which must be
    present to satisfy the constraints of the Schema or DTD, but which does
    not yet have any real value or content.

    For example, in DocBook, a chapter must have a title and at least one
    other element present for the document to be valid, so you might want to
    create dummy entries for your intended chapters, but with no content, eg

    <chapter id="xyz">
    <title></title>
    <para></para>
    </chapter>

    (although it would be more likely that you would give the titles: that
    would at least enable you to generate the Table of Contents). In this
    sense, the para element is a placeholder, so is the ID value.

    ///Peter

    Comment

    • mick

      #3
      Re: beginner guide

      On 21 Oct, 22:23, Peter Flynn <peter.n...@m.s ilmaril.iewrote :
      mick wrote:
      hello,
      I need to learn enough xml to use a piece of software. can anybody
      point me to a friendly guide. right now I want to know exactly what a
      placeholder is. I kind of understand but not really .
      >
      The term placeholder isn't specific to XML: it's used in a lot of
      computing and non-computing fields.
      >
      You haven't told us what the piece of software is that you want to use,


      Those guys will answer eventually I'm sure but I need to get on.

      regards

      mick

      Comment

      • Peter Flynn

        #4
        Re: beginner guide

        mick wrote:
        On 21 Oct, 22:23, Peter Flynn <peter.n...@m.s ilmaril.iewrote :
        >mick wrote:
        >>hello,
        >>I need to learn enough xml to use a piece of software. can anybody
        >>point me to a friendly guide. right now I want to know exactly what a
        >>placeholder is. I kind of understand but not really .
        >The term placeholder isn't specific to XML: it's used in a lot of
        >computing and non-computing fields.
        >>
        >You haven't told us what the piece of software is that you want to use,
        >

        >
        Those guys will answer eventually I'm sure but I need to get on.
        To answer your first question there, the two documents:

        <image type="SPHERE"
        tiled="true"
        tiledimagewidth ="8192"
        tiledimageheigh t="4096"
        tilesize="1024"
        >
        <sphere url="sphere_til es_%v_%u.jpg" />
        </image>

        and

        <image>
        <type>SPHERE</type>
        <tiled>true</tiled>
        <tiledimagewidt h>8192</tiledimagewidth >
        <tiledimageheig ht>4096</tiledimageheigh t>
        <tilesize>102 4</tilesize>
        <sphere>
        <url>sphere_til es_%v_%u.jpg</url>
        </sphere>
        </image>

        are equivalent but not "the same". That is, they describe the
        information with the same names, but using a different syntax.

        See the XML FAQ at http://xml.silmaril.ie/developers/attributes/ for
        more on using attributes vs elements. My own rule is that numerical and
        categorical data is best held in attributes, while normal text is best
        held in elements, so I would prefer the first method for this data; but
        there are probably many people who will disagree.

        But you say that the Krpano docs say (on the first page of docs) "use
        proper xml syntax". That's a different question. They must first tell
        you what they mean by "proper".

        XML can be used (and abused) for almost anything. The only sensible
        meaning for "proper" here is "well-formed"; the rules for this are in
        the XML Spec and are summarised in the XML FAQ at


        However, abuse of terminology is also rife, so Krpano may mean "XML
        valid according to our Schema or DTD", which is one step further than
        well-formedness. Valid documents are not only well-formed; they must
        adhere to the specified structure and naming set out in a particular
        Schema or DTD.

        It is very rare that you are allowed just to make up your own XML and
        expect some random application automagically to know what it means, so
        you should check with the Krpano people as to what the "proper" XML is.
        It appears from the thread you quote that there is already some
        specified set of names (image, sphere, etc) that you are aware of, so
        you presumably already know what you must use.

        ///Peter

        Comment

        Working...