Hi,
I will be honest. It has been years since I didn't write code for Fortran, but I know it, I just need to remember.
About PHP, let me ask you why PHP. As far as I get it is a enter values, make calculations and return back the results, sort of project, and Javascript better suits this scenario. PHP makes sense only if you want to hide the source code.
Even then if you want to continue with PHP, here is my offer. But first please send me the Fortran code, and let me check my Fortran notes.
Regards,
Serdar Yalçın