Welcome to TalkGraphics.com
Page 1 of 2 12 LastLast
Results 1 to 10 of 14
  1. #1

    Default Help with Error Message

    Hello,

    I am embedding a multi-video .swf player on a page and I am almost there. The player and videos are working fine, but I lose my scrollbars on the page.

    This is the error message:

    Line: 60
    Error: 'swfmacmousewheel' is null or not an object


    From this code:

    <head>
    <title>Dynamic Flash Video Gallery</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <script type="text/javascript" src="js/swfobject.js"></script>
    <script type="text/javascript" src="js/swfmacmousewheel2.js"></script>
    <script type="text/javascript">

    var vars = {xmlURL:'gallery.xml' ,autoplay:'false',videoHeight:'328', videoWidth:'594'};
    var params = { scale:'noScale', salign:'lt', menu:'false', bgcolor:'3a362f', allowfullscreen:'true' };
    var attributes = { id:'testObject', name:'testObject' }; // give an id to the flash object

    swfobject.embedSWF("preview.swf", "flashContent", "812", "360", "9.0.0", "js/expressInstall.swf", vars, params, attributes );
    swfmacmousewheel.registerObject(attributes.id);

    </script>
    <style type="text/css" media="screen">
    html, body, #flashContent { height:100%; background-color:#3a362f; }
    body { margin:0; padding:0; overflow:hidden; }
    </style>
    </head>

    <body bgcolor="#3a362f" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" scroll="no">
    <table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0">
    <tr>
    <th align="center" valign="middle">
    <div id="flashContent">
    <h1>Alternative content</h1>
    <p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>
    </div>
    </th>
    </tr>
    </table>
    </body>
    </html>


    I have pasted this code in Xara as a paceholder which has been copied from a sample hmtl [age that came with the player.

    Thanks for you help!

  2. #2

    Default Re: Help with Error Message

    You cannot embed a complete html page into a placeholder, this will cause your Xara output page to have double <html> <title> <head> and <body> tags.
    Also, you are introducing tags that should be in the head area to the body area.
    Basically, you have too much code in one placeholder.

  3. #3

    Default Re: Help with Error Message

    Thanks,

    As you can tell, I am not much of a coder!

    Is there a way you could decipher what I would want to include to operate the player?

    Thanks

  4. #4

    Default Re: Help with Error Message

    Well I don't know the software/script you are using - but as a glance you need two placeholders.
    The first named <HEAD> should contain:

    <script type="text/javascript" src="js/swfobject.js"></script>
    <script type="text/javascript" src="js/swfmacmousewheel2.js"></script>
    <script type="text/javascript">

    var vars = {xmlURL:'gallery.xml' ,autoplay:'false',videoHeight:'328', videoWidth:'594'};
    var params = { scale:'noScale', salign:'lt', menu:'false', bgcolor:'3a362f', allowfullscreen:'true' };
    var attributes = { id:'testObject', name:'testObject' }; // give an id to the flash object

    swfobject.embedSWF("preview.swf", "flashContent", "812", "360", "9.0.0", "js/expressInstall.swf", vars, params, attributes );
    swfmacmousewheel.registerObject(attributes.id);

    </script>
    <style type="text/css" media="screen">
    html, body, #flashContent { height:100%; background-color:#3a362f; }
    body { margin:0; padding:0; overflow:hidden; }
    </style>


    *Note: The <HEAD> placeholder can be located off the page in the grey area (pasteboard)

    The second placeholder sized to 594x328 pixels (the actual player window in your page) you need at least:

    <div id="flashContent">
    </div>

  5. #5

    Default Re: Help with Error Message

    Thanks for your help.

    I created a separate box and set the <HEAD> placeholder to it.

    If I place this box in the grey area, it does not show up in the code.

    If I place the box on the page, the Flash player works!, the scroll bars are active but my background stops about 2/3rds the way down the page and the player is not centerd.

    The easy way is to put the player's .swf as a placeholder but for some reason when I do this the player is active on the page, but the video files will not play.

    So close but I am lost why and how to fix this!

    Is there anything I can show you to help?

    Thanks

  6. #6

    Default Re: Help with Error Message

    Quote Originally Posted by Bassman View Post
    If I place this box in the grey area, it does not show up in the code.
    You must name the placeholder <HEAD>.
    Only then will the code show up when exported.

    Click image for larger version. 

Name:	names.png 
Views:	167 
Size:	24.9 KB 
ID:	69857

    If you do not name the placeholder, the code will not be placed in the <head section.

    The easy way is to put the player's .swf as a placeholder but for some reason when I do this the player is active on the page, but the video files will not play.
    No, because the player.swf is only the 'player' - it does not contain the gallery data. The code needs to load the variables, parameters and attributes and parse the gallery.xml which contains the image data for the player to show.

  7. #7

    Default Re: Help with Error Message

    Thanks so much for your persistence.

    After naming the placeholder everything is working well except the background seems to be interrupted.

    I have attched a screen capture of the exported html page.

    (The player is just at stock settings with sample videos btw).

    Any ideas why the background is being affected?
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	Background Issues.jpg 
Views:	136 
Size:	65.7 KB 
ID:	69860  

  8. #8

    Default Re: Help with Error Message

    Images used for background are tiled by default and will show as such when the browser window exceeds the original size of the image used..
    If you don't want tiling, look in the Tweak set

  9. #9

    Default Re: Help with Error Message

    Quote Originally Posted by sledger View Post
    Images used for background are tiled by default and will show as such when the browser window exceeds the original size of the image used..
    If you don't want tiling, look in the Tweak set
    This background did not stop there before I added the html placeholder.

  10. #10

    Default Re: Help with Error Message

    What size is the bitmap used for the background?
    Can you post it and/or your .xar file please?

 

 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •