|
[Date Index]
[Thread Index]
[Author Index]
Re: Dynamic evaluation not automatically enabled in CDF documents
- To: mathgroup at smc.vnet.net
- Subject: [mg121893] Re: Dynamic evaluation not automatically enabled in CDF documents
- From: A Retey <awnl at gmx-topmail.de>
- Date: Thu, 6 Oct 2011 04:20:47 -0400 (EDT)
- Delivered-to: l-mathgroup@mail-archive0.wolfram.com
- References: <j6h2vk$6t1$1@smc.vnet.net>
Am 05.10.2011 10:03, schrieb Jacopo Bertolotti:
> Dear Mathgroup,
> Recently I started to use the CDF format from Mathematica to create some
> physics interactive tutorial but, on the last one I created, I
> encountered a strange problem. If you download the cdf
> (http://www.jacopobertolotti.com/CDF/COPS_tutorial_digitalholography.cdf) and
> open it with the offline player you are greeted with the warning that
> "This file contains potentially unsafe dynamic content". If you press on
> "Enable Dynamics" then everything works fine.
If you open the cdf with Mathematica 8, the header (=DockedCell) that it
shows has also a link which gives details about that security feature.
There you will find the information that it depends on what
functionality you use in your cdf-file whether or not that warning is
shown. If you click on that link and scroll down the help page that
opens there is a relatively vague description on what is considered to
be "unsafe":
Dynamic content is considered unsafe if it:
uses File operations
uses interprocess communication via MathLink Mathematica Functions
uses JLink or NETLink
uses Low-Level Notebook Programming
uses data as code by Converting between Expressions and Strings
uses Namespace Management
uses Options Management
uses External Programs
I didn't inspect your code in detail, but it doesn't look very unsafe to
me. My guess is that it is the Needs for PlotLegends that causes the
warning in your case. So if you find a way to avoid the use of
PlotLegends that might solve your problem.
> Yet when the cdf is embedded in a webpage
> (http://www.jacopobertolotti.com/tutorials_digitalholography.html) all
> the Manipulate[] that make a cdf really worth to use are just disabled
> and appear as grey boxes.
I think that this is the default behaviour when shown within the plugin
when the standalone player would show the "potentially unsafe content"
warning. If you can't get rid of the warning, your users could still use
the cdf if they save it to file from the plugin and then open the file
with the standalone player and allow the potentially unsafe dynamics to
evaluate. You could put that information into the cdf-file or onto the
web-page where your users download the cdf-files.
> What puzzles me is that I did not encounter this problem in my previous
> attempts and this time I did not do anything very different (apart from
> the fact that the code is a lot more complex).
as said above, that might well be the cause for the warning...
> Does anybody have any idea how to set the dynamics as enabled by default?
I think that the only solution is to not use anything that is considered
"unsafe". This might need some experimentation, since I think there is
no complete list of functions that are considered unsafe. The most
user-friendly feature would be a tool that would show unsafe content
with possible alternatives, as the version 5 to version 6 converter, but
I don't think anything like that does exist...
hth,
albert
Prev by Date:
Re: Re: simplification
Next by Date:
Re: Thread::tdlen: Objects of unequal length
Previous by thread:
Dynamic evaluation not automatically enabled in CDF documents
Next by thread:
Re: Dynamic evaluation not automatically enabled in CDF documents
|