# 'Coming from' rails...to php, help

**URL:** <https://www.ruby-forum.com/t/coming-from-rails-to-php-help/111103>\
**Category:** Rails\
**Created:** [August 2, 2007, 6:20pm UTC](https://www.ruby-forum.com/t/coming-from-rails-to-php-help/111103 "2007-08-02T18:20:36Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![blinking\_bear](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/a9a28c/32.png) [@blinking\_bear](https://www.ruby-forum.com/u/blinking_bear)\
**Post date:** [August 2, 2007, 6:20pm UTC](https://www.ruby-forum.com/t/coming-from-rails-to-php-help/111103/1 "2007-08-02T18:20:36Z")

</div>

I have to put together a quick proposal for a site that, for now, is set  
to  
be PHP. Hopefully we can change that, but I could use some help with  
PHP  
best practices. Are their PHP equivalents for Test:Unit, autotest,  
capistrano…? basically I just need some buzzwords for this meeting  
before  
we make them drink the rails Kool Aide.

Thanks

---

<div class="post-metadata">

**Author:** ![blinking\_bear](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/a9a28c/32.png) [@blinking\_bear](https://www.ruby-forum.com/u/blinking_bear)\
**Post date:** [August 2, 2007, 7:12pm UTC](https://www.ruby-forum.com/t/coming-from-rails-to-php-help/111103/2 "2007-08-02T19:12:49Z")

</div>

On Aug 2, 2007, at 12:19 , blinking bear wrote:

> I have to put together a quick proposal for a site that, for now,  
> is set to be PHP. Hopefully we can change that, but I could use  
> some help with PHP best practices. Are their PHP equivalents for  
> Test:Unit, autotest, capistrano…? basically I just need some  
> buzzwords for this meeting before we make them drink the rails Kool  
> Aide.

PHP has PHPUnit and Phing - and as noted on other threads the Symfony  
framework has some rails flavor to it as well.

The difference from my experience as a PHP-\>Rails convert, is that  
you can do a lot of the same things in PHP but you have to take a  
build-it-yourself attitude; whereas Rails, RSpec and Capistrano give  
you so much more right out of the box.

Here’s a funny story for you guys - I’m working on a huge PHP project  
right now, and I’m using Rails on my macbook (on the sly, of course)  
to manage changes to the datamodel with migrations. I hope none of  
those guys read this list.

- mitch holds a pinkie up to the corner of his mouth

---

<div class="post-metadata">

**Author:** ![blinking\_bear](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/a9a28c/32.png) [@blinking\_bear](https://www.ruby-forum.com/u/blinking_bear)\
**Post date:** [August 2, 2007, 8:38pm UTC](https://www.ruby-forum.com/t/coming-from-rails-to-php-help/111103/3 "2007-08-02T20:38:05Z")

</div>

On Aug 2, 1:11 pm, Mitch P. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> PHP has PHPUnit and Phing - and as noted on other threads the Symfony  
> framework has some rails flavor to it as well.

Symfony is very Rails-ish but (like you) I wish it had migrations…

Its also had its own testing framework (Lime) for some time.

There is some built-in support for deployment and syncing to  
production servers.

But Im now looking at using Capistrano to deploy our PHP apps 😉

> Here’s a funny story for you guys - I’m working on a huge PHP project  
> right now, and I’m using Rails on my macbook (on the sly, of course)  
> to manage changes to the datamodel with migrations. I hope none of  
> those guys read this list.

Damn, wish I had done that from day one!

–

---

<div class="post-metadata">

**Author:** ![blinking\_bear](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/a9a28c/32.png) [@blinking\_bear](https://www.ruby-forum.com/u/blinking_bear)\
**Post date:** [August 7, 2007, 11:05pm UTC](https://www.ruby-forum.com/t/coming-from-rails-to-php-help/111103/4 "2007-08-07T23:05:07Z")

</div>

Thanks for the feedback… we got the project. Now…wanna build it?

---

<div class="post-metadata">

**Author:** ![blinking\_bear](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/a9a28c/32.png) [@blinking\_bear](https://www.ruby-forum.com/u/blinking_bear)\
**Post date:** [August 8, 2007, 3:49am UTC](https://www.ruby-forum.com/t/coming-from-rails-to-php-help/111103/5 "2007-08-08T03:49:35Z")

</div>

Just for interest sake. There is PHP on Trax, it is syntacticly  
equivalent to RoR but using php code… [http://www.phpontrax.com](http://www.phpontrax.com)

I don’t know how active its dev is?

---

<div class="post-metadata">

**Author:** ![blinking\_bear](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/a9a28c/32.png) [@blinking\_bear](https://www.ruby-forum.com/u/blinking_bear)\
**Post date:** [August 2, 2007, 9:03pm UTC](https://www.ruby-forum.com/t/coming-from-rails-to-php-help/111103/6 "2007-08-02T21:03:10Z")

</div>

Capistrano is definitely not a Rails-only solution. You definitely  
should  
use it for PHP deployment. Heck, I use it for day-to-day administrative  
tasks!

Rake is the same way.

Migrations rock, and you can set Rails to output as schema.sql so  
no-one’s  
the wiser :P.

Otherwise, good luck. Hope you can at least use Ruby tools if not all of  
Rails.

Jason
