• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Struts 2 and PHP Integeration

 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

My web application currently using struts 2 frame work, it has got its sessions and works fine, I want use PHP as an interfcae to struts2, user provide all input in php form and my struts frame work executes with php inputs, and finaly php will read struts framework output and present data to user.

I have installed xampp intergated with tomcat and java bridge.

Can any one know how use php pages as an interfcae to struts actions

Thanks & Regards,
Arun
 
Ranch Hand
Posts: 65
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have no idea why you want to integrate Struts with PHP.
As i know PHP is a script language with can be used to build web sites.Do you want to migrate structs based web application in to PHP based web site.Refer http://www.phpwact.org/java/struts
 
Arun Ak
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi srinivas,

No I dont want to imgrate, I want to use php as an interface for user, php form accept user inputs and struts framework process it.

Regards,
Arun
 
srinivas srinivasmeenavalli
Ranch Hand
Posts: 65
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have never experienced this kind of approach. I would say you might need to have a bridge between PHP and Java .
Following URL has more details
PHP/Java Bridge
 
Bartender
Posts: 1210
25
Android Python PHP C++ Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Arun Ak wrote:Hi srinivas,

No I dont want to imgrate, I want to use php as an interface for user, php form accept user inputs and struts framework process it.

Regards,
Arun




Hi,

1. PHP (on Apache) gets the form input as HTTP POST and submits it to "process.do" (on Tomcat) as another HTTP POST.
2. "process.do" action processes and sends back HTTP response, which is received by PHP.
3. PHP sends back that response to browser.

Seems simple enough...or have I misunderstood the question?
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have no understanding why you'd want to do this--it's an unnecessary complication. Why mix two entirely different frameworks?
 
    Bookmark Topic Watch Topic
  • New Topic