for example could u create a ruby on rails application and install in it php extensions coz i'm newby with ruby on rails but i find it so good and fun to use so could i do it, coz maybe i might need something that i can't do with ror so i use php for specific tasks in the app, is it possible?
Not really. They are entirely different languages. You could always integrate via an API, but this would require creating the API's on both systems. Symfony is a php framework that is very similar to ROR. If you are looking for similar functionality, I would probably lean towards a PHP framework. Others that are similar are codeignitor and cakephp.