PDA

View Full Version : LPS not working correctly on my Mac


zrephel
04-17-2004, 02:33 PM
Hi,

I just downloaded and installed LPS 2.1.1 DE (with the Tomcat Java Servlet Container).
I followed the install instructions. And I confirm that the Laszlo's example "hello.lzx" works fine.

However, when I modify the <text> component to <button>:

<canvas>
<button>Hello Laszlo!</button>
</canvas>

And reload the example page:
http://localhost:8080/lps-2.1.1/examples/hello.lzx

I get:
Error: The data "-
This is a simple rectangular button with a text label.
If no height is given, the default height is used and a special
resource configuration is employed which prevents the
button from being able to be resized at runtime in the y-axis, but which is
significantly lighter weight than the standard <b><i>Button</i></b>
configuration.
" is not legal for a JDOM comment

(Please see attached stack_trace.html file for full error message.)

Why is LPS generating a comment at runtime that it can't even parse?
Similar comment errors occur when I try other components like <window>.

Please help... I'm eager to do some development!

Environment:
Mac OS X 10.2.8
Java 1.4.1

ptw
04-18-2004, 04:19 PM
I don't have a 10.2.8 machine to test against, and I can't duplicate your error in 10.3.3. I am using JVM 1.4.2, and was under the impression that 1.4.1 is no longer supported by Apple. You might try updating your JVM.

mdavis
04-19-2004, 09:49 AM
I have a Power Mac G4 (500 Mhz) with 10.2.8 and Java 1.4.1 running here.

I launched the Laszlo in 10 minutes app and tested a simple button like yours and it is working here for me.

The text of the error message is odd, where exactly did the code come from? Were you in Laszlo in 10 minutes or in the documentation?

Please let me know, we'll find out what is causing you troubles.

mdavis
04-19-2004, 09:56 AM
It looks from the error like you have somehow gotten extra text into your program that is causing the error.

Check to make sure there's no extra text after the canvas tag, including comments.

Let me know if this solves your problem.

zrephel
04-19-2004, 06:29 PM
You bring up a good point, mdavis!

I confirm that Laszlo works perfectly for me via the "In 10 Minutes" app on localhost. Even my simple button example works in the "In 10 Minutes" app!

My problem occurs when I try to build my own .lzx page.

Building from the example files, I did this:
[list=1]
http://localhost:8080/lps-2.1.1/my-apps/copy-of-hello.lzx
(this displays correctly)

In TextEdit, open the file copy-of-hello.lzx
(under the folder "Laszlo Presenatation Server 2.1.1/jakarta-tomcat-4.1.12/webapps/lps-2.1.1/my-apps/")

Change <text>Hello</text> to <button>Hello</button>
And remove all the comment tags, leaving only:

<canvas>
<button>Hello Laszlo!</button>
</canvas>


Reload: http://localhost:8080/lps-2.1.1/my-apps/copy-of-hello.lzx

JDOM comment error occurs
(see first post of this thread)
[/list=1]

I hope there's a simple explanation as to why this is happening to me!

To clarify: my simple button example code works in "Laszlo in 10 Minutes"; all the sample apps and examples work.

But when I modify or create my own .lzx file (saved as UTF-8 or the default Western roman encoding), I get the JDOM comment error.

dlewis
04-30-2004, 03:58 PM
I am running 10.3.3 and was running LPS 2.0. Under these conditions it worked fine. So I then upgraded to LPS 2.1.1 and ran it again and it still works fine. What are you using to edit text? BBEdit? TextEdit? Can you email me your file and I'll give it a go on my machine?

dan@laszlosystems.com

jashatton
12-01-2004, 11:53 AM
None of the demos or the small applications work either.

Here is the different error messages by application:

<b>Dashboard</b>
Error: The data "- Abstract class for making buttons with up-over-down states. " is not legal for a JDOM comment: Comment data cannot start with a hyphen..org.jdom.IllegalDataException: The data "- Abstract class for making buttons with up-over-down states. " is not legal for a JDOM comment: Comment data cannot start with a hyphen..

<b>Calendar</b>
vate " is not legal for a JDOM comment: Comment data cannot start with a hyphen..org.jdom.IllegalDataException: The data "- @keywords private " is not legal for a JDOM comment: Comment data cannot start with a hyphen..

The setup is

Windows XP Pro
JBoss 3.2.3 ( which runs Tomcat 4.0 )
Laszlo LPS core 2.2

Is this a configuration problem?

Thanks,

Jas

zrephel
12-01-2004, 12:12 PM
I solved my problem a long time ago. And I forgot to post the solution here.

This is what I remember: my environment was using the jdom.jar that I had installed, rather than the one in LPS.

Try to get your LPS projects to use the jdom.jar that comes with LPS.

Right now, your .lzx files are being parsed unsuccessfully by the jdom.jar that comes with JBoss/Tomcat.

Hope this helps.

alcat60
01-14-2005, 04:44 AM
Hi,

I unavoidly started another thread (http://www.laszlosystems.com/developers/community/forums/showthread.php?s=&threadid=1954&goto=nextnewest) on the same argument with JBoss 4.0.1.

I can copy my posts here if you think...

Sincerely,
Alberto