Thanks Ian for the useful advice. I would appreciate your thoughts and
indeed the thoughts of anyone else,  on my use of a config file for this
project.

Not sure if a config file is the best solution for what I am doing.
Basically the CDROM consists of 60 separate pages / sections. I have just
used 60 labels on the timeline for these

e.g

1_1
1_2
2_1
2_2
Etc

I have not created separate swf files for each of the 60 sections as the
content of most sections is simply a video clip or one sentence of text. I
therefore thought it was more manageable to keep all the sections within one
flash movie. All video clips are external flv files.

I have also set up the navigation menu like this, with 60 labels.

The idea of using a config file is to set various things for each section
such as:

What video clip to play
The Page title
Which label of the navigation menu mc to display
Which buttons to display e.g forward / backward
Which label to navigate to when any button is clicked
Assign actions to visible buttons

etc

The idea of doing it this way is to prevent there being lots of code in all
the 60 labels across the timeline.

Hence the configuration file would have details of what actions to take upon
arriving at each of the 60 sections.

Does the above solution sound like the right way to go? Or can you suggest a
better solution. The application is PC only and is being developed with
Flash 8.

Thanks

Paul





-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Ian Thomas
Sent: 30 January 2007 08:27
To: Flashcoders mailing list
Subject: Re: [Flashcoders] JSON vs. XML for CDROM configuration

We've had absolutely no problem reading text files from CD-ROM using Flash
8. :-)

XML/JSON wouldn't be any faster to read in.

I'd choose XML if you had a much more complex configuration task that needed
lots of nested config (unlikely unless you've got a huge sprawling app - you
can handle most situations by choosing your key=value keynames
appropriately) or if your config involved chunks of (possibly unicode)
textual data.

I wouldn't use JSON for configuration as I find it far less readable - it's
primarily a serialisation/data interchange format rather than a
configuration file format. Additionally, it ties you to a particular
implementation/data layout in your app; whereas if, for whatever reason, you
wanted other apps to read your key/value pairs plain text file (for example,
for patching or updating or simply cataloguing) then it's very
straightforward.

Cheers,
  Ian

On 1/30/07, Paul Steven <[EMAIL PROTECTED]> wrote:
>
> Hmm good point Ian.
>
> Any reason why people would use xml or json files rather than plain text?
> Ease of editing, speed of loading etc?
>
> With regards security implications, just wanted to be sure there was no
> problem reading data from the CDROM as I am sure I read somewhere about
> some
> issue that arised with Flash 8.....
>
> Thanks
>
> Paul
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Ian Thomas
> Sent: 30 January 2007 08:08
> To: Flashcoders mailing list
> Subject: Re: [Flashcoders] JSON vs. XML for CDROM configuration
>
> Um - surely there's a third option, which is plain text? It does depend
> what
> you're configuring, but our external configuration files look like
> java.properties files:
>
> language=en
> useDirectX=true
>
> etc. etc.
>
> We just read them in using LoadVars (overriding onData) and parse them.
> Very
> straightforward.
>
> Security implications etc. - well, that entirely depends what you're
> trying
> to protect against, and what info you're putting in the configuration
> file.
> In general, if the config file is on the CD itself, it's unchangeable, so
> I
> don't see a huge issue?
>
> Unless I've got the wrong end of the stick and you're talking about
> configuring a CD-ROM app via a net connection (some sort of activation
> system) - in which case ignore me. :-)
>
> Ian
>
> On 1/30/07, Paul Steven <[EMAIL PROTECTED]> wrote:
> >
> > I am creating a CDROM application (Flash 8 PC only) and would like to
> > control it with an external configuration file.
> >
> > >From what I can see, I have a choice of a XML or JSON solution - can
> > anyone
> > recommend one over the other?
> >
> > Also if anyone has a link to a working version of JSON and JSONConfig,
> > then
> > I would appreciate it as the version I downloaded is giving me several
> > errors.
> >
> > Any pointers on the use of a configuration file for a CDROM also
> > appreciated
> > - such as any problems I could encounter with security etc
> >
> > Thanks in advance
> >
> > Paul
> >
> > _______________________________________________
> > [email protected]
> > To change your subscription options or search the archive:
> > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
> >
> > Brought to you by Fig Leaf Software
> > Premier Authorized Adobe Consulting and Training
> > http://www.figleaf.com
> > http://training.figleaf.com
> >
> _______________________________________________
> [email protected]
> To change your subscription options or search the archive:
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
> Brought to you by Fig Leaf Software
> Premier Authorized Adobe Consulting and Training
> http://www.figleaf.com
> http://training.figleaf.com
>
> _______________________________________________
> [email protected]
> To change your subscription options or search the archive:
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
> Brought to you by Fig Leaf Software
> Premier Authorized Adobe Consulting and Training
> http://www.figleaf.com
> http://training.figleaf.com
>
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to