Klaus,
Publish settings is Javascript/HTML, with none of the 'other formats' (JPEG, etc.) boxes checked.
I swear I already did 2 toolbars that worked in animate--one is at www.thirddcahistoricalsociety.org. I swear I made that one in animate, and using HTML5 canvas.
What else would I have used? And why wouldn't an html5 canvas button work ordinarily? It seems strange that I can make a button perfectly except for the last step...mostly, though, those toolbars didn't come out of the sky!
Patrick
Alright Patrick,
I had a look at www.thirddcahistoricalsociety.org at that what you always describe as toolbar. I dug myself into the structure and logic of your <object> element (Dreamweaver work I suppose) and came finally to your
NavigationBar
and from there to the code behind it:
http://www.thirddcahistoricalsociety.org/animation_assets/NavigationBar/Assets/NavigationBar.js
Since I asked you "how come that you are back to Actionscript?" - and you answered "I'm onto AS because I need animation for my page" I got a sense that you are unsure about the distinctions and similarities of both concepts.
So, in NavigationBar.js from your thirddcahistoricalsociety toolbar, definately a HTML5-Canvas-Javascript concept, you applied a code snippet from the HTML5 Canvas folder in Animate, and second, in your case of this post, you applied a code snippet from the Actionscript folder in Animate. Compare:
NavigationBar.js
/* Click to Go to Web Page
Clicking on the specified symbol instance loads the URL in a new browser window.
Instructions:
1. Replace http://www.adobe.com with the desired URL address.
Keep the quotation marks ("").
*/
this.movieClip_7.addEventListener("click", fl_ClickToGoToWebPage_7);
function fl_ClickToGoToWebPage_7() {
window.open("http://www.thirddcahistoricalsociety.org/Past_Events.html", "_blank");
}
and then your case of this post
/*Click to Go to Web Page
Clicking on the specified symbol instance loads the URL in a new browser window.
Instructions:
1. Replace http://www.adobe.com with the desired URL address.
Keep the quotation marks (""). */
mybtn.addEventListener(MouseEvent.CLICK, fl_ClickToGoToWebPage);
function fl_ClickToGoToWebPage(event:MouseEvent):void
{
navigateToURL(new URLRequest("http://www.adobe.com"), "_blank");
}
Can you spot the differences? And don't say the link to adobe.com, that's not the point here.
- the methods: window.open(..) as opposed to navigateToURL(..)
- the events: "click" as opposed to MouseEvent.CLICK bla
Hence if you would do the same in the case of this post as you did with NavigationBar.js, there wouldn't be any problems.
Apart from that I find it quite odd that every link in your toolbar opens in a new window or tab. That's quite unsual for links within the same domain/website. if you change the code snippet from
window.open("http://www.thirddcahistoricalsociety.org/Past_Events.html", "_blank");
to
window.location.href = "http://www.thirddcahistoricalsociety.org/Past_Events.html";
then it always opens in the same window or tab.
Klaus