title: Call bootstrap modal show event with php
body: <p>I want to call <code>modal('show')</code> event with php code. How can I do this? I tried the following:</p>
  
  <pre><code>if(isset($_POST['Edit'])){
  echo "&lt;script&gt; $('#Modal').modal('show') &lt;/script&gt;";} 
  </code></pre>
  
  <p>I run this code, but <code>echo "&lt;script&gt; $('#Modal').modal('show') &lt;/script&gt;";</code> doesnt work. How can I show modal  when image input is clicked? I don't want to call with image onlick.</p>
  
  <p>Input:</p>
  
  <pre><code>&lt;input type="image" src="image.png" name="Edit" value="Edit" alt="Edit" /&gt;
  </code></pre>
  
  <p>Modal:</p>
  
  <pre><code>&lt;div class="modal hide fade" id="Modal" &gt;
       &lt;form method="post"&gt;
            &lt;div class="modal-header"&gt;
                 &lt;button type="button" class="close" data-dismiss="modal" style="margin-top:-10px"&gt;×&lt;/button&gt;
            &lt;/div&gt;
            &lt;div class="modal-body"&gt;
                 &lt;textarea id="text" name="text"&gt;Test&lt;/textarea&gt;
            &lt;/div&gt;
            &lt;div class="modal-footer"&gt;
            &lt;/div&gt;
      &lt;/form&gt;
  &lt;/div&gt;
  </code></pre>