I am new on php . i am currently on the project that have a php file contain approx 2500 line of code.
This script is working fine in localhost but on the server it take a lot of time to reload the page.
I want to know that is there any tool or website that find out the slow running code from php script.
Any help will be appreciated..
I strongly recommend using xdebug for that – it has an integrated profiling solution. You can then parse these files with Webgrind
If you use software like XAMPP or MAMP, xdebug could be already with it. There are also lots of useful information how to setup xdebug like here http://unitstep.net/blog/2009/01/26/getting-xdebug-to-work-with-apachexampp-to-debug-php/
Maybe the server is also slower than your local machine.