Welcome, Guest. Please login or register.
Did you miss your activation email?
05/23/12, 02:09
Home Help Search Login Register
News: Parsley Flex framework review featuring quiz application, in our Flex frameworks series
Flex SDK 4.5 mobile roadmap: begin with your mobile development
Swiz Flex framework review featuring quiz application
New homepage we release our new Homepage, take a look ...

+  Flash-db
|-+  Server side Scripting and Database Support
| |-+  PHP, Perl, ASP, JSP, CFM (Moderators: Flash-db, Musicman, vesa kortelainen, Ronald Wernecke, Jorge Solis, nothingGrinder)
| | |-+  Sexier title, more views??? Bizzare variable problem part II!
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Print
Author Topic: Sexier title, more views??? Bizzare variable problem part II!  (Read 1225 times)
GordonC
Server what's that
*
Posts: 13



View Profile WWW Email
« on: 05/30/02, 17:37 »

I can now get my url encoded php generated variable into my flash movie which is comprised of one MC on the main timeline. The MC (called time) contains two dynamic textfields - "textfield" and "timezone".

The Actionscript attached to the the MC generates the current time based on the local server time, modified by the variable "timezone"

For example:

if (timezone != "local time" && timezone != "GMT") {
        timezone_hours = Number(timezone.substring(5,7));
        timezone_minutes = Number(timezone.substring(8,10));
        if (timezone.charAt(4) == "-") {
            timezone_hours *= -1;
            timezone_minutes *= -1;
        }

Previously, "timezone" was an internal flash parameter with a drop down list of various variables that would modify the server time - I want to replace the internal variable with a php generated one.

The problem: I can succesfully target the dynamic textfield called "timezone" with my external php variable - this however does not affect the "timezone" variable in the above actionscript, so instead of a modified time element, I get the default, or GMT time.

If I preface the above code with "timezone = "-08:00" for example, I get the correct time, that is pacific standard time displayed. I included the textfield "timezone" as a test to make sure that php was doing its job - why would the variable show up correctly there, but not in the actionscript???

A little illustration:

Main Timeline - MC(time) + actionscript
                                        |
                                        |
             texfield(textfield) textfield(timezone)

I hope this is clear!
« Last Edit: 05/30/02, 18:16 by Gordon » Logged
Pages: [1] Print 
« previous next »
Jump to:  


Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!