Html Codes: Canvas- Protect Javascript Source Code by using PHP and Ajax
This is an important question: "If I create a wonderful graphics by HTML5 Canvas and Javascript, how can I protect my source code?". I have searched about it but no satisfying answer was found. So I've decided to create a way for protecting sources of HTML5 Canvas and in general Javascript codes. In fact, the algorithm can be protected not the whole source. The procedure is that I have designed a PHP script which performs calculations and loops, and the results are called by Ajax. The following example is just our previous plotter, but, the graph points and lines are calculated and generated by PHP, called by Ajax, and then it is drawn by Javascript in the Canvas element. So each user can just achieve its own graph code, not the whole grapher script. The PHP source is also given below.
It's great, isn't it? Use for free but do not forget a link to us!
It's great, isn't it? Use for free but do not forget a link to us!
If you don't know how to use this code or need more information Click here!
Sources: Download
![]() | You can leave comments once you sign in/up. |