title: I can't find the format file `pdflatex.fmt'!
body: <p>I want to run pdflatex from php on user request.
  Running from terminal works fine [php file.php] and creates pdf file. But when I try to run from browser by sending request to php, It gives this error "<strong>I can't find the format file `pdflatex.fmt'!</strong>"</p>
  
  <p>I am working with php5.2.6, OS is Fedora 9, and safe_mode is turned off.</p>
  
  <p>Code -</p>
  
  <pre><code>    $cmd = "/usr/bin/pdflatex /home/deep/public_html/resume/Folder/deependra.tex 2&gt;&amp;1";
      $output = exec($cmd);
      echo $output;
  </code></pre>