Hello,

I dont see a problem with your requirement. Just have the applet download the script from HTTP. So host your BSH script on an http and load it as you would an image or any other HTTP resource.

Travis

On Thu, Mar 6, 2008 at 1:36 PM, leenasn <leenasn@gmail.com> wrote:

uwe,

 Thanks a lot for your reply. I will explain a little more on my
requirement. We right now have an applet which downloads a set of files to
the client machine. The problem with applet is, there are caching issues
with it and also the download is also not on demand. What we want is an
intelligent script written at the server end using which the applet can
download the files from the server. The advantage of using a beanshell
script here is:

 1. The entire logic is moved the bean shell script. So there is no need to
compile, create jar, sign jar etc.
 2. Applet will just pass the request to beanshell and there is very less
chance of code change in applet.

It is not a manual download done by the user and has to happen automatically
by the applet when someone access the site. The files we are downloading are
some kind of applications say like gotomeeting app getting downloaded from
gotomeeting and it gets downloaded at the user.home.

I don't think this can be achieved through a MVC architecture as you had
mentioned. I feel the good solution is with applet+server side beanshell.

Let me know there are better solutions.

Thanks,
Leena


Geercken Uwe wrote:
>
> leena,
>
> I am using beanshell in a MVC environemnt (java) to dynamically load
> scripts and merge them with apache velocity templates, to create the html
> output.
>
> so the user clicks on a webpage. the request goes to the server, goes
> through a controller, loads the appropriate beanshell script and e.g.
> retrieves data from the database, then merges the data with a layout file
> and the velocity template and at the end hands back the created html page
> to the client.
>
> I have used this in several production systems and it works well. it also
> allows me to - in a wiki like style - to modify or create the beanshell
> scripts and the templates from the webpage itself.
>
> let me know if I can further help you.
>
> rgds,
>
> uwe
>
> -----Original Message-----
> From: beanshell-users-bounces@lists.sourceforge.net
> [mailto:beanshell-users-bounces@lists.sourceforge.net] On Behalf Of
> leenasn
> Sent: Donnerstag, 6. März 2008 12:10
> To: beanshell-users@lists.sourceforge.net
> Subject: [Beanshell-users] Running Bean shell from applet
>
>
> Hi,
>
>   I am newbie to BeanShell. I would like to know how can I execute a bsh
> file located at the server side from the browser using an applet. Let me
> explain you in detail.
>
>   I have an applet which the browser will be loading. On a user action, I
> would like to execute a beanshell script located at the server to be
> executed. I tried using Interpreter.source method, but got the error
> saying the bsh file can not be located because it is looking the bsh file
> at the client machine rather than at the server. I also tried using
> Remote.eval method but that also gave me the same error.
>
>   It is not compulsory that I have to use applet. Is there a way I can
> execute a beanshell script at the server from a browser.
>
> Thanks in advance,
> Leena
>
> --
> View this message in context:
> http://www.nabble.com/Running-Bean-shell-from-applet-tp15871037p15871037.html
> Sent from the BeanShell - User mailing list archive at Nabble.com.
>
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> Beanshell-users mailing list
> Beanshell-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/beanshell-users
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> Beanshell-users mailing list
> Beanshell-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/beanshell-users
>
>

--
View this message in context: http://www.nabble.com/Running-Bean-shell-from-applet-tp15871037p15871374.html
Sent from the BeanShell - User mailing list archive at Nabble.com.


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Beanshell-users mailing list
Beanshell-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/beanshell-users



--
www.toxicbunny.co.za << Java port site