• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

Calling Javascript functions from an applet

 
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

I am having a problem calling two separate javascript functions from an applet at the same time.
I can call them both separately, but not together.
My applet should take some arguments in from an applet (as a string), then create a html page from the string and display it in a separate window.

The first function is to open a page in a new window:


The function is defined in a .js file

This works fine where mainpage.htm exists in the same directory which the applet is running from.

The second function is to create a html page from a string:


This successfully creates and displays a page from a string.
There is also a second, alternative function to do the same thing:

This also successfully creates and displays a page from a string.

Now I need to open the page created from the string in a new window by combining the functions. I have tried lots of things here such as:


but nothing seems to work.
If anyone has an idea how to combine two javascript functions like this it would be a big help.


Thanks.


Eoin.
[ July 20, 2007: Message edited by: Eoin Mac Aoidh ]
 
Eoin Mac Aoidh
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ps: My code dosnt actually contain smileys!
they are supposed to be
'colon'openLeftMonitor...
and
'colon'document.write....



E
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Eoin Mac Aoidh:
Ps: My code dosnt actually contain smileys!


We know.

It's because those particular smileys are triggered by the character sequences ":o" and ":D", which your post happened to contain.

You can turn off smilies by checking the "Disable smilies in this post" checkbox when posting.
[ July 20, 2007: Message edited by: Ulf Dittmer ]
 
Water proof donuts! Eat them while reading this tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic