0

Hey;
I have 6 months of work done in PHP and I really don't want to re-invent the wheel but I want to use some Ruby in my site. Is it possible to "mix languages" like PHP and ruby or will I run into some major problems? I would really appreciate your opinion. If your advice is helpful to my situation I'll add to your reputation.

3
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by codejoust
1

It's completely plausible, as long as you're not trying to mix the two into the same file (it'd still be possible, just inefficient, as it'd have to be processed twice). And, it depends on what kind of site you're trying to build. For example, if you're building a 'web-app' where a large number of your PHP scripts just return data, and are never actually 'viewed' by a user, then your life will be quite simple.

1

In short. No.
However, if, as noted before, you are using php files for data access, you can use pure ruby (or sinatra-like frameworks) to work with the data.
Rails will be extremely hard to mix code.
If your starting from scratch, learn ruby properly, and you won't need all that php code (if it's just crud code).
The whole idea of rails is to keep it clean, and what your suggesting isn't that clean. (would require a net://http to your own server, or using php command-line interface).

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.