title: Unlink() not working
body: <p>I am trying to delete a file from the Server.</p>
  
  <p>The files of my application is in a folder name "/public_html/app/";</p>
  
  <p>All the images associated with the application is located in the following path: "/public_html/app/images/tryimg/"</p>
  
  <p>The file in which I am writing the below code spec is in "/public_html/app/".</p>
  
  <p>Here is my code snipet:</p>
  
  <pre><code>&lt;?php
  
  $m_img = "try.jpg"
  
  $m_img_path = "images/tryimg".$m_img;
  
  if (file_exists($m_img_path))
  {
       unlink($m_img_path);
  }
  // See if it exists again to be sure it was removed
  if (file_exists($m_img))
  {
            echo "Problem deleting " . $m_img_path;
  }
  else
  {
          echo "Successfully deleted " . $m_img_path;
  }
  ?&gt;
  </code></pre>
  
  <p>When the above script is executed the message "Successfully deleted try.jpg" is displayed.</p>
  
  <p>But when I navigate to the folder, the file is not deleted.</p>
  
  <p>Apache: 2.2.17
  PHP version: 5.3.5</p>
  
  <p>What am I doing wrong?</p>
  
  <p>Do I have to give a relative or absolute path to the image?</p>