'java -version' command in CMD - java

When I run the 'java -version' command in Command Prompt, then it gives me the following information:
java version "1.7.0_01"
Java(TM) SE Runtime Environment (build 1.7.0_01-b08)
Java HotSpot(TM) Client VM (build 21.1-b02, mixed mode, sharing)
Can I run a web page that hosts a Java Applet properly?
P.S.: I'm using Windows 7 32 bit.

You don't need Java installed on the server to host a Java applet. Applets are executed on the client side. Apache server (do not confuse with Apache Tomcat) or similar is enough.

Related

why Spring tool suite IDE shows error message as "JVM terminated. Exit code=127"

I tried to install spring-tool-suite 4.1(64 bit) on Cent OS-7, when i try to run installer, it shows message like "JVM terminated. Exit code=127"
I have a latest 16.0.2(64 bit) JDK version,
Edited the .ini file with correct jdk path, but still it shows the same error message
I faced the same problem while using eclipse installer also, tried the given solutions in stack overflow, none of them worked
This is the version I am using:
java -version
java version "16.0.2" 2021-07-20
Java(TM) SE Runtime Environment (build 16.0.2+7-67)
Java HotSpot(TM) 64-Bit Server VM (build 16.0.2+7-67, mixed mode, sharing)
Make sure
using a 64 bit Java VM of the same architecture to run Eclipse (in your case x86_64) and
on Linux having GTK 3.20 or higher.

Apache not aware of window path variables?

I am trying to do the same as this guy. I want to be able to get a result when I do this:
$javaExec = shell_exec('java -version 2>&1');
var_dump($javaExec);
However, all I get is:
'java' is not recognized as an internal or external command,
operable program or batch file.
If I run "java -version" from the command line (i.e. cmd), I get:
java version "1.8.0_65"
Java(TM) SE Runtime Environment (build 1.8.0_65-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.65-b01, mixed mode)
But I can't get PHP/Apache to get the same result. Is there something I need to do to make Apache aware of the path environment variables?
I tried restarting Apache and my PC, but unfortunately no luck. Any ideas?

Unable to execute jshell from Mac Terminal

I am currently using java 1.8 on my Mac Sierra.
java -version
java version "1.8.0_51"
Java(TM) SE Runtime Environment (build 1.8.0_51-b16)
Java HotSpot(TM) 64-Bit Server VM (build 25.51-b03, mixed mode)
Now I want to run "jshell" for executing simple java commands right from the terminal. But I ended up with the following error message -
Unable to locate an executable at "/Library/Java/JavaVirtualMachines/jdk1.8.0_51.jdk/Contents/Home/bin/jshell" (-1)
What is the workaround do I need to do for avoiding this error message ?
As pointed out by #Elliott, you need to download and install Java-9 for working with jshell.
Once you have set the environment variable to make use of the /jdk../.../bin directory. You can execute the command jshell on your command line to get going.

JWplayer suddenly not working - says Java not installed, but it IS (playback issue)

I was using openjdk 7, then all of a sudden I wasn't able to stream a video with JWplayer. I tried setting $PATH in Ubuntu 14.04 among lots of other things until I just gave up and purged openjdk completely. I installed Oracle 8, and I still get the same issue.
$ java -version
java version "1.8.0_20"
Java(TM) SE Runtime Environment (build 1.8.0_20-b26)
Java HotSpot(TM) 64-Bit Server VM (build 25.20-b23, mixed mode)
The videos just say that Java is not installed, to install it and restart my browser, etc.
This is extremely frustrating. Any ideas?
JW Player does not make any use of Java at all. It is a script written in Javascript, which is simply part of your browser.

Why is JRE version different in Browser Applet than it is using Java -version? [duplicate]

the Safari browser says I am running 7 -
But the command line says I am running 6:
[~/prg/ceylon-dist/samples/helloworld]$ java -version
java version "1.6.0_43"
Java(TM) SE Runtime Environment (build 1.6.0_43-b01-447-11M4203)
Java HotSpot(TM) 64-Bit Server VM (build 20.14-b01-447, mixed mode)
[~/prg/ceylon-dist/samples/helloworld]$
I checked /System/Library/Frameworks/JavaVM.framework/Versions/ and nothing there shows a 1.7 version at all.
It's usually because the web version is a plugin to your browser, whilst java -version check the environment variable $JAVA_HOME$ and executes it with -version. So you will have to check your plugins for your browser.

Categories

Resources