tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Funk <funk...@joedog.org>
Subject Re: Embedding JSP code in a JS file
Date Fri, 12 Sep 2003 16:10:01 GMT
For example:
In the html:
=============
<head>
<link href="javascript/cowbell.jsp" rel="stylesheet" type="text/css" />
</head>
=============

In javascript/cowbell.jsp (possibly)
=============
<%@ page contentType="application/x-javascript"%>
=============


-Tim

Anson Zeall wrote:

> Thanks, but....what....and how to set the mime-type?....
> 
> -----Original Message-----
> From: Tim Funk [mailto:funkman@joedog.org]
> Sent: Saturday, September 13, 2003 12:37 AM
> To: Tomcat Users List
> Subject: Re: Embedding JSP code in a JS file
> 
> 
> Rename the js file to jsp then update your link to pull in the jsp file
> accordingly. (You may have to do a mime-type set too)
> 
> -Tim
> 
> Anson Zeall wrote:
> 
> 
>>HI,
>>
>>    I want to know if anyone knows how to embed JSP code in JS files?
>>'cause I want to use encodeURL inside the JS file....somehow.
>>
>>Regards,
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
> 


Mime
View raw message