Re: [SWFObject] Switch audio on/off

2012-05-27 Thread Aran Rhee
So what is happening right now? The code above looks ok on first glance.

Does your swf have a js / ExternalInterface method defined called
playVideo() ?



On Sat, May 26, 2012 at 7:04 PM, Arnaud arn...@smartsy.us wrote:

 Hi

 I am trying to have an HTML link that allow the user to switch on/off
 the audio of the videos shown on the home page. Is it possible? If so
 what would be the adequate code?

 The current code I am using to call the different videos is the one
 below:
 [
 var flashvars = {
xml:'../swf/xml/data.xml'
};
var params = {
menu: false,
scale: noScale,
allowFullscreen: true,
allowScriptAccess: always,
bgcolor: ,
wmode: transparent // can cause issues with FP settings 
 webcam
};
var attributes = {
id:flash_content
};
swfobject.embedSWF(
../swf/smartsy.swf,
flash_content, 256px, 381px, 10.0.0,
../swf/expressInstall.swf,
flashvars, params, attributes);

function playVideos(_id) {
if(!userAgent.match(mobile)){

  document.getElementById(flash_content).playVideo(_id);
}

}
 ]


 You can find the current page in dev here:
 http://184.73.230.170/en/index.html

 Thanks in advance for your help.

 --
 You received this message because you are subscribed to the Google Groups
 SWFObject group.
 To post to this group, send email to swfobject@googlegroups.com.
 To unsubscribe from this group, send email to
 swfobject+unsubscr...@googlegroups.com.
 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 swfobject@googlegroups.com.
To unsubscribe from this group, send email to 
swfobject+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/swfobject?hl=en.



Re: [SWFObject] Switch audio on/off

2012-05-27 Thread Arnaud Saint-Paul
The videos are played correctly but I want to give the users the ability to
switch audio off as it can be annoying sometimes. Beyond the function
already mentioned, there is nothing else:

 function playVideos(_id) {
   if(!userAgent.match(mobile)){
   document.getElementById(flash_content).*
playVideo*(_id);
   }

   }

Can I mute/unmute the audio with javascript by clicking on a HTML link?


On Sun, May 27, 2012 at 9:33 AM, Aran Rhee aran.r...@gmail.com wrote:

 So what is happening right now? The code above looks ok on first glance.

 Does your swf have a js / ExternalInterface method defined called
 playVideo() ?



 On Sat, May 26, 2012 at 7:04 PM, Arnaud arn...@smartsy.us wrote:

 Hi

 I am trying to have an HTML link that allow the user to switch on/off
 the audio of the videos shown on the home page. Is it possible? If so
 what would be the adequate code?

 The current code I am using to call the different videos is the one
 below:
 [
 var flashvars = {
xml:'../swf/xml/data.xml'
};
var params = {
menu: false,
scale: noScale,
allowFullscreen: true,
allowScriptAccess: always,
bgcolor: ,
wmode: transparent // can cause issues with FP settings
  webcam
};
var attributes = {
id:flash_content
};
swfobject.embedSWF(
../swf/smartsy.swf,
flash_content, 256px, 381px, 10.0.0,
../swf/expressInstall.swf,
flashvars, params, attributes);

function playVideos(_id) {
if(!userAgent.match(mobile)){

  document.getElementById(flash_content).playVideo(_id);
}

}
 ]


 You can find the current page in dev here:
 http://184.73.230.170/en/index.html

 Thanks in advance for your help.

 --
 You received this message because you are subscribed to the Google Groups
 SWFObject group.
 To post to this group, send email to swfobject@googlegroups.com.
 To unsubscribe from this group, send email to
 swfobject+unsubscr...@googlegroups.com.
 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 swfobject@googlegroups.com.
 To unsubscribe from this group, send email to
 swfobject+unsubscr...@googlegroups.com.
 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 swfobject@googlegroups.com.
To unsubscribe from this group, send email to 
swfobject+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/swfobject?hl=en.



Re: [SWFObject] Switch audio on/off

2012-05-27 Thread Nathan Mynarcik
Your swf will need to have a listener for the JS call and will need the
functionality to change the volume.

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



Re: [SWFObject] Switch audio on/off

2012-05-27 Thread Arnaud Saint-Paul
Thanks Nathan. How do I create a listener with the functionality to change
volume?


On Sun, May 27, 2012 at 3:15 PM, Nathan Mynarcik kicra...@gmail.com wrote:

 Your swf will need to have a listener for the JS call and will need the
 functionality to change the volume.

 --
 You received this message because you are subscribed to the Google Groups
 SWFObject group.
 To post to this group, send email to swfobject@googlegroups.com.
 To unsubscribe from this group, send email to
 swfobject+unsubscr...@googlegroups.com.
 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 swfobject@googlegroups.com.
To unsubscribe from this group, send email to 
swfobject+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/swfobject?hl=en.



Re: [SWFObject] Switch audio on/off

2012-05-27 Thread Nathan Mynarcik
You will need to have access to the fla file for the swf. Create a function
to change the volume. Add an ExternalInterface.addCallback and set the name
of the function as it's parameters.

Look up ExternalInterface to find some examples.

If you do not have access to edit the fla file, you won't be able to do it.

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