Not signed in (Sign In)

Vanilla 1.0.3 is a product of Lussumo. More Information: Documentation, Community Support.

    • CommentAuthorkarlp
    • CommentTimeJan 9th 2007
     
    Hello...

    I am attempting to implement SWFObject in to an Enterprise CMS. In order to implement SWFObject efficiently I would like to encapsulate the .js file in to a single function. Can this be done? How would I go about doing this? Any pointers appreciated. Thanks in advance.
    • CommentAuthorGeoff
    • CommentTimeJan 9th 2007
     
    Why does it needs to be in a single function?

    It's already namespaced into the 'deconcept' object, so won't collide with anything else you have on your pages.
    • CommentAuthorkarlp
    • CommentTimeJan 10th 2007
     
    I have been asked to put the swfobject_source.js file in to a single function so that it can then be included in the single .js file that contains all the other javaScript functions implemented within the CMS. I have be told this would be the most efficient method of implementation for a rather large site.
    • CommentAuthorGeoff
    • CommentTimeJan 10th 2007
     
    that sounds silly.

    you can easily place the contents of the swfobject.js into another file, but it wouldn't make sense to put all the code into a single function.
    • CommentAuthorkarlp
    • CommentTimeJan 10th 2007 edited
     
    OK! so if the swfobject.js is in another file - will it not run everytime the file is called? Not all the pages within the site contain Flash. I would like to call the swfobject.js only on the pages which contain Flash obviously. Thanks