homepage Welcome to WebmasterWorld Guest from 54.163.84.199
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / Flash and Shockwave
Forum Library, Charter, Moderator: open

Flash and Shockwave Forum

    
Flash runs locally, fails after upload.
Issues with Flip-book app that generates exe's & swf for CD and swf for web
Arizona




msg:4287870
 5:27 pm on Mar 26, 2011 (gmt 0)
Hello everybody,

I am so new to Flash that to even say so would be a lie! All I've done is use a couple different applications to generate flash files, so I have virtually no coding experience, although I have done a little HTML work... but nothing very elegant. I've spent a hour or so reading over several of the posts on this forum, and I'm amazed at how many questions there are that are similar to mine... but different. I am also amazed at the breadth of knowledge available here, so I am optimistic. I'm thinking that my biggest initial challenge is going to be framing my question in such a way that it can be answered. I will do my best...

My task was to make an online flip-book for a company that publishes a magazine. It's a small book, 24 pages, all real estate adverts, and the source files are all web quality PDFs ripped from Adobe InDesign CS4.

The flip-book application in this case is called Fresh Flash Catalog 3.6... it's from a Turkish developer. It has a very straightforward PDF import feature, and I was able to make everything work in the first day of the free trial period of its evaluation version... that is, I was able to make everything work on board.

Locally, I could generate and run stand-alone exe and swf files, burn them to CD and run/open them at another workstation. I even ran them on a non-networked laptop. The same for the html/swf files. For web purposes, the app generates the same presentation in several smaller flash files instead on one gigantic one. It outputs an html file to contain a small flash file that displays the interface - the background, the navigation bar, and the space for the pages. It also outputs the separate pages as individual swf files, and deposits them in their own sub-directory.

Because everything worked perfectly on the developing machine and others, I just assumed that it would work on the web, so I gave them the go-ahead and the company plunked down $200 for the full version. Long story short - after binary ftp to their server, the html page displays the frame for the book with the navigation bars and everything, but it doesn't "see" the pages in the sub-folder. It "flips" from page to page, shows the page numbers one by one, right to the end of the book, but the frames remain empty... you can even hear the "flip" sound!

I've checked everything that I know to check - there are no small case / upper case conflicts, the host (Network Solutions) needs no special permissions, plus another flash presentation that I made using a separate slide show application works perfectly. I "tested" each of the flash files on the server - individually, they open and display in Fx4 and IE8, even the ones in the sub-folder.

I even had the app export the entire presentation as a single swf file (without the smaller files in a sub-directory), uploaded it to the server, and tested it - it runs perfectly, although it takes almost a full minute to download... and nobody's gonna wait that long.

The only thing I can think of is that the "parent" swf file, the one that displays the book frame and nav bars, doesn't know the path to the individual swf file pages, even though that path was created by the application itself, and I don't even know how to "open" an swf file to check... I tried to look at it with ConTEXT, a program editing tool, and all it sees is machine language.

I've called the developer in Istanbul, but they're not open until Monday... and there's the time difference thing... I have to call them at midnight my time (Arizona, USA) to get them at 9:00 am their time, and when I do, I get an answering machine that speaks to me in Turkish for a minute, then sez in a very cool accent "Press the 9 for English". Kinda scary, but I will press the 9 if it comes to that.

In the meantime, however, I'll paste the code here from the html page that contains the "parent" swf file. The name of the overall project file is Flip_04 (a flip-book for the month of April), so the app names everything accordingly. The web page is named "flip_04.html" and the flash file is named "flip_04.swf". The sub-folder that contains the individual pages is named "flip_04", and the pages are named "page1.swf" sequentially to page 24, all without the quotes. And lastly, the giant 5.3 MB stand-alone file is named "0000.swf" and can be viewed through "0000.html", if anyone wants to see what the full presentation is supposed to look like... but don't be in a hurry.

Oh, one other thing... when the software outputs the "SWF for Web" files, it offers two check-box options - the default is to make the \flip_04 sub-directory and to use something called Relative Reference. I've tried it with and without Relative Reference. The only difference, as far as I can tell, is that with the RR box unchecked, it puts everything in the same folder - the html file, the main swf file, and all of the pages. It still doesn't work... at least not online - everything works brilliantly on my PC, no matter how I crunch it.

So... here's the code, and you're more than welcome to poke around those other files I've named... they're all on the main root directory at rimcountry.com.

Besides easing the embarrassment of being the only "IT" type geeky person here... and failing... I'm thinking that resolving this issue might help advance me along my career path... so any and all help would be greatly appreciated.

CODE from "flip_04.html":

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>The Rim Country's REVIEW Magazine - Real Estate & More</title>
</head>
<body style="margin: 0px;">
<!--<FFCVerison>3.6</FFCVerison>-->
<script language="JavaScript" type="text/javascript">
function parseHashParam(strParamName){
var strReturn = "";
var strHref = window.location.hash;
if ( strHref.indexOf("#"[smilestopper]) > -1 ){
var strQueryString = strHref.substr(strHref.indexOf("#"[smilestopper])).toLowerCase();
var aQueryString = strQueryString.split("&"[smilestopper]);
for ( var iParam = 0; iParam < aQueryString.length; iParam++ ){
if (
aQueryString[iParam].indexOf(strParamName.toLowerCase() + "="[smilestopper]) > -1 ){
var aParam = aQueryString[iParam].split("="[smilestopper]);
strReturn = aParam[1];
break;
}
}
}
return unescape(strReturn);
}
function ffcmovie_DoFSCommand(command, args) {
if (command=="quit"[smilestopper])
{
location.href="/"; // change to location.href="your web address"
}
}
function setPLink(url)
{
location.hash = url;
}
document.write(
'<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"\n'+
' codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0"\n'+
' WIDTH="100%" HEIGHT="100%" id="ffcmovie" align="middle">\n'+
' <PARAM NAME="allowScriptAccess" value="sameDomain" />\n'+
' <PARAM NAME="allowFullScreen" value="true" />\n'+
' <PARAM NAME=movie '+
' VALUE="flip_04.swf" />\n'+
' <PARAM NAME=quality VALUE=high />\n'+
' <PARAM NAME=FlashVars VALUE="inpageno='+parseHashParam('pageno')+'" />\n'+
' <PARAM NAME=scale VALUE=noscale />\n'+
' <EMBED src="flip_04.swf"' +
' WIDTH="100%" HEIGHT="100% '+
' quality="high"' +
' scale="noscale"' +
' id="ffcmovie" name="ffcmovie"' +
' FlashVars="inpageno='+parseHashParam('pageno')+'"' +
' allowFullScreen="true"' +
' TYPE="application/x-shockwave-flash"'+
' />\n'+
'</OBJECT>\n');
</script>
</body>
</html>

 

Arizona




msg:4287872
 5:41 pm on Mar 26, 2011 (gmt 0)

Hmmm... after viewing my post, I've noticed a lot of stuff appears here in this forum in the code that doesn't appear in the original. I'm think that maybe it's because I checked the Disable Smileys and Disable [codes] options. Let me try the code again and I'll leave the check boxes be...

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>The Rim Country's REVIEW Magazine - Real Estate & More</title>
</head>
<body style="margin: 0px;">
<!--<FFCVerison>3.6</FFCVerison>-->
<script language="JavaScript" type="text/javascript">
function parseHashParam(strParamName){
var strReturn = "";
var strHref = window.location.hash;
if ( strHref.indexOf("#") > -1 ){
var strQueryString = strHref.substr(strHref.indexOf("#")).toLowerCase();
var aQueryString = strQueryString.split("&");
for ( var iParam = 0; iParam < aQueryString.length; iParam++ ){
if (
aQueryString[iParam].indexOf(strParamName.toLowerCase() + "=") > -1 ){
var aParam = aQueryString[iParam].split("=");
strReturn = aParam[1];
break;
}
}
}
return unescape(strReturn);
}
function ffcmovie_DoFSCommand(command, args) {
if (command=="quit")
{
location.href="/"; // change to location.href="your web address"
}
}
function setPLink(url)
{
location.hash = url;
}
document.write(
'<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"\n'+
' codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0"\n'+
' WIDTH="100%" HEIGHT="100%" id="ffcmovie" align="middle">\n'+
' <PARAM NAME="allowScriptAccess" value="sameDomain" />\n'+
' <PARAM NAME="allowFullScreen" value="true" />\n'+
' <PARAM NAME=movie '+
' VALUE="flip_04.swf" />\n'+
' <PARAM NAME=quality VALUE=high />\n'+
' <PARAM NAME=FlashVars VALUE="inpageno='+parseHashParam('pageno')+'" />\n'+
' <PARAM NAME=scale VALUE=noscale />\n'+
' <EMBED src="flip_04.swf"' +
' WIDTH="100%" HEIGHT="100% '+
' quality="high"' +
' scale="noscale"' +
' id="ffcmovie" name="ffcmovie"' +
' FlashVars="inpageno='+parseHashParam('pageno')+'"' +
' allowFullScreen="true"' +
' TYPE="application/x-shockwave-flash"'+
' />\n'+
'</OBJECT>\n');
</script>
</body>
</html>

explorador




msg:4289687
 6:38 pm on Mar 30, 2011 (gmt 0)

Wow, very long post. Sorry, but from:

Flash runs locally, fails after upload.


A very common problem with flash, several swfs and loading external swfs is, first the filenames being case sensitive including the extension .swf is not equal to .SWF . Also, use absolute paths instead of relative (../../flash.swf), replace it by domain.com/swf/flash.swf

good luck

Arizona




msg:4289718
 7:30 pm on Mar 30, 2011 (gmt 0)

Thank you, explorador... i'll try your suggestions and let you know if it changes anything. really, thanks a lot!

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / Flash and Shockwave
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved