Replace flash with jquery / html5

I have a project using flash for most pages. Now the client wants to replace the flash with jquery / html. So where should I start?

The project has a swf file and it is embedded with swfobject (javascript). Can someone help me give an idea or steps, how can I convert swf to javascript / html?

+4
source share
3 answers

If Flash does not contain a lot of animation / dynamic interaction, I would say that you should follow the following process:

  • Create HTML documents in which content is structured in a simple, consistent format. If you do not know how to do this, I suggest you familiarize yourself with some basic principles related to semantic markup (Google is your friend here, there are a lot of great resources, but here is the starter with which I just came across ). Don't worry about elements that are related to animation or special user interactions at this point - just set aside some of your HTML where you need to look for those elements now
  • Use CSS to compose the structure of the document with the desired appearance. Take it one step at a time - starting with the largest elements on the page and paving the way for the smallest (I believe this is the best way to build your UI reliably, although others may approach it differently).
  • Once your main pages are well structured and looking good, you need to focus on animated / interactive aspects. The easiest way to do this is to use other people: jQuery plugins. Determine which functions you need and find plugins that already provide this functionality (i.e. you mentioned the slide show function - Google for "jQuery slide show" and play around with the parameters - there will be many).

Actually, if you are not familiar with HTML / CSS / JS, this will not be an easy task for you. Here are a few other considerations that might help you:

  • First, focus on the structure of the content: if you understand this correctly, everything else builds on top of it with much less pain. In addition, Google really loves a good document structure, so this will be a very small way to get search results ranked on a site.
  • Don't worry too much about HTML5: except that you need to do extra work to make it fully compatible with the browser (at least if you need more compatibility with the browser), it just doesn't really need to use elements like nav or video (unless your client allows Flash video, but this is for another discussion.) Don't bite off more than you can chew.
  • Be consistent, this is related to the first paragraph above - if you consistently apply a structure to your elements in all your documents, you can more easily take advantage of the same CSS and JS.
  • Regarding the w3schools comments elsewhere on this page, I would say that you should not use them for tutorials - but they can be a useful reference source for learning HTML elements and CSS attributes and rules (although there are many other sites that may help here).

Ok, hope this helps you. Sorry, I cannot be more specific, but I need a much more detailed description of your problem before I can give you much more ... Good luck.

+2
source

1) Explore Flash (I hope you have achieved this)

2) Learn Javascript. Learn html5. There are many resources and tutorials.

3) Take the source of the flash project. Read it and slowly rewrite it in javascript.

4) After you have translated the project, it may be suboptimal. Think in javascript to change some flash-like constructs to javascript-like ones. Do a little optimization until you are satisfied with the results.

0
source

Have you tried Wallaby or Swiffy ? Adobe reacts to the death of excessive use of Flash in other ways .

0
source

Source: https://habr.com/ru/post/1392550/


All Articles