0
return ok(views.html.index.render(Group.all(), groupForm));

I need a way for the framework to use index.scala.php file instead of the default index.scala.html file. The code above renders the html file but is there a way to use the php file instead. I want the play framework to use php files instead of html.

biesior
  • 55,576
  • 10
  • 125
  • 182
Nitrodbz
  • 1,276
  • 1
  • 15
  • 25

2 Answers2

0

I have absolutely no idea how this can be accomplished, but I imagine any hope of pulling off such a wild idea is to use the PHP/Java Bridge. You would have to rewrite the Play template rendering engine to generate HTML from PHP files.

Good luck with that.

Vidya
  • 29,932
  • 7
  • 42
  • 70
0

I have built a simple bridge between CakePHP and Symfony 2 Controllers, so I can try to provide some general approach. I can't provide specifics because I have never worked with Play personally, and you are bridging across different languages where I was not.

Definitely, take a look at the link @Vidya provided. It might provide what you need already, but I've never worked with it personally. Otherwise, I would avoid these alternatives and build your own.

I am sorry I don't have more details, but I hope this gives you an idea of what's involved.

Community
  • 1
  • 1
user2910265
  • 844
  • 1
  • 9
  • 15