View Full Version : calllzx.jsp
srinivas
07-24-2006, 02:55 AM
Hi,
I'm trying to embed laszlo file from jsp like this..Its not throwing any error but not showing the embedding file
where is the mistake ???
<%@ page contentType="text/html; charset=iso-8859-1" language="java"
import="java.sql.*" import="javax.sql.*" errorPage="" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script src="/lps-3.0.2/lps/includes/embed.js" type="text/javascript"></script>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Testing javaScript</title>
<script type="text/javascript">
window.alert("before embedding ");
lzEmbed({url: 'adminmenu.lzx?lzt=js', bgcolor: '#ffffff', width: '400', height: '622'});
window.alert("After embedding ");
</script>
</head>
<body>
</body>
<body>
</body>
</html>
Thanks in advance..
srinivas
caclark
07-24-2006, 11:40 AM
1) Are the jsp and lzx files in the same directory?
2) What happens when you run adminmenu.lzx?lzt=js from the browser address bar? (or with the lzt=swf)
3) Have you tried different lzt= values?
4) Are the alerts (before & after) firing?
5) Are the <body></body><body></body> really in your HTML or is that a copy/paste error?
6) Have you tried with the lzEmbed(...) down in the <body>?
srinivas
07-24-2006, 11:10 PM
Hi caclark,
This is my code:::::
<%@ page contentType="text/html; charset=iso-8859-1" language="java"
import="java.sql.*" import="javax.sql.*" errorPage="" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script src="/lps-3.0.2/lps/includes/embed.js" type="text/javascript"></script>
</head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Testing javaScript</title>
<script type="text/javascript">
window.alert("before embedding ");
lzEmbed({url: 'adminmenu.lzx?lzt=js', bgcolor: '#ffffff', width: '400', height: '622'});
window.alert("after embedding ");
</script>
<body>
</body>
</html>
Answers to ur questions:::
1) Are the jsp and lzx files in the same directory?
yes
2) What happens when you run adminmenu.lzx?lzt=js from the browser address bar? (or with the lzt=swf)
If i run http://localhost:8080/lps-3.3.1/samples/adminmenu.lzx?lzt=js then the output is::::
lzEmbed({url: '/lps-3.3.1/samples/adminmenu.lzx?lzt=swf', bgcolor: '#ffffff', width: '100%', height: '100%'});
3) Have you tried different lzt= values?
I have tried with lzt = swf and lzt= js. it does made any difference
4) Are the alerts (before & after) firing?
The first alert is firing and then blank screen is coming (its' getting stopped in getMenu.jsp itself)
5) Are the <body></body><body></body> really in your HTML or is that a copy/paste error?
sorry ...its copy paste error :) and ofcourse even if i remove it the o/p is same
6) Have you tried with the lzEmbed(...) down in the <body>?
If i do so it is firing first alert and then displaying lzEmbed({url: 'adminmenu.lzx?lzt=js', bgcolor: '#ffffff', width: '400', height: '622'});
Not only that whatever i give in the body..it is displaying as it is....
Waiting for ur reply,
srinivas
illogic_code
07-25-2006, 09:18 PM
dude... i really dont know if i could help.. but i resolv this problem in one way that could get you some ideas.
i am using here servlets to make the html page on the fly. This is the html page generated and worked very well.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>One title</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="1000" height="710" align="middle">
<param name="movie" value="/lps-3.3/calamb/main.lzx?lzt=swf">
<param name="quality" value="high">
<embed src="/lps-3.3/calamb/main.lzx?lzt=swf" width="1000" height="710" align="middle" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"></embed></object>
</body>
</html>
---------------------------
*perhaps* things dont work for you because you arent including all the parameters necessary to flash?? (guessing)
like that classid, codebase, params and so.
if the jsps are compiled to servlets... and here servlets are working ok.. well... that MUST work with jps, rigth?
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.