Loading ...
Sorry, an error occurred while loading the content.
 

Re: [wmlprogramming] Re: WURFL: XML parser missed!!

Expand Messages
  • luca passani
    Fabio, we are here to help, you just need to do your part of the work :) Please provide the following: - a self-contained JSP page or servlet which exhibits
    Message 1 of 9 , Jun 1, 2003
      Fabio, we are here to help, you just need to do your part of the work :)

      Please provide the following:
      - a self-contained JSP page or servlet which exhibits the problem
      - the name of the devices (or even better their complete UA strings)
      which are requesting the page

      you should know that 73% of help requests on the internet are solved by
      the requestors themselves
      when trying to build a self-contained example that exhibits the problem.

      BTW did you install wget to programmatically look at the WML returned by
      your server?

      luca

      fater1976 wrote:

      >Luca, I've followed your suggestion, and now the error messages are
      >disappeared, but I suspect there's a problem in the WURFL tags
      >interpretation. In my application I use WURFL to catch the correct
      >image to display, but it doesn't catch it. Always is displayed a
      >WBMP image, also on devices which support GIF or JPEG. Thank you for
      >your time. Fabio
      >
      >
      >--- In wmlprogramming@yahoogroups.com, luca passani <passani@e...>
      >wrote:
      >
      >
      >>please try with this wurfltags.jar and let me know how it goes
      >>
      >>http://groups.yahoo.com/group/wmlprogramming/files/wurfltags.jar
      >>
      >>luca
      >>
      >>fater1976 wrote:
      >>
      >>
      >>
      >>>I have my wurfl.xml in C:\temp, in fact it is found by your API.
      >>>
      >>>
      >I
      >
      >
      >>>think the problem is in the parser recognition. I receive this
      >>>message from the Tomcat window:
      >>>
      >>>Last try. Looking for wurfl.xml in temp directory
      >>>file://C:/temp/wurfl.xml found! I'll use this
      >>>Error in Wurfl:if: null
      >>>Error in Wurfl:if: null
      >>>Error in Wurfl:if: null
      >>>Error in Wurfl:if: null
      >>>Error in Wurfl:if: null
      >>>Error in Wurfl:if: null
      >>>Error in Wurfl:if: null
      >>>Error in Wurfl:if: null
      >>>
      >>>
      >>>And this is the code I use in my JSP (XHTML/MP) page. I wrote a
      >>>cascade if structure in which, each "wurfl:if" condition is
      >>>evaluated until the right image type and size is found:
      >>>
      >>><wurfl:ifmc logic="AND">
      >>> <wurfl:condition capability="gif"/>
      >>> <wurfl:condition capability="max_image_width"
      >>>relation="GE" value="130" match="loose"/>
      >>> <wurfl:then>
      >>> <img src="../img/prensan130.gif" alt="SPOL Gif
      >>>
      >>>
      >130" />
      >
      >
      >>> </wurfl:then>
      >>> <wurfl:else>
      >>>
      >>> <wurfl:ifmc logic="AND">
      >>> <wurfl:condition capability="gif"/>
      >>> <wurfl:condition capability="max_image_width"
      >>>relation="GE" value="110" match="loose"/>
      >>> <wurfl:then>
      >>> <img src="../img/prensan110.gif" alt="SPOL
      >>>
      >>>
      >Gif
      >
      >
      >>>110" />
      >>> </wurfl:then>
      >>> <wurfl:else>
      >>>
      >>> <wurfl:ifmc logic="AND">
      >>> <wurfl:condition capability="gif"/>
      >>> <wurfl:condition
      >>>capability="max_image_width" relation="GE" value="90"
      >>>
      >>>
      >match="loose"/>
      >
      >
      >>> <wurfl:then>
      >>> <img src="../img/prensan90.gif"
      >>>alt="SPOL Gif 90" />
      >>> </wurfl:then>
      >>> <wurfl:else>
      >>>
      >>> <wurfl:ifmc logic="AND">
      >>> <wurfl:condition
      >>>capability="wbmp"/>
      >>> <wurfl:condition
      >>>capability="max_image_width" relation="GE" value="96"
      >>>
      >>>
      >match="loose"/>
      >
      >
      >>> <wurfl:then>
      >>> <img
      >>>src="../img/prensan.wbmp" alt="SPOL Wbmp 96" />
      >>> </wurfl:then>
      >>> <wurfl:else>
      >>> <img
      >>>src="../img/prensan84.wbmp" alt="SPOL Wbmp 84" />
      >>> </wurfl:else>
      >>> </wurfl:ifmc>
      >>>
      >>> </wurfl:else>
      >>> </wurfl:ifmc>
      >>>
      >>> </wurfl:else>
      >>> </wurfl:ifmc>
      >>>
      >>> </wurfl:else>
      >>> </wurfl:ifmc>
      >>>
      >>>
      >>>
      >>>
      >>>--- In wmlprogramming@yahoogroups.com, luca passani
      >>>
      >>>
      ><passani@e...>
      >
      >
      >>>wrote:
      >>>
      >>>
      >>>
      >>>
      >>>>Fabio, you are right. Clive's document referred to Laszlo's API.
      >>>>
      >>>>
      >>>>
      >>>>
      >>>With
      >>>
      >>>
      >>>
      >>>
      >>>>the XOM API,
      >>>>things are not very different, but different enough to confuse
      >>>>
      >>>>
      >>>>
      >>>>
      >>>people.
      >>>
      >>>
      >>>
      >>>
      >>>>I promise to review the whole site and the docs and make them
      >>>>
      >>>>
      >more
      >
      >
      >>>>consistent soon.
      >>>>
      >>>>Here is where the new API looks for wurfl.xml
      >>>>
      >>>>
      >>>>
      >>>>
      >>>(ObjectsManager.java).
      >>>
      >>>
      >>>
      >>>
      >>>>Hopefully this will help. If not,
      >>>>just post the error message and you exact config, and I'll try
      >>>>
      >>>>
      >to
      >
      >
      >>>>
      >>>>
      >>>>
      >>>>
      >>>help
      >>>
      >>>
      >>>
      >>>
      >>>>ciao
      >>>>
      >>>>luca
      >>>>
      >>>>
      >>>>
      >>>>
      >>>>
      >>>
      >>>
      >>>
      >>>
      >>>>fater1976 wrote:
      >>>>
      >>>>
      >>>>
      >>>>
      >>>>
      >>>>>I've just installed Tomcat 4.0.6 and the JDK 1.4.1_02. I've
      >>>>>
      >>>>>
      >read
      >
      >
      >>>>>with attention Clive's instructions on the Wurfl site about how
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>to
      >>>
      >>>
      >>>
      >>>
      >>>>>install WURFL under Tomcat (Before all worked fine, but I had
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>some
      >>>
      >>>
      >>>
      >>>
      >>>>>problems with my machine and now I have to reinstall many
      >>>>>
      >>>>>
      >things,
      >
      >
      >>>>>wurfl included, but now it doesn't run). When I try to run my
      >>>>>
      >>>>>
      >JSP
      >
      >
      >>>>>code or the demo.jsp provided with the new WurflApi based on
      >>>>>
      >>>>>
      >XOM,
      >
      >
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>I
      >>>
      >>>
      >>>
      >>>
      >>>>>see in the Tomcat window that all the wurfl:if statements have
      >>>>>
      >>>>>
      >a
      >
      >
      >>>>>null value (but the wurfl.xml isfound in C:\temp). I think
      >>>>>
      >>>>>
      >ther's
      >
      >
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>a
      >>>
      >>>
      >>>
      >>>
      >>>>>problem with the XML parser.
      >>>>>
      >>>>>Where I have to put the .jar of the XML parser? I know Tomcat
      >>>>>
      >>>>>
      >has
      >
      >
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>an
      >>>
      >>>
      >>>
      >>>
      >>>>>internal parser, but I have installed it now without modifing
      >>>>>
      >>>>>
      >the
      >
      >
      >>>>>default configuration, but nothing happens, it doesn't work!!!
      >>>>>
      >>>>>Help me please. Fabio
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>>>
      >>>Please read the FAQ before you ask questions:
      >>>
      >>>
      >http://www.thewirelessfaq.com
      >
      >
      >>>Visit http://groups.yahoo.com/group/wmlprogramming for archive
      >>>
      >>>
      >and subscription options
      >
      >
      >>>Your use of Yahoo! Groups is subject to
      >>>
      >>>
      >http://docs.yahoo.com/info/terms/
      >
      >
      >>>
      >>>
      >>>
      >>>
      >>>
      >
      >
      >
      >Please read the FAQ before you ask questions: http://www.thewirelessfaq.com
      >
      >Visit http://groups.yahoo.com/group/wmlprogramming for archive and subscription options
      >
      >Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
      >
      >
      >
      >
      >
    • luca passani
      oops,I had missed this message for some reason (I visited 5 countries over the past 2 weeks). Fabio, Clive is correct. The new version I had produced for you
      Message 2 of 9 , Jun 2, 2003
        oops,I had missed this message for some reason (I visited 5 countries
        over the past
        2 weeks).

        Fabio, Clive is correct. The new version I had produced for you fixed
        the bug.
        I have not released the new version to everyone, but I plan to do it soon.
        I have some basic unit-tests in place. Also the XOM jar will be even
        smaller.

        I would like the new version to support all of the features that
        Laszlo's JAXB implementation
        has.

        Luca

        van Hilten, Clive wrote:

        >Hi Fabio
        >
        >At http://wurfl.sourceforge.net/java/java_apiluca.php , we see the
        >following text - 'I still see some funny message in the
        >tomcat window about a null refrence, but the JSP work. If you can help,
        >that would be great.' So it would appear that this is a known issue, and
        >likely not related to your XML parser.
        >
        >HTH
        >
        >Clive
        >
        >-----Original Message-----
        >From: fater1976 [mailto:fater@...]
        >Sent: 21 May 2003 11:14
        >To: wmlprogramming@yahoogroups.com
        >Subject: [wmlprogramming] WURFL: XML parser missed!!
        >
        >
        >I've just installed Tomcat 4.0.6 and the JDK 1.4.1_02. I've read
        >with attention Clive's instructions on the Wurfl site about how to
        >install WURFL under Tomcat (Before all worked fine, but I had some
        >problems with my machine and now I have to reinstall many things,
        >wurfl included, but now it doesn't run). When I try to run my JSP
        >code or the demo.jsp provided with the new WurflApi based on XOM, I
        >see in the Tomcat window that all the wurfl:if statements have a
        >null value (but the wurfl.xml isfound in C:\temp). I think ther's a
        >problem with the XML parser.
        >
        >Where I have to put the .jar of the XML parser? I know Tomcat has an
        >internal parser, but I have installed it now without modifing the
        >default configuration, but nothing happens, it doesn't work!!!
        >
        >
        >
      Your message has been successfully submitted and would be delivered to recipients shortly.