Page 1 of 1

the platform...

Posted: Sat Jan 02, 2010 3:12 pm
by massung
...or the environment should be capable of returning "Web" or similar to indicate that the stack is running in a browser.

With the application I'm currently working on, I'm wanting to put a slightly gimped, web version of my app online as a trial version. It'd be nice to have everything be the same app and just a couple if statements to disable certain features.

Or, if this feature is already there, can someone point me to it?

Thanks!

Jeff M.

Re: the platform...

Posted: Sat Jan 02, 2010 4:02 pm
by Klaus
Hi massung,

I think that "the environment" returns "Browser" in a Revlet.
Check the "user contributed notes" in the docs (Rev Dictionary) under "environment"!


Best

Klaus

Re: the platform...

Posted: Tue Jan 05, 2010 11:05 am
by Dixie
massung...

use something like this...

Code: Select all

on openStack
   /*on the desktop */
   if environment() = "development" OR environment() = "standalone" then
         -- do something
   end if
   
   /* on the server */
   if environment() = "browser" then
        -- do something else
   end if
end openStack
be well

Dixie