Re: Problem: JSP works in Firefox but not in Internet Explorer

2009-05-22 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Jan,

On 5/21/2009 4:51 PM, Jan Peters-Anders wrote:
> The taglib uses
> 
> document.body.appendChild
> 
> which causes IE 7 to crash

Shocking.

> :( Microsoft states as workaround to upgrade
> to IE 8, that is a very good solution

They also suggest:

"
To work around this problem, write script blocks that modify only closed
containers or that modify only the script's immediate container element.
To do this, you can use a placeholder to close the target container, or
you can move the script block into the container that you want to modify.
"

You could move your script code to a different place (and probably
discontinue using the taglib). I suspect you could easily write this
javascript as an external file that you call from wherever you need it.

I have a document myself with this rough layout:


  



// call addChild on div#target

  


This works. I think you have a few options, here, besides re-doing
everything:

1. Create an empty  that takes up no space, and use that as the
target for your addChild.

2. Move the 

RE: Problem: JSP works in Firefox but not in Internet Explorer

2009-05-21 Thread Martin Gainty

Microsoft says you are putting script not in body but in td (Table Data) 
element e.g.

  
  

 
 
  var d = 
document.createElement('div');
  document.body.appendChild(d);
 
 
 
  
  
 
solution is to place the script outside the table to modify the body as seen 
here
 
  
  


   
 
  
  
  var d = document.createElement('div');
  document.body.appendChild(d);
 
  
 


does this conform to your IE implementation?
Martin 
__ 
Jogi és Bizalmassági kinyilatkoztatás/Verzicht und 
Vertraulichkeitanmerkung/Note de déni et de confidentialité
 Ez az
üzenet bizalmas.  Ha nem ön az akinek szánva volt, akkor kérjük, hogy
jelentse azt nekünk vissza. Semmiféle továbbítása vagy másolatának
készítése nem megengedett.  Ez az üzenet csak ismeret cserét szolgál és
semmiféle jogi alkalmazhatósága sincs.  Mivel az electronikus üzenetek
könnyen megváltoztathatóak, ezért minket semmi felelöség nem terhelhet
ezen üzenet tartalma miatt.

Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger 
sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung 
oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem 
Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. 
Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung 
fuer den Inhalt uebernehmen.
Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le 
destinataire prévu, nous te demandons avec bonté que pour satisfaire informez 
l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est 
interdite. Ce message sert à l'information seulement et n'aura pas n'importe 
quel effet légalement obligatoire. Étant donné que les email peuvent facilement 
être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité 
pour le contenu fourni.




> Date: Thu, 21 May 2009 22:51:06 +0200
> From: peters...@gmx.at
> To: users@tomcat.apache.org
> Subject: Re: Problem: JSP works in Firefox but not in Internet Explorer
> 
> Dear Christopher,
> I found the cause for my troubles:
> 
> http://support.microsoft.com/kb/927917/en
> 
> The taglib uses
> 
> document.body.appendChild
> 
> which causes IE 7 to crash :( Microsoft states as workaround to upgrade 
> to IE 8, that is a very good solution
> 
> You helped me with your hint:
> 
> > The parts of the JSP aren't "executed"... they are imported into your
> > HTML, which you could probably see if you had posted the generated HTML.
> > Then your javascript triggers in the generated page do various things.
> > The taglib itself doesn't cause any requests to occur.
> >   
> 
> bacause I looked at the generated HTML and saw the above stated command. 
> I found a forum entry that pointed me to that M$ page. So IE is to 
> blame, not my code.
> 
> Thanks again, I will have to find another way of doing things, I guess, 
> since it is odd to let users encounter this problem and let them be 
> annoyed about the website not working.
> 
> Jan
> 
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 

_
Windows Live™: Keep your life in sync.
http://windowslive.com/explore?ocid=TXT_TAGLM_BR_life_in_synch_052009

Re: Problem: JSP works in Firefox but not in Internet Explorer

2009-05-21 Thread Jan Peters-Anders

Dear Christopher,
I found the cause for my troubles:

http://support.microsoft.com/kb/927917/en

The taglib uses

document.body.appendChild

which causes IE 7 to crash :( Microsoft states as workaround to upgrade 
to IE 8, that is a very good solution


You helped me with your hint:


The parts of the JSP aren't "executed"... they are imported into your
HTML, which you could probably see if you had posted the generated HTML.
Then your javascript triggers in the generated page do various things.
The taglib itself doesn't cause any requests to occur.
  


bacause I looked at the generated HTML and saw the above stated command. 
I found a forum entry that pointed me to that M$ page. So IE is to 
blame, not my code.


Thanks again, I will have to find another way of doing things, I guess, 
since it is odd to let users encounter this problem and let them be 
annoyed about the website not working.


Jan


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Problem: JSP works in Firefox but not in Internet Explorer

2009-05-21 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Jan,

On 5/19/2009 6:54 PM, Jan Peters wrote:
>> If you don't include the Flash document embedded in the HTML document,
>> does MSIE still crash? Try simply using HTML comments to remove it:
>>
>> 
>
> unfortunately to no avail.

MSIE still crashes? Even without the .swf download? So... you have a
plain HTML document that can crash MSIE? Cool!

>> Interesting. So, if you generate an HTML page (say, using Firefox) using
>> this JSP and then browse it using MSIE, everything is okay? It's only
>> when you use the JSP dynamically with MSIE that it breaks?
>>
>>   
> No, it breaks all the time. I do not know what is causing the breaking of IE 
> which is odd. I tried commenting out the taglib parts, but nothing helped.

What happens if you remove sections of your JSP systematically until you
have nothing left? There must be *some* point at which the browser stops
crashing...

>> How about an access log instead of the mod_jk one?
>>
>>   
> ttp://[mysite]/jsp-examples/ct/flamingo-mc_2_0_5/flamingo/flamingo.swf?config=../config/test.xml"
>  "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 
> 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30618)"

...looks like the browser is still requesting the .swf file...

>>> >> url="http://[mysite]/jsp-examples/ct/ClimateConnector.jsp"/>
>>> >> url="http://[mysite]/jsp-examples/ct/ClimateConnectorTemp.jsp"/>
>>> 
>> So, what HTML does this generate? I must admit, I don't understand the
>> usefulness of this tag library, since you can use  to do
>> the same thing if I understand this tag properly. You could also use an
>> external .js file and call functions in it. 
>>
>>   
> This taglib is capable executing parts of the jsp without reloading
> the whole page again. Can you tell me another way of loading the
> ClimateConnector.jsp from the page? I just need to execute the jsp with
> a query parameter attache "id=..." to trigger the database query. That
> is what the taglib does at the moment.

The parts of the JSP aren't "executed"... they are imported into your
HTML, which you could probably see if you had posted the generated HTML.
Then your javascript triggers in the generated page do various things.
The taglib itself doesn't cause any requests to occur.

>> Why do you suspect mod_jk is the problem, here?
> 
> Just a guess.

Okay, well, then make your requests directly to Tomcat and see if it
fixes the problem. Does it?

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkoVjfYACgkQ9CaO5/Lv0PCfbQCggyyFMjWlbmE/wGJalUZKI7tv
kzIAoJ5Mxr80OG65GYEZVurmt24hjIAt
=N4kH
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Problem: JSP works in Firefox but not in Internet Explorer

2009-05-19 Thread Jan Peters
Hi Christopher,

Christopher Schultz schrieb:
> When you say "embeds a Flash object within a JSP page", do you mean that
> your JSP generates a .swf document, or are you saying that the HTML your
> JSP generates causes a .swf document to be fetched by the browser?
>
>   
The latter.
>
> Wow, does MSIE actually crash? Sounds like you are serving a broken .swf
> file and the plug-in is crashing. What version of MSIE are you running?
> What version of the Flash plug-in?
>
>   
I use IE 7. Flash Plugin is version 9.
> If you don't include the Flash document embedded in the HTML document,
> does MSIE still crash? Try simply using HTML comments to remove it:
>
> 
>
>   
unfortunately to no avail.
>
> Interesting. So, if you generate an HTML page (say, using Firefox) using
> this JSP and then browse it using MSIE, everything is okay? It's only
> when you use the JSP dynamically with MSIE that it breaks?
>
>   
No, it breaks all the time. I do not know what is causing the breaking of IE 
which is odd. I tried commenting out the taglib parts, but nothing helped.
>
> How about an access log instead of the mod_jk one?
>
>   
ttp://[mysite]/jsp-examples/ct/flamingo-mc_2_0_5/flamingo/flamingo.swf?config=../config/test.xml"
 "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 2.0.50727; 
.NET CLR 3.5.30729; .NET CLR 3.0.30618)"
62.178.150.151 - - [19/May/2009:23:28:43 +0200] "GET 
/jsp-examples/ct/flamingo-mc_2_0_5/config/test.xml?noCache=1242768521960 
HTTP/1.1" 200 10937 
"http://[mysite]/jsp-examples/ct/flamingo-mc_2_0_5/flamingo/flamingo.swf?config=../config/test.xml";
 "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 2.0.50727; 
.NET CLR 3.5.30729; .NET CLR 3.0.30618)"
62.178.150.151 - - [19/May/2009:23:28:51 +0200] "GET 
/cgi-bin/mapserv?map=/var/www/cubedata/result_test_map_no_postgis.map&VERSION=1.1.1&VERSION=1.1.1&REQUEST=GetMap&SERVICE=WMS&STYLES=default,default&TRANSPARENT=TRUE&SRS=EPSG:31287000&EXCEPTIONS=application/vnd.ogc.se_xml&LAYERS=europa_mm5,ggrenz92&FORMAT=image/png&HEIGHT=444&WIDTH=164&BBOX=149704.680335125,-1125960.27520424,1141359.20986683,1558762.96328403
 HTTP/1.1" 200 9015 
"http://[mysite]/jsp-examples/ct/flamingo-mc_2_0_5/flamingo/fmc/LayerOGWMS.swf"; 
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 2.0.50727; 
.NET CLR 3.5.30729; .NET CLR 3.0.30618)"
62.178.150.151 - - [19/May/2009:23:28:51 +0200] "GET 
/cgi-bin/mapserv?map=/var/www/cubedata/result_map_test.map&SERVICE=WMS&VERSION=1.1.1&VERSION=1.1.1&REQUEST=GetMap&STYLES=default,default,default,default,default,default&TRANSPARENT=TRUE&SRS=EPSG:31287000&EXCEPTIONS=application/vnd.ogc.se_xml&LAYERS=europa_mm5,ggrenz92,d02,results,results_temp,poi&FORMAT=image/png&HEIGHT=444&WIDTH=504&BBOX=29189.1891891893,-25,1050810.81081081,65
 HTTP/1.1" 200 28771 
"http://[mysite]/jsp-examples/ct/flamingo-mc_2_0_5/flamingo/fmc/LayerOGWMS.swf"; 
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 2.0.50727; 
.NET CLR 3.5.30729; .NET CLR 3.0.30618)"

Nothing special I guess...
>> > url="http://[mysite]/jsp-examples/ct/ClimateConnector.jsp"/>
>> > url="http://[mysite]/jsp-examples/ct/ClimateConnectorTemp.jsp"/>
>> 
>
> So, what HTML does this generate? I must admit, I don't understand the
> usefulness of this tag library, since you can use  to do
> the same thing if I understand this tag properly. You could also use an
> external .js file and call functions in it. 
>
>   
This taglib is capable executing parts of the jsp without reloading the whole 
page again. Can you tell me another way of loading the ClimateConnector.jsp 
from the page? I just need to execute the jsp with a query parameter attache 
"id=..." to trigger the database query. That is what the taglib does at the 
moment.

> Why do you suspect mod_jk is the problem, here?
>
>   

Just a guess.

Thank you very much in advance again

Jan


-- 
Neu: GMX FreeDSL Komplettanschluss mit DSL 6.000 Flatrate + Telefonanschluss 
für nur 17,95 Euro/mtl.!* 
http://dslspecial.gmx.de/freedsl-surfflat/?ac=OM.AD.PD003K11308T4569a

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Problem: JSP works in Firefox but not in Internet Explorer

2009-05-19 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Jan,

On 5/19/2009 3:47 AM, Jan Peters wrote:
> I developed a mapserver client application that embeds a
> Flash object within a JSP page using a taglib to trigger a JSP
> database query to create a new map for the viewer.

Wow!

When you say "embeds a Flash object within a JSP page", do you mean that
your JSP generates a .swf document, or are you saying that the HTML your
JSP generates causes a .swf document to be fetched by the browser?

The difference is big: JSP was built to generate text-based content, not
binary content. Yes, you /can/ trick it into generating binary content,
but you have to be very careful.

> All of this works
> perfectly in Firefox but Internet Explorer exits with the error "Site
> [mysite] cannot be loaded. Process terminated."

Wow, does MSIE actually crash? Sounds like you are serving a broken .swf
file and the plug-in is crashing. What version of MSIE are you running?
What version of the Flash plug-in?

If you don't include the Flash document embedded in the HTML document,
does MSIE still crash? Try simply using HTML comments to remove it:



> The page loads the first part
> of the HTML content of the JSP (I can see the heading of the page)
> and tries to display  the Flash part (I can see the grey box of the
> container) but then IE exits (btw: the page also loads perfectly well
> when I just use plain HTML - but then I loose the JSP functionality,
> of course).

Interesting. So, if you generate an HTML page (say, using Firefox) using
this JSP and then browse it using MSIE, everything is okay? It's only
when you use the JSP dynamically with MSIE that it breaks?

> This is my mod_jk log in debug mode:

How about an access log instead of the mod_jk one?

> It seems that Firefox "ignores" the missing mappings while IE does
> not.

What missing mappings? If you're talking about mod_jk, there's no
interaction between the browser and mod_jk: the bytes are just being
shuttled back and forth between httpd and Tomcat.

> The JSP contains the following JSP part:
> 
> 
>  <%@ taglib uri="taglib.tld" prefix="j" %>
>   

I agree with Hassan: it's odd to declare a taglib in the middle of a
page. You should really put this at the top of the page.

>  url="http://[mysite]/jsp-examples/ct/ClimateConnector.jsp"/>
>  url="http://[mysite]/jsp-examples/ct/ClimateConnectorTemp.jsp"/>

So, what HTML does this generate? I must admit, I don't understand the
usefulness of this tag library, since you can use  to do
the same thing if I understand this tag properly. You could also use an
external .js file and call functions in it. 

> without the taglibs the JSP loads in IE.

Maybe you have a bug in your javascript. Have you examined the error
console in Firefox? How about loading something similar in MSIE?

> I am a bit stuck here. Any
> ideas and suggestions how to configure my mod_jk e.g. or what else
> might be wrong are greatly welcome. I use Apache 2.2.3, Tomcat 5.5.23
> and mod_jk 1.2.28.

Why do you suspect mod_jk is the problem, here?

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkoS/fYACgkQ9CaO5/Lv0PBfzQCeKB4SCvCSgDdBUgjMb1Tq9n1V
NiwAoJnmJnfAjDB3Gr3eLMJZpGuDfB2A
=KD/t
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Problem: JSP works in Firefox but not in Internet Explorer

2009-05-19 Thread Hassan Schroeder
On Tue, May 19, 2009 at 12:47 AM, Jan Peters  wrote:

> I developed a mapserver client application that embeds a Flash object within 
> a JSP page using a taglib to trigger a JSP database query to create a new map 
> for the viewer. All of this works perfectly in Firefox but Internet Explorer 
> exits with the error "Site [mysite] cannot be loaded. Process terminated."

I don't use mod_jk, but I'd recommend you try recreating this
first without it (direct connect to Tomcat).

> 
>  <%@ taglib uri="taglib.tld" prefix="j" %>
>  

No idea if it's relevant, but why in the world would you put a taglib
declaration inside page markup??  I would put that at the start of
the page before any response output is set.

FWIW,
-- 
Hassan Schroeder  hassan.schroe...@gmail.com

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org