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.

1
  • Use some PHP framework in that case Commented Feb 18, 2014 at 22:37

2 Answers 2

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.

Sign up to request clarification or add additional context in comments.

Comments

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.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.