[X3D-Public] Is there a 'base url' for VRML/X3D browsers?

GLG info at 3dnetproductions.com
Mon Aug 1 03:17:49 PDT 2011


You seem to have this right Dave, but I suspect you
are attempting to run it locally thus the localhost
path. Loading your world from an online domain will
produce the right path. Place your php file in the same
directory as your world or use things like ../phppath/.
As for your other question about base path you can 
create your own SFString field. That will do the trick. 

Hope this helps,
Lauren

   _____  ___      __   __ ___  ______   ___   ___   ___
  /__  / / _ \    /  | / // _ \/_  __/  / _ \ / _ \ / _ \
 _/_  / / // /   / /||/ //  __/ / /    / ___//   _// // /
/____/ /____/   /_/ |__/ \___/ /_/    /_/   /_/\_\ \___/
______________________________________________________
 * * Interactive Multimedia - Internet Management * * 
  * * Virtual Reality - Application Programming  * *
   * 3D Net Productions  www.3dnetproductions.com * 

>-----Original Message-----
>From: x3d-public-bounces at web3d.org [mailto:x3d-public-
>bounces at web3d.org] On Behalf Of Dave A
>Sent: Monday, August 01, 2011 5:35 AM
>To: 'x3d public mailing list'
>Subject: [X3D-Public] Is there a 'base url' for
>VRML/X3D browsers?
>
>Hello again,
>
>I'm using Contact, I'm not seeing this, at least as
>anything standard,
>am I missing it?
>
>What I need to know is the 'base url', that is, the
>domain and path,
>that my content is served from. Or more precisely, I
>DON'T want to know
>it, I'd like to be able to use relative paths,
>specifically for using
>createX3DFromURL and such.
>
>Say I have a script that calls thus:
>
>Browser.createX3DFromURL ('generate.php', this,
>'loaded');
>
>Where does the 'generate.php' file need to be? My
>experiments seem to
>indicate that it is on the client machine. Meaning, if
>I serve a page
>containing the plugin from www.mydomain.com, I expect
>that it will call
>http://www.mydomain.com/generate.php, but instead it
>seems to want
>http://localhost/generate.php, I'm guessing because it
>has been cached
>to the local drive and hence runs from there.
>
>Is there a policy on this?
>
>I do see that Contact provides a script extension that
>I could parse to
>find the current url. How widely are such API's out
>there? Xj3D,
>FreeWRL, Instant, etc?
>
>Thanks
>
>Dave A.
>
>_______________________________________________
>X3D-Public mailing list
>X3D-Public at web3d.org
>http://web3d.org/mailman/listinfo/x3d-public_web3d.org




More information about the X3D-Public mailing list