Quick Flash Question

Discussion in 'Web Design and Development' started by davisjw, Apr 27, 2009.

  1. davisjw macrumors regular

    davisjw

    Joined:
    Jul 28, 2006
    Location:
    Richmond, Va
    #1
    Sorry to bother again but I have a very easy question I need answering but have yet to find a tutorial because I have no idea what to call it.

    I'm designing my personal site and need to have the links change color when the cursor is over them. I.e. I have a bubble letter with an outline that when the cursor is off it the bubble letter will be filled but when the cursor is over it the outline will be filled in but not the letter (it just reverses the effect as such).

    I have both variations of the letters done up in Illustrator but looking through Google I've only managed to find tutorials on making movies that change and changing the cursor's color.

    Either a phrase I can use to search for a tutorial or a posted tutorial would be fantastic! Thanks in advance!
     
  2. samwich macrumors regular

    Joined:
    Aug 5, 2007
    #2
    Sounds like all you want to do is create a button.

    go to insert > new symbol
    choose button, and name it something meaningful
    in the timeline you will now see four frames with the labels "up,over,down,hit"
    import your illustrator files into your library and drag an instance of the corresponding button state onto the correct frame
    ex. drag the normal state onto up
    put the image that you want to appear on the "over" frame
    if you want you can put an image on for when the mouse is pressed down on the button
    you probably won't have to worry about the over state

    back in your main movie drag your completed buttons onto stage, give them an instance name and set up the click events for the navigation
     
  3. davisjw thread starter macrumors regular

    davisjw

    Joined:
    Jul 28, 2006
    Location:
    Richmond, Va
    #3
    Thanks for the help but you say put it on the "over" frame but then say you won't have to worry about the over state... Did you mean not to worry about the "hit" state? Thanks!
     
  4. samwich macrumors regular

    Joined:
    Aug 5, 2007
    #4
    whoops typo

    yea the over state is what will appear when the mouse hovers over the button

    the hit state is a little hard to explain, but it defines the area in which the clickable region of the button can occur. So for example, if you have a button that is pretty small, but you still want users to be able to easily click it, you might put a larger rectangle shape in the hit state of the button. The hit state will never be visible, but anytime the user puts his mouse over that larger area defined by the hit state, the button will be fully functional
     
  5. davisjw thread starter macrumors regular

    davisjw

    Joined:
    Jul 28, 2006
    Location:
    Richmond, Va
    #5
    Thanks for the help! I've moved everything into Dreamweaver (decided it's best to kill two birds with one stone and while I'm learning Flash I can dump myself into DW!)

    Now I'm at another question; I want to create a Flash movie of something coming down on the right hand side when something is clicked as almost a separate window into itself with clickable thumbnails. It's a portfolio site so I want the effect to be a window coming down, a big jpeg and then smaller jpegs on the side that when you click it becomes the big one. Any chance you can help with that? Sorry about all the questions!
     
  6. pelsar macrumors regular

    Joined:
    Apr 29, 2008
    Location:
    israel
    #6
    flash animation.....

    you do that animation in flash...save it as a swf and import it into DW, making sure that its "z" (floater level") is above the rest of the page. The links will have to be built in to flash or if you know xml, put into an xml file (preferable)

    doing the animation is what flash is all about, cant really help you here about that
     
  7. davisjw thread starter macrumors regular

    davisjw

    Joined:
    Jul 28, 2006
    Location:
    Richmond, Va
    #7
    Cheers, I didn't know if I could bring the animation into DW and do the links there. I'll find some tutorials to finish the animation in Flash; thanks!

    Having a difficult time combining the two though. Any thoughts on brining in a Flash file to Dreamweaver where the animation says for each link a picture comes down holding something and then back up and bringing down another when another link is clicked. In Flash would I have to program each individual link and find a tutorial that told me how to link all of them?

    Or have each link a separate file and bring them individually into DW and link them all into it.

    I'm useless in anything but basic animation with Flash. I can do the hand coming down with something but programing it to go back up and bring something else down is beyond me at the moment. Another tutorial search I guess!
     
  8. pelsar macrumors regular

    Joined:
    Apr 29, 2008
    Location:
    israel
    #8
    flash actionscript....

    it sounds like our going to have little choice but to learn actionscript...flash as an animation program has its limits without programming knowledge..and it sounds like your ideas are going to require that.

    in the meantime you can buy animations at places like flashden http://flashden.net/
     
  9. davisjw thread starter macrumors regular

    davisjw

    Joined:
    Jul 28, 2006
    Location:
    Richmond, Va
    #9
    Ok so my next problem. I inserted the flash into my Dreamweaver document and I can't for the life of my figure out how to move things so I can position it dead in the middle. I have a few buttons on the left and I can't get it level with those but towards the middle. Here's my code and I apologize for the length of this, I'm assuming it's something really simple I'm just not seeing as I know you move it somewhere in the code but I can't find where it says it's being placed to move it. Thanks for your time again.

    <html>
    <head>
    <title>Link_Light</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <script type="text/javascript">
    <!--
    function MM_preloadImages() { //v3.0
    var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a.indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a;}}
    }

    function MM_swapImgRestore() { //v3.0
    var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a)&&x.oSrc;i++) x.src=x.oSrc;
    }

    function MM_findObj(n, d) { //v4.01
    var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
    if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[n];
    for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers.document);
    if(!x && d.getElementById) x=d.getElementById(n); return x;
    }

    function MM_swapImage() { //v3.0
    var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
    if ((x=MM_findObj(a))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
    }
    //-->
    </script>
    <script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
    </head>
    <body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onLoad="MM_preloadImages('Links_Dark/Link_Light_03.gif','Links_Dark/Link_Light_07.gif','Links_Dark/Link_Light_10.gif')">
    <!-- ImageReady Slices (Link_Light.psd) -->
    <table id="Table_01" width="200" height="401" border="0" cellpadding="0" cellspacing="0">
    <tr>
    <td width="200" height="99" colspan="6">
    <img src="images/spacer.gif" width="200" height="99" alt=""></td>
    </tr>
    <tr>
    <td width="31" height="301" rowspan="6">
    <img src="images/spacer.gif" width="31" height="301" alt=""></td>
    <td colspan="4">
    <a href="home.htm">
    <img src="images/Link_Light_03.gif" alt="" width="143" height="42" border="0" id="Image1" onMouseOver="MM_swapImage('Image1','','Links_Dark/Link_Light_03.gif',1)" onMouseOut="MM_swapImgRestore()"></a></td>
    <td width="26" height="301" rowspan="6">
    <img src="images/spacer.gif" width="26" height="301" alt=""></td>
    </tr>
    <tr>
    <td width="143" height="28" colspan="4">
    <img src="images/spacer.gif" width="143" height="28" alt=""></td>
    </tr>
    <tr>
    <td rowspan="2">
    <img src="images/Link_Light_06.gif" width="3" height="68" alt=""></td>
    <td colspan="2">
    <a href="ads.htm">
    <img src="images/Link_Light_07.gif" alt="" width="96" height="42" border="0" id="Image2" onMouseOver="MM_swapImage('Image2','','Links_Dark/Link_Light_07.gif',1)" onMouseOut="MM_swapImgRestore()"></a></td>
    <td width="44" height="231" rowspan="4">
    <img src="images/spacer.gif" width="44" height="231" alt=""></td>
    </tr>
    <tr>
    <td width="96" height="26" colspan="2">
    <img src="images/spacer.gif" width="96" height="26" alt=""></td>
    </tr>
    <tr>
    <td colspan="2">
    <a href="pr.htm">
    <img src="images/Link_Light_10.gif" alt="" width="64" height="45" border="0" id="Image3" onMouseOver="MM_swapImage('Image3','','Links_Dark/Link_Light_10.gif',1)" onMouseOut="MM_swapImgRestore()"></a></td>
    <td width="35" height="163" rowspan="2">
    <img src="images/spacer.gif" width="35" height="163" alt=""></td>
    </tr>
    <tr>
    <td width="64" height="118" colspan="2">
    <img src="images/spacer.gif" width="64" height="118" alt=""></td>
    </tr>
    <tr>
    <td>
    <img src="images/spacer.gif" width="31" height="1" alt=""></td>
    <td>
    <img src="images/spacer.gif" width="3" height="1" alt=""></td>
    <td>
    <img src="images/spacer.gif" width="61" height="1" alt=""></td>
    <td>
    <img src="images/spacer.gif" width="35" height="1" alt=""></td>
    <td>
    <img src="images/spacer.gif" width="44" height="1" alt=""></td>
    <td>
    <img src="images/spacer.gif" width="26" height="1" alt=""></td>
    </tr>
    </table>
    <h1>
    <!-- End ImageReady Slices -->


    <script type="text/javascript">
    AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0','width','550','height','400','align','middle','title','Ad_Album','src','Ad_Album','quality','high','pluginspage','http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash','movie','Ad_Album' ); //end AC code
    </script>
    <noscript>
    <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="550" height="400" align="middle" title="Ad_Album">
    <param name="movie" value="Ad_Album.swf">
    <param name="quality" value="high">
    <embed src="Ad_Album.swf" width="550" height="400" align="middle" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash"></embed>
    </object>
    </noscript>
    </h1>
    </body>
    </html>
     
  10. pelsar macrumors regular

    Joined:
    Apr 29, 2008
    Location:
    israel
    #10
    replace....

    <table id="Table_01" width="200" height="401" border="0" cellpadding="0" cellspacing="0">

    with this:

    <table width="200" height="401" border="0" align="center" cellpadding="0" cellspacing="0" id="Table_01">

    its in the properties window of DW where it has an alignment option, you highlight your outside table then in the properties window find alignment, and choose center.
    ____

    and just for the record...using tables is considered a "no no'......eventually you're going to have to learn css
     
  11. davisjw thread starter macrumors regular

    davisjw

    Joined:
    Jul 28, 2006
    Location:
    Richmond, Va
    #11
    Thanks for the help but moving the links (tables) wasn't the issue. The issue was moving the flash file which is the second bit of coding... When I put in your code it only moved the links to the middle... And under alignment I don't see Center, I see Middle but that does nothing.

    In relations to the tables, I built it using a quick tutorial from Youtube that had me doing it via Photoshop, this is a quick portfolio site I'm working on for a class but I'm defiently going to look into it as eventually I'd like to be able to create pages for fun. Thanks.
     

Share This Page