Website with Java algorithms embedded into the site [closed] - java

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
Hi I want to create a small web application which will take inputs such as 80 and 120 and return the GCD of those numbers. I want to write the logic in Java. When the user enters 80 and 120 and clicks on calculate button, the values must be passed to the algorithm and return the answer to be displayed on the application again. How do I link the java algorithm to the html page in order to achieve this? Kindly suggest. Is there no other way of doing this other than creating a Java applet for this and deploying it on the application? Kindly help.

Use "Applets" if you want the Java code to run in the users browser and not on a remote server.
Applets are, however, a waning technology due to the numerous attacks that has gone through the JVM to avoid the security checks in the browser, so your users will most likely not see the experience you want them to. Additionally I believe that the ability for the Java program to interact with its surrounding page has been crippled again for security reasons.
Your best bet is to use Java for server side code only (which it is quite fine for - Google Application Engine is perhaps the easiest way to get started) and to use JavaScript for client side code.

Related

How to hide javascript with cryptography? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I am looking for method to hide my plugin's javascript with complex obfuscator but i read everywhere that it is not possible to hide javascript completely.
I want to know that is there any way to hide java script with cryptography?
can any one make the algorithm which can be adopt by every web hosting like they have php , jommla, java, magneto etc in which we can encrypt our javascript with our own secret key and we add this key in our license manager in our hosting and on user side we can add license manager client in our applications which need to connect our server and get that key to run our application.
Doing this would be almost exactly like deobfuscating the code. If you obfuscate the code, and provide it only on pages when you're logged in, then this would accomplish pretty much the same task. At some point, you'd need to fetch this key to decrypt it to run it on the client, and when that happens, someone can easily reverse engineer the decryption code and get to the code that's being run on the client side.
Simply put: If it's run on the client side, at some point, you'll have to get it into a state that the compiler can read. At this point, someone can inject code to fetch that code, and reverse engineer the output.

Web browser applications program language? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I would like to write various web browser games and apps to post to my own personal website, mostly for fun. I'm pretty familiar with Java and starting to get into C a little. As I understand it, I cant just run a common java application from a web browser but have to use the JApplet class or Applet class(or possibly others.) Can I use a JApplet to make fairly sophisticated games or is it really just for basic display images? I'm willing to learn something completely outside of Java.
I've been browsing the web but am a little overwhelmed in deciding how I should go about this. I would like to make games that are pretty simple graphically, but can remember things like a characters inventory.
Its really just a place to host different games and things I make. How should I go about this?
I hope this isn't too vague.
The only language you can guarantee within a web browser is JavaScript. You can write highly sophisticated games using JavaScript, so this shouldn't be a major problem - you can see an example written using Unreal Engine and JavaScript on YouTube.

Connecting and fetching data from mysql using angularjs [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I am new to angularjs , can anybody guide me in performing CRUD operations in MYSQL and display in html form using angularjs... to be more precise... I want to store information to customer details such has name,consumer number,contact,address and update the same whenever necessary using java..
Hello and welcome to SO,
I created this diagram in order to make you feel more comfortable with the subject.
As you may see I didn't mention any language: Client, Server nor Database, because the language itself has nothing to do with REST APIs.
Instructions - begginer:
(If you are using PHP, I'd recommend SlimFramework, which is the light, scale, easy to start with, PHP Framework).
1) Pick a server-side language.
2) Create a Database Resource.
3) Pick a Server Side Language.
4) Create 4 Scripts that each does one of each:
Create,Read,Update,Delete.
5) Connect endpoints with each of the scripts, URL -
GET,POST,DELETE,UPDATE.
6) Verify that you can access each of them from the web (authenticated
or not).
7) After you verified that endpoints are working, time to connect
Angular:
7a) First try to create buttons for each action, and link it with
$http.get, $http.post, $http.delete, $http.put actions.
7b) Once it's working you might wanna step up and use ng-resource or
restangular.
P.S: I didn't supply much code information since once you understand what I stated on top, you'd realize that writing code for that isn't really hard.
After you complete these ,
You might wanna start with: Server side and Client side authentication, Performance, Multiple resources and collections, CORS and preflighted requests, and so on.
Good Luck.

Server side application [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
for my new project I need to write server-side application that will serve some of simple requests. I have no experience of writing server-side application, so I need some advice.
The problem is that I don't know how to start; I've spent couple of hours searching google for some guidelines, but I got nowhere.
I need to write application that will ran on the server (I've installed Ubuntu server in VirtualBox and used briged connection, so I can access it from my network) and will serve some requests:
connnect to server
authorize user (check user and his pass in db)
store some data in db on connection (for example IP address)
I am not sure which language would be best to use and what do I need to know to implement that app. This is my private project, which I came up with to learn something new; until now I have always written apps that ran locally (usually in Java/C/Python).
I've seen some tutorials on PHP and Django, but I am not sure if I am going in the right direction.
Thanks in advance for all help :)
I would prefer to you meteorjs look at www.meteor.com the reason why im prefering this to you is that i was in the same position as you one month ago and i,m amaized with meteorjs. Also have a look at derbyjs. This frameworks are built on top of node.js it allows you to write only javascript end to end.
Look at install.meteor.com you will find a quick install bash file.
At the end you can do this with any of the languages you mentioned. Write with what you like the most.

Java back-end and JavaScript front-end, how to join? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
I'm new to creating a web application with a Java back-end and a JavaScript, HTML 5 front-end. How do I pass content between the two?
You are looking for a web framework. These will integrate all three technologies you mention into a server and fully functioning webapp. You will also need to be working with JavaEE.
I recommend Jetty or Play
Look up some tutorials on how to get started but basically these frameworks will create the server backend that launches on a port and can host different sockets etc... and since theyre in Java the backend code can literally be written anywhere in the project...front end is easy too, you'll see how it works once you work through your first tutorial with them :)
Java EE is what you need indeed.
on a back end you add end points, and on front end you hit those end points w/ ajax

Categories

Resources