How can I embed a java program in php file and what changes have to be done in php.ini file?
The better question, why would you want to?
If the program works perfectly fine why rewrite it? Anyway, OP you can’t embed java programs into the PHP process. [fphp]system[/fphp] and [fphp]exec[/fphp] can be used to call the programs and receive their returns (presuming they return a string), but be very, very careful with what you pass to those commands.
Streams can also be used to let programs talk to each other, I think.
I was more so thinking, if you have a program that already operates as a web application written in Java, why would you embed a working already capable web application in a PHP script? You wouldn’t, you’d allow it to be accessed like it was prior…
The question is a bit vague and may have a language barrier issue that isn’t quite describing what the user really wants to do…
That makes sense.