W3C home > Mailing lists > Public > www-forms@w3.org > March 2004

Debugging forms

From: T. V. Raman <tvraman@us.ibm.com>
Date: Mon, 22 Mar 2004 15:45:41 -0800
Message-ID: <16479.31397.7604.3622@bubbles.almaden.ibm.com>
To: bobbateman@sequoiallc.com
Cc: www-forms@w3.org



You've hit on one of XML's dirty secrets:-)

As in your case, debugging and checking the XML examples,
specifically namespaces and XPath expressions -- were the things
that took most time while writing the XForms book -- though
probably not as much time as writing the equivalent logic in
hand-rolled javascript would have proven.

Here are some of the tools I found helpful while I wrote the
examples in the book; note that at the time I was writing the
book, the validation service was not yet availab,e.

0) Getting XML instances write -- use Emacs --- with James
Clark's excellent nxml mode.

This gets you valid xml as you type, gives colorization for
invalid constructs, keeps namespaces straight ...

1) Either use xmllint's interactive mode (xmllint is part of
   libxml from the Gnome project, or use the perl xsh (see
   sourceforge)
to work with XPath expressions interactively. 

>>>>> "Robert" == Robert Bateman <bobbateman@sequoiallc.com> writes:
    Robert> Greetings all.
    Robert> 
    Robert> I've been having a discussion today with an associate
    Robert> who uses XML a lot.  During our conversation, I
    Robert> rambled on about the difficulties I've been having
    Robert> while I'm both learning XPath and XForms and writing
    Robert> a form.
    Robert> 
    Robert> One of the difficulties I'm having is "debugging" my
    Robert> various XPath expressions.  One of the errors I get a
    Robert> LOT is my instance data not being "valid." This error
    Robert> means I can't write even invlid XML to look at and
    Robert> "fix."
    Robert> 
    Robert> I realize I'm quite stuck in my ways (I've been
    Robert> programming for over 22 years.) and some habits (like
    Robert> debugging) are hard to break.  What I'm hoping for is
    Robert> a little advice from the "experts" on the list as to
    Robert> better ways to debug using XForms and XPath.  (Please
    Robert> note that I've looked at XFormation and found that,
    Robert> while its a great tool, I can't get it to work for
    Robert> me....)
    Robert> 
    Robert> Thanks much for your time!
    Robert> 
    Robert> Bob Bateman Software Developer Sequoia Group LLC

-- 
Best Regards,
--raman
------------------------------------------------------------
T. V. Raman:  PhD (Cornell University)
IBM Research: Human Language Technologies
Architect:    Conversational And Multimodal WWW Standards
Phone:        1 (408) 927 2608   T-Line 457-2608
Fax:        1 (408) 927 3012     Cell: 1 650 799 5724
Email:        tvraman@us.ibm.com
WWW:      http://almaden.ibm.com/u/tvraman
AIM:      TVRaman
GPG:          http://www.almaden.ibm.com/cs/people/tvraman/raman-almaden.asc
Snail:        IBM Almaden Research Center,
              650 Harry Road
              San Jose 95120
Received on Monday, 22 March 2004 18:46:32 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 10 March 2012 06:21:57 GMT