Convert interactive flash animation to javascript to use in html5 - javascript

Hi,
I have a banner on my site made in flash. Its an animation that ends with a sequence showing buttons which the user can click to navigate to inner pages. Since flash seems to be dead soon I would like to replace that with html5 friendly code. Is it possible to have a program such as Adobe Flash CS5 to convert the full movie for me into javascript code? Or I have to write the javascript all by myself from scratch?
Thank you.

You can use Flash CC to publish you flash file into HTML canvas base structure. Steps -
Open file in Flash CC select commands->Convert to other Documents.
Folder Select HTML 5 Canvas from Dropdown and press OK. Now open
newly created Flash file and publish. It will give you the canvas
base html file.
The html and javascript you get is in organized format and you can even edit code as well.
Hope it solve your problem.

Related

Necklace Mockup Tool in JavaScript does not always work as expected

I am using Shopify and a script located at https://app.cjdropshipping.com/static/shopify/pod/pod.js to generate mockups for a necklace product. You basically need to upload a photo and then it takes it and sends it to the server to generate a front and back side cover.
Well, this script does not always work on mobile.
You can try the mockup tool at https://purfectgifts.com/products/petnecklace as well as analyze it.
It does not always capture the whole area of the uploaded image dimensions and does not put the generated image instead of the original product image.
I need to have this fixed for mobile (iPhone & Android). It works better on Desktop.
I think this issue about the script has to do with how it loads itself...
Please help me out with this. You can make me the happiest person in the world if you can help me with that.
I am not a programmer but I tried to change how the script loads.
I think the issue is about how the script is loaded.
I appended the following code right above the closing body tag:
<script type='text/javascript' async=false defer=false src='https://app.cjdropshipping.com/static/shopify/pod/pod.js'></script>

Do not autoplay animation in knitr html

I am creating an html presentation using slidify (which in turn uses knitr) in which I am incorporating an animation displayed via scianimator (i.e. by setting the knitr options opts_knit$set(animation.fun = hook_scianimator)). This all works perfectly. However, the animation starts autoplaying as soon as the html is loaded. This is caused by the generated javascript code .scianimator("play");. Of course, I can delete this manually from the html file. But my goal is to generate the complete html presentation automatically without the need for manual corrections in the html file. Is it possible to set knitr options, redefine the hook_scianimator function, or some other approach in order for this to work?
So that others can reproduce this: I've put my source package here http://www.let.rug.nl/wieling/statscourse/lecture5/lecture5.7z
If it is unzipped and the html file is opened in a browser (Chrome, Firefox), the animation op slide 16 is already playing (it starts when the html file is loaded). The original markdown/slidify source is index.Rmd in the same archive.
Note that if I upload the data to a webserver: http://www.let.rug.nl/~wieling/statscourse/lecture5/#16, the Scianimator animation does not play at all.
Any help would be very much appreciated!

Embedding .rh 3d models in html for interactive display

I have to embed the 3D models (format: right hemisphere) in the HTML page (WebHelp). The 3D player has to be embedded in the page/browser, rather than being a pop-up page.
In other words, to act like a YouTube video player embedded in the HTML page, showing a lightweight splash screen or multimedia thumbnail, that you can turn into full screen.
I am not able to follow on how to use the SAP VisualEnterpriseViewer to accomplish this. Otherwise, can we use javascript for this purpose? I know that jsc3d does not support .rh format yet.
Please help.
Thanks
No one can support .rh format, except RH/SAP. It is a closed, proprietary format. And forget about html5, canvas, webgl etc. These are too open, SAP / RH have traditionally created data silos rather than working off of open standards.
SAP VEV , formerly DeepView, does have a complete JS interface. The viewer doesn't have to be a popup. Look in the docs, you can embed the viewer in a page, and disable all the menus etc through appropriate javascript calls. The docs are distributed with the viewer sdk, however it is getting rather hard to come by now. Also helpful, and included with the docs, are examples.

Dragging and dropping images from Firefox into Microsoft Powerpoint

I am trying to make a web page which allows users to drag and drop images into Microsoft Office applications, specifically Powerpoint.
By default (as of FF3.5), Firefox will insert the source URL when an image is dropped rather than the image itself. After adding the following Javascript/jQuery code (derived from https://developer.mozilla.org/En/DragDrop/Drag_Operations),
$('img').attr('draggable', true).bind('dragstart', function (event) {
event.originalEvent.dataTransfer.effectAllowed = 'copy';
});
dragging and dropping works from Firefox to Word and Excel, but not to PowerPoint. For an example of what happens, see http://slides.html5rocks.com/#drag-and-drop. I have tested this with FF3.6 and FF9.
How can I make it work with PowerPoint?
Just drag'n'drop outside the boundaries of the ppt slide (to make sure you're not dropping on a predefined textbox) - and release the mouse button -no coding needed!
Firefox drag will drop the image at the center of te ppt slide.
Status quo
Sadly there is nothing you can do from within your browser and the application to enable drop support for PowerPoint.
This is something that needs to supported at source level in PowerPoint (and it seem to be if you don't drop the image on an existing element but right outside the slide frame you want to drop it onto - but probably depending on version).
If it (for some reason still) does not support the image part of the drop but just the link (and if there is no option provided for changing this behavior) there is little to do but to hope Microsoft will update PowerPoint with this support in the future, - or - check the following options for work-arounds if needed:
Add-ins
You can look into writing an add-in (or possibly just use a macro - you might need to lower security to medium [PDF] for macros) for PowerPoint that will take the link that is dropped and replace it with the image the link refers to.
Here is one place to get you started making add-ins if this is a viable option.
Here is a commercial framework that makes creating add-ins very simple.
(disclaimer in this regard: I am here assuming this will be possible due to add-ins such as this which allow you to show a live web page inside PP).
Pipe-line / work process
There is also the option of injecting a third-party applications in the pipe-line to do screen snapshots of the image and have it inserted automatically into PP.
SnagIt is such an application (and there are probably others) and it has free extensions that will allow you to integrate "snags" directly with PowerPoint.
Or (the perhaps too obvious option): simply copy the image in browser and paste it into PowerPoint.
What is your version of Powerpoint?
It's very important because image format support may be lacking.
If that's the case your code needs a minimum version warning addition.
Could also ask to convert image to suitable format.
It may even be the case that it's impossible to the version of Powerpoint you're using to support this in the way you want.
You could try to use html code.
This code might help you:
http://classroomtech.org.uk/2008/08/drag-and-drop-in-powerpoint/
Other possibilities are OLE object with a link to a image.
Could check how other Microsoft applications, that do something similar, handle things.
If that doesn't work you could try to generate an OLE object with a link to the image in it.

How can I get the mediaelement.js to work in a popup window?

I got the Media Element JS player to work, but when I tried to get it to play in a pop-up, I noticed that it breaks the popup. It looks like I can't call JavaScript inside a JavaScript. My popup is pretty simple, it just does window.open and uses document.write with code to build a new page with its own style sheet. However, I can't load the mediaelement.js stuff inside that. Maybe I should just load the Flash that comes with it? There's also a silverlight file.
Can someone please help? I need a player that doesn't require an XML file for the playlist, works in all browsers, plays MP3s and has a timer on it. I've been working on it all day to no avail!
if you're document.writing into a new window you should be able to write a call to an external js file and that should run. Can you post the code you're using?
also why not just window.open('http://yoursite.com/path/to/an/html/file.html') instead of document.writing to it. This would be cleaner and would maintain the separation of structure and behavior.

Categories