Opening a popup window 
Author Message
 Opening a popup window

Hello,

    Now, I'm working in a vrml project that consists in modeling a
supermarket. When the user clicks on a shelve, a popup windows should appear
showing what there is in this one.

    But when I click in the shelve, I get two windows, one with the
information I
asked for, and another with the javascript. But the windows with the
javascript
should still contain the VRML file. Is it a problem with my javascript or
with the
brower? Or can't it be done? I use Blaxxsun browser under Internet Explorer
5.

    Does anyone know what code I should use?

    Thanks in advance,

        Albert Morales
        Datos y Sistemas Informticos



Sat, 06 Apr 2002 03:00:00 GMT  
 Opening a popup window

Quote:

>     Now, I'm working in a VRML project that consists in modeling a
> supermarket. When the user clicks on a shelve, a popup windows should appear
> showing what there is in this one.

>     But when I click in the shelve, I get two windows, one with the
> information I
> asked for, and another with the javascript. But the windows with the
> javascript
> should still contain the VRML file. Is it a problem with my javascript or
> with the
> brower? Or can't it be done? I use Blaxxsun browser under Internet Explorer
> 5.

>     Does anyone know what code I should use?

I assume you have the code for opening the new window in the HTML page
which contains also (in an EMBED tag or in an OBJECT tag) the VRML. You
will have some function for opening the new window; let's say it's
called "myFunctionName()". Then you set it up to be called from either a
Script (triggered by a TouchSensor, probably), like this:

        field MFString jsURL "javascript:myFunctionName()"
        field MFString jsParameter ""
        eventIn SFBool trigger

        url ["javascript:
          function trigger(v,ts){
            if (t) {
              Browser.loadURL(jsURL, jsParameter);
            }
          }"
        ]

*OR* you can trigger it from an Anchor, in which case the Anchor looks
like this:
        Anchor {
          url [ "javascript:myFunctionName()" ]
          children [
            # your shelf geometry here
          ]
        }

- Paul
***********************************
Paul S. Hoffman
Senior Interface Designer, Cognetics Corporation

Company URL - http://www.cognetics.com
Personal URL - http://pluto.njcc.com/~paulsam
609-799-5005 ext.237 - FAX 609-799-8555



Sat, 06 Apr 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Realbasic opens a window without a NewDocument event on opening the application

2. Problem with mouse wheel and popup under windows

3. Hiding menu in popup-window

4. Windows Explorer Popup menu options

5. Instant messenger type popup windows

6. Popup window doesn't close (BUG?)

7. controls with template on a popup-window?

8. Popup help window won't display

9. Disable javascript to avoid popup windows.

10. popup window with "anchor" node

11. How: 2D popup window

12. Javascript popup window

 

 
Powered by phpBB® Forum Software