How to put my website containing java on the web - java

I've made a dynamic web project in eclipse, and now I would like to put it on the web. Usually I'd just put the files on the web server, and it would run on my webpage, but this doesn't work when there's java involved.
Can anyone walk me through how to put a dynamic web project from eclipse on a real web server? I'm a complete newbie.

Related

How to ¿connect? a website and a Java App

This is just an introductory question for a problem that I'd be required to solve in the following weeks.
I have a website and a Java WebApp, both currently unrelated.
Website is BootStrap and Java App runs under Apache Tomcat.
The website is in one domain, and its core file is index.htm
The App is in other domain, and core is index.jsp, enclosed in a .war file
We will redesign the site , leave BootStrap and move to WordPress.
BUT, and this what I don't know how to do it, from the WordPress site I'd be required to LOGIN into Java App.
That is to create the typical user/pass miniform.
The web works at port 80, Java at 8080.... Any way, not being an expert is hard for me to imagine how to invoque Java Login from HTML, as the website is not going to be included inside the project.
I'm sure this is quite basic... Thank you!
It's a nice question you have.
I think the best solution is install a plugin in your wordpress project: **https://wordpress.org/plugins/json-api-auth**
with this plugin you can get a rest api login and then you only need to consume this api from your java application.

Java application for a server

I have created a JavaFX app, but it seems that servers do not support UI applications. What is the easiest way to develop Java apps for servers? (In other words, what solution does IntelliJ IDEA have? I don't want to rewrite a lot of code)
JavaFX is a technology for creating desktop (client) application on Java. These application are run on a local computer, that computer the user is currently interacting with.
There is Java WebStart technology. It lets us place the application .jar (java executable) on the server and call it via a link from a web page or direct URL. In this case the application will still be running on user's local computer. At the same time, application deployment can be easily managed, since the application executable is sitting on a single location on the server.
JavaFX works with WebStart, you will need to create a JNLP file. It is a descriptor of the application. Here is some info: Java WebStart
I hope this helps.
Java Web App? if I understand you, get my small advice.
You will have to rewrite all controllers, and change UI fxml forms to web pages (html + thymeleaf, jps, jsf and so on).
If you have bad project architecture, for example: you connect with database and retrieve data into controller classes, methods, it's so bad, and you will rewrite a lot of code.
But if it don't
You should just create web controllers, inject needed services, facades and call needed methods there.
Good luck)

Java/JSP : Making a executable Java working as webapp

I have a standard java project working local made by another person i know.
It's about data retrieving.
I need to develop a web app supposed to do the same thing but accessible by anyone via browser.
I CAN'T edit the code for that purpose, at least some implementation details. A kind of black box.
Can you suggest me the best approach to make a webapp based on a local executable app through JSP & servlet ecc?
Maybe you can try something like webswing.
What is Webswing ? Webswing is a web server that allows to run any swing application inside your web browser using only pure HTML5.
The best days of swing framework are gone. Desktop applications lost
popularity and everything is forced to be online and mobile. But what
about existing application? Using applet technology proved to be
insecure, rewriting the application to web technology is too
expensive. This is where Webswing can help you. With Webswing, your
application is securely running on server and user's browser only
displays the application window. All this without changing single line
of source code.

Using FreeTTS in a web application

I'm building a web application using HTML and JSP. One of the functionality which provided is converting some texts to speech. In netbeans, I created a Java project, this project contains a Java applet offers the speech task, this applet uses FreeTTS (external JAR file), and it works fine. So after building this project, I added its JAR to the web project, for embedding the applet within the web.
Now, the problem the applet doesn't work from the website, but it works standalone.
Please I need your help to fix this issue.
The FreeTTS developers recommend against using it in an applet, and suggest deploying it via Web Start instead. If it does indeed work fine standalone, that should fix your problem.
If you can't use Web Start, you could consider moving the audio generation to the server and running FreeTTS there.

Starting web programming in Java

I've been programming in PHP and ASP.NET for a while now. When doing PHP, I've always used XAMPP to test my websites. I'm wondering (since I'm learning Java) if there are equivalent services around?
Furthermore, I know this is sort of an open question, but how would you make a basic page in Java, just a basic 'Hello World' web page.
You can actually still use XAMPP. You just need to install tomcat. Here is a great screen cast on how to do it: http://www.youtube.com/watch?v=TUV_jPdq7fc.
If your a mac user you can try MAMP (whcih I prefer) and follow http://blog.mirotin.net/22/tomcat-on-mamp-the-simple-way. To get Tomcat going.
You might want to learn about programming in JSP and Servelets. JSP s are kinda like php in that they emit html out.
Also the server would be tomcat.
It would be best if you download Eclipse for EE developers. You can also try Netbeans. a sample servelet
You may read about servlets which is the basis for web applications in Java. There are many web frameworks built on top of them.
I always recommend Grails to anyone getting started with java/the web. It's more important to grasp the patterns, lifecycle, and working with requests and responses than learning the actual language. Learning Grails has got me from hobbyist developer to IT employee working with ATG - one of the most obscenely challenging web frameworks there are.
Grails includes everything you need to get started: local server, scaffolding (that's your ticket to Hello World), database access, dependency injection, the list goes on. It's built on top of Spring, Hibernate, Sitemesh, etc, which are all well-known and excellent frameworks that are being used in production.
Grails is written with Groovy, a language written on top of the JVM not far from Java.
Happy coding!
i seems to be new to the platform nd new to java but would like to suggest what i have gained till now that for developing a java page we can have any of the two servers downloaded(Weblogic or tomcat). weblogic is fully implementation of classes whereas tomcat has partial implementation. Then for the next step that we require is a source file(java file),and html file and a xml file and these all needs to be placed in a root directory as like the source file,html file and a folder named WEB-INF to be placed parallel.
Inside WEB-INF folder needs to create classes folder where our java class file will be kept.
then needs to create a .war file and deploy it over weblogic to get our desired page display.
thanks......

Categories