Order Now AdSolution Sign Up | Login » Bits on the Run Sign Up | Login »

Forums

/

how to use showdigits in 4.x

7 replies [Last post]

I need to to use version 4 to display h.264 files and can't go back to 3 - but I would really like to turn the digits off using showdigits like I did with ver 3. Is this possible?

This was my 3.x code:
var s1 = new SWFObject("flvplayer.swf","single","450","360","0");
s1.addParam("allowfullscreen","true");
s1.addVariable("file","MOVIE.flv");
s1.addVariable("autostart","true");
s1.addVariable("showicons","true");
s1.addVariable("showdigits","false");
s1.addVariable("bufferlength","6");
s1.write("player1");

How can I adapt this new 4 code to get the digits to go away?

<p id='preview'>The player will show in this paragraph</p>

<script type='text/javascript' src='swfobject.js'></script>
<script type='text/javascript'>
var s1 = new SWFObject('player.swf','player','450','360','0');
s1.addParam('allowfullscreen','true');
s1.addParam('allowscriptaccess','always');
s1.addParam('flashvars','file=QTMOVIE.mov&autostart=true&controlbar=bottom');
s1.write('preview');

</script>

Much thanks for any hints

Is there a simple way to modify the source code with flash to do this?

I downloaded the trial version of flash - but know nothing about it. But I managed to remove some buttons and stretch the time bars to where I'd like it to be but..

-could not delete the time numbers display
-could not export it to a swf that worked (the swf I published doesn't seem to have any script - just shows the same default layout as in flash with no video)

I just loaded only the "player.fla" file into flash - poked around with my mods - and published it to a swf. I'm assuming I need to add some scripts but do not know how to...

Any hints very appreciated - just want to return functionality to the swf player.

@Mark,

It might be much easier to modify a skin that is close to what you want.

The skin .fla files are in the code branches of the Subversion repository, here: http://code.longtailvideo.com/trac/browser/skins/as3

There might be some here also: http://www.longtailvideo.com/AddOns/?category=skins

Skinning tutorial: http://www.jeroenwijering.com/?item=Skinning_the_JW_Player

thanks for the pointer, and that is what I am trying to do - modify the default player - but I can't figure out how to carry out the seemingly simple steps at Skinning_the_JW_Player. I know it's introduced as needing a basic familiarity with action script - which I do not in any way have! But I have done some scripting in my life with basic, applescript, even the amiga.

But if someone could point me to a good source to fill in the action script holes in the Skinning_the_JW_Player tutorial on this site I would truly appreciate it!

thanks again...

OK, I figured it out - didn't know you needed all the source files in the same folder as the fla file you loaded into flash. Also got to delete the numbers once I loaded the controller tool.

Adding back ability to select:
- ShowFullscreen button - Yes/No
- ShowDigits buttons - Yes/No
- ShowDownload button - Yes/No
- UseFullscreen button - Yes/No

The removal of these features has broken AllVideos Reloaded for Joomla.
It may be easier modify the player than delete features users want and need from AVR.
AVR was designed to make this inserting Flash video easy for everyone.
And not require users to be programmers.
Requiring users to learn Flash to remove a simple button is ridiculous.

Looks like adding IF statements in Controlbar.as should do it:
Around line 275 in the SVN as today (2009-02-19)
JW_Player_SVN\trunk\as3\com\jeroenwijering\plugins\Controlbar.as

    /** Process resizing requests **/
    private function resizeHandler(evt:ControllerEvent=null):void {
        var wid:Number = config['width'];
        clip.x = config['x'];
        clip.y = config['y'];
        clip.visible = config['visible'];
        if(config['position'] == 'over' || view.config['fullscreen'] == true) {
            clip.x = config['x'] + config['margin'];
            clip.y = config['y'] + config['height'] - config['margin'] - config['size'];
            wid = config['width'] - 2*config['margin'];
            clip.back.alpha = 0.75;
        } else if(config['position'] != 'none') {
            clip.back.alpha = 1;
        }
        try {
            clip.fullscreenButton.visible = false;
            clip.normalscreenButton.visible = false;
            if(clip.stage['displayState']) {
                if(view.config['fullscreen']) {
                    clip.fullscreenButton.visible = false;
                    clip.normalscreenButton.visible = true;
                } else {
                    clip.fullscreenButton.visible = true;
                    clip.normalscreenButton.visible = false;
                }
            }
        } catch (err:Error) {}
        stacker.rearrange(wid);
        stateHandler();
        fixTime();
        Mouse.show();
    };

Any suggestions on a better way of doing this are welcome.

After I get this working I will make available for download a version of the SVN 4.4.xxx player with these features re-enabled.

Maybe we should call it the
JW FLV Player - AVR Version - the User-Friendly Backwards-Compatible Will-not-break-every-users-existing-website-embedded-Flash-videos Version.

This is very nice.

Two questions:

1) are you going to maintain this fork as JW releases new versions?

2) did you reallly need to spam so many threads?