Go Back   CodingForums.com > :: Client side development > JavaScript programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-15-2012, 01:22 AM   PM User | #1
wkilc
New Coder

 
Join Date: Feb 2008
Posts: 23
Thanks: 0
Thanked 0 Times in 0 Posts
wkilc is an unknown quantity at this point
error - expected identifier, string or number

I just noticed that my pseudo-streaming movie code causes an error with IE7.

I works fine with IE8, FireFox, Chrome... I have been looking on my own and found that it's likely a misplaced comma in my code, the other browser are debugging it, but IE7 will not. The error suggests it's where I have indicated below. I've tried removing the comma just after "about_us.jpg" and that causes the script to fail completely. Can anyone help me here, please?


Code:
<script type="text/javascript">
//<![CDATA[

flowplayer("player", {src: "http://www.mysite.org/flowplayer/flowplayer.commercial-3.2.5.swf", wmode: 'opaque'}, {
	// product key from your account
	key: '#$xxxxxxxxx',
		   // configure clip to use "lighthttpd" plugin for providing video data
    playlist: [
	{
        url: 'http://www.mysite.org/media/video/about_us.jpg',

    },  //<----error suggest here???
	{
        url: 'http://www.mysite.org/flowplayer/streamer.php?file=about_us.flv',
        provider: 'lighttpd',
		bufferLength: "2",
		autoBuffering: false
    }],

    // streaming plugins are configured normally under the plugins node
    plugins: {
        lighttpd: {
            url: 'http://www.mysite.org/flowplayer/flowplayer.pseudostreaming-3.2.5.swf',

			// use ${start} as a placeholder for the target keyframe
        queryString:escape('&start=${start}')
        }
    }
});
//]]>
</script>
wkilc is offline   Reply With Quote
Old 01-15-2012, 01:25 AM   PM User | #2
wkilc
New Coder

 
Join Date: Feb 2008
Posts: 23
Thanks: 0
Thanked 0 Times in 0 Posts
wkilc is an unknown quantity at this point
Tried it again, removing that comma. Works now. Sorry!

Code:
<script type="text/javascript">
//<![CDATA[

flowplayer("player", {src: "http://www.mysite.org/flowplayer/flowplayer.commercial-3.2.5.swf", wmode: 'opaque'}, {
	// product key from your account
	key: '#$xxxxxxxxx',
		   // configure clip to use "lighthttpd" plugin for providing video data
    playlist: [
	{
        url: 'http://www.mysite.org/media/video/about_us.jpg',

    },  //<----error suggest here???
	{
        url: 'http://www.mysite.org/flowplayer/streamer.php?file=about_us.flv',
        provider: 'lighttpd',
		bufferLength: "2",
		autoBuffering: false
    }],

    // streaming plugins are configured normally under the plugins node
    plugins: {
        lighttpd: {
            url: 'http://www.mysite.org/flowplayer/flowplayer.pseudostreaming-3.2.5.swf',

			// use ${start} as a placeholder for the target keyframe
        queryString:escape('&start=${start}')
        }
    }
});
//]]>
</script>
wkilc is offline   Reply With Quote
Old 01-15-2012, 02:16 AM   PM User | #3
Old Pedant
Supreme Master coder!

 
Old Pedant's Avatar
 
Join Date: Feb 2009
Posts: 23,248
Thanks: 59
Thanked 3,999 Times in 3,968 Posts
Old Pedant is a name known to allOld Pedant is a name known to allOld Pedant is a name known to allOld Pedant is a name known to allOld Pedant is a name known to allOld Pedant is a name known to all
The comma at the end of THIS line is the wrong one:
Code:
       url: 'http://www.mysite.org/media/video/about_us.jpg',
The other comma is fine.
__________________
An optimist sees the glass as half full.
A pessimist sees the glass as half empty.
A realist drinks it no matter how much there is.
Old Pedant is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 06:40 PM.


Advertisement
Log in to turn off these ads.