Well, that is off topic for this list as it is just general js programming,
but here is a siple function which will toggle any div (it can be rewritten
to be passed a visible or hidden value directly rather than a toggle, but
I'll leave that up to you)

function toggleDiv(el)
{
var targetDiv = document.getElementById(el);
if(targetDiv.style.display === "none")
{
targetDiv.style.display = "block";
}
else
{
targetDiv.style.display = "none";
}
}

//usage

toggleDiv ("div_to_hide");


Aran

On Fri, Apr 29, 2011 at 8:59 AM, marzia <[email protected]> wrote:

> Hi Aran,
> I tried, it works when loading the page but then the div wrap will
> remain hidden forever, and everything inside it would not be shown at
> any function applied to my buttons (ie. show movie /hide movie),
> because everything would probably happen, but as being invisible, it
> would not be seen...
> Maybe I should modify the javascript used in my buttons and add a sort
> of "on click show my div wrap". But I don't know how to write it.
> Thank you again!
> Marzia
>
>
>
> On 29 Apr, 10:17, marzia <[email protected]> wrote:
> > I Aran, thank you very much for your answer!
> > very intresting what you described, I will try with a div wrapper
> > around and see what happen.
> > I did test the site remotely but I'm working with mac and a virtual
> > machine with IE multiversion.
> > Maybe is that the reason of the funny IE security alerts?
> > Thank you
> > Marzia
> >
> > On 28 Apr, 16:37, Aran Rhee <[email protected]> wrote:
> >
> > > Hi Marzia
> >
> > > So with dynamic embed, SWFObject overwrites the specified taget div
> with the
> > > flash <object> tag. Any styling you had on the div is therefore
> removed. I
> > > would suggest you create a wrapper div as a parent and style that
> instead.
> >
> > > The alerts from IE in static mode I am guessing are because you are
> testing
> > > locally, and IE has some funny security settings about where it will it
> will
> > > run content. Try uploading to a webserver and see if it still happens.
> If
> > > the error still occurs, then please plost a link to your live page and
> > > people can take a look to see what might be going on.
> >
> > > Aran
> >
> > > On Thu, Apr 28, 2011 at 3:38 AM, marzia <[email protected]>
> wrote:
> > > > Hi to the people of this group,
> > > > I'm new here and not really expert in web developing issuing, I'm a
> > > > self-taught web designer basically....
> > > > I've used the swfObject to embed my flash movies in a web page, but
> > > > I've a couple of problems to solve.
> > > > My movies are in hidden divs (class from css display="none")  and are
> > > > activated using buttons with javascript.
> > > > When using the SwfObject static type, it works fine in all recent
> > > > browsers except in IE6 which gives a pop up alerting "Press ok to
> > > > continue loading the content of this page". It gives it one for each
> > > > embedded movie, so It's quite disturbing since I've got 5 in there.
> > > > When using the dymamic procedure the alert disappear but the movies
> > > > are all visualised, ignoring the class assigned to the container
> divs.
> > > > This is probably due to the fact that the dynamic type is working
> with
> > > > the target div instead the object ID, but I don't undestand
> javascript
> > > > so I don't know how to modify it.
> > > > Please, anybody can help me with this?
> > > > Thank you very much!
> > > > Marzia
> >
> > > > --
> > > > You received this message because you are subscribed to the Google
> Groups
> > > > "SWFObject" group.
> > > > To post to this group, send email to [email protected].
> > > > To unsubscribe from this group, send email to
> > > > [email protected].
> > > > For more options, visit this group at
> > > >http://groups.google.com/group/swfobject?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups
> "SWFObject" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/swfobject?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"SWFObject" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/swfobject?hl=en.

Reply via email to