웹디자인 강의
Flash Flash ActionScript 추가
2007.11.08 18:26
2강. 단원, 절, 페이지
http://218.37.27.142/~lectora/chung/lec_02/lec_02.html
렉토라에 플래시액션스크립트 추가
Go to Next Page: (Note: "invButton" is the button instance)
function gotoNextPage(event:MouseEvent):void
{
var url:String = "javascript:trivNextPage()";
var request:URLRequest = new URLRequest(url);
navigateToURL(request,"_self") ;
}
invButton.addEventListener(MouseEvent.CLICK,gotoNextPage);
Go to Previous Page: (Note: "invButton" is the button instance)
function gotoPreviousPage(event:MouseEvent):void
{
var url:String = "javascript:trivPrevPage()";
var request:URLRequest = new URLRequest(url);
navigateToURL(request,"_self") ;
}
invButton.addEventListener(MouseEvent.CLICK,gotoPreviousPage );
Writing/Editing a variable from Flash to Lectora.
getURL("javascript:VarVARIABLENAME.set('Yes')");
(Or whatever you want written to the variable...)
Showing/Hiding an image/object from Flash to Lectora.
getURL("javascript: OBJECTHTMLNAME.actionShow();");
(Or whatever you want the action to be "show, hide, etc"...)
http://218.37.27.142/~lectora/chung/lec_02/lec_02.html
렉토라에 플래시액션스크립트 추가
Go to Next Page: (Note: "invButton" is the button instance)
function gotoNextPage(event:MouseEvent):void
{
var url:String = "javascript:trivNextPage()";
var request:URLRequest = new URLRequest(url);
navigateToURL(request,"_self") ;
}
invButton.addEventListener(MouseEvent.CLICK,gotoNextPage);
Go to Previous Page: (Note: "invButton" is the button instance)
function gotoPreviousPage(event:MouseEvent):void
{
var url:String = "javascript:trivPrevPage()";
var request:URLRequest = new URLRequest(url);
navigateToURL(request,"_self") ;
}
invButton.addEventListener(MouseEvent.CLICK,gotoPreviousPage );
Writing/Editing a variable from Flash to Lectora.
getURL("javascript:VarVARIABLENAME.set('Yes')");
(Or whatever you want written to the variable...)
Showing/Hiding an image/object from Flash to Lectora.
getURL("javascript: OBJECTHTMLNAME.actionShow();");
(Or whatever you want the action to be "show, hide, etc"...)