PDA

View Full Version : Ext doesn't run with jboss



linuxer
18 Aug 2008, 4:32 AM
Hi. When I try to charge Ext in a jsp it fails.

I have the Ext dir at /home/sergio/ext
The jboss dir is /home/sergio/jboss-4.2.3.GA
And my application dir is /home/sergio/pruebaEnterprise and I use netbeans (I think it doesn't matter).

When I compile, the page to run the application is http://localhost:8080/pruebaEnterprise-war/index.jsp

Then, Firebug says "Ext is not defined", so it doesn't run. Script tags I writed on head tag are:
<script type="text/javascript" src="/ext/adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="/ext/ext-all-debug.js"></script>

I tried
src="/home/sergio/ext/..."
src="http://localhost:8080/home/sergio/ext/..."
src="http://localhost:8080/ext/..."
and more.. but doesn't run :( I need help please...

NOTE: Excuse my english please.

Condor
18 Aug 2008, 4:47 AM
Are you sure that the Ext files can be found at /home/sergio/ext/?

In that case the following lines should work:

<script type="text/javascript" src="/home/sergio/ext/adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="/home/sergio/ext/ext-all.js"></script>

linuxer
18 Aug 2008, 4:59 AM
Hi Condor.

I'm sure Ext files are at /home/sergio/ext.

[email protected]:~$ ls /home/sergio/ext
adapter docs ext-all.js INCLUDE_ORDER.txt source
build examples ext-core-debug.js license.txt tutorial
CHANGES.html ext-all-debug.js ext-core.js resources

The lines you write doesn't work :( I don't understand anything...

Writing these lines, the firebug's Net tag has 3 requests:
index.jsp
ext-base.js
ext-all-debug.js

and the ULR's are:
http://localhost:8080/pruebaEnterprise-war/index.jsp
http://localhost:8080/home/sergio/ext/adapter/ext/ext-base.js
http://localhost:8080/home/sergio/ext/ext-all-debug.js

Condor
18 Aug 2008, 5:03 AM
/home/sergio/ext is your file system URI and not the URL in your webserver!

Are you running JBoss stand-alone or with Apache?

You need to host the Ext files on JBoss or Apache (latter one preferred, because of lower overhead).

linuxer
18 Aug 2008, 5:18 AM
/home/sergio/ext is your file system URI and not the URL in your webserver!

I know it.



Are you running JBoss stand-alone or with Apache?


When I installed JBoss I installed Apache Ant too.



You need to host the Ext files on JBoss or Apache (latter one preferred, because of lower overhead).

Ok, I will host it on JBoss, but.. In what dir exactly? I hosted Ext files with a symbolic link at:
/home/sergio/jboss-4.2.3.GA
/home/sergio/jboss-4.2.3.GA/server/default
/home/sergio/jboss-4.2.3.GA/server/default/work/jboss.web/localhost

and no-one works..

Animal
18 Aug 2008, 5:22 AM
Works for us.

linuxer
19 Aug 2008, 3:26 AM
I hosted Ext dir here:
/home/sergio/pruebaEnterprise/pruebaEnterprise-war/web

Netbeans spends A LOT of time indexing files, but when it finish (if netbeans don't crash before..), Ext works! In the jsp file, I use this path:

src="/pruebaEnterprise-war/ext/adapter/ext/ext-base.js"
src="/pruebaEnterprise-war/ext/ext-all.js"

I'm happy! =D