title: Fancybox popup not working
body: <p>I have added this script for fancybox popup. But it is not working.</p>
  
  <p>It is working on other page but don't know what is the problem in this page, there is much more JavaScript for other functionality, may be this is the reason, but when in console, there's no error!</p>
  
  <pre><code>&lt;table id="tb1" cellspacing="0" cellpadding="7" style="width:99%;border:solid 1px#c0bebe;min-width:550px;height:auto;font-family:arial;font-size:11px;margin-left: 6px;border-bottom: none;"&gt;
      &lt;tr class="heads tr_check" height="44px"&gt;
          &lt;th style="padding-left:15px;width:5%"&gt;Date&lt;/th&gt;
          &lt;th style="padding-left:15px;width:5%"&gt;From&lt;/th&gt;
          &lt;th style="padding-left:15px;width:5%"&gt;Mode&lt;/th&gt;
          &lt;th style="padding-left:15px;width:40%"&gt;Message&lt;/th&gt;
          &lt;th style="padding-left:15px;width:10%;border-right: medium none;"&gt;Document&lt;/th&gt;
      &lt;/tr&gt;
      &lt;?php 
      $msgMngResult = getMessagesForEdit($_GET['projectid']);
      if(mysql_num_rows($msgMngResult)&gt;0) {
          while($msgMngtaskDtlsRow = mysql_fetch_array($msgMngResult)) {  
              if($msgMngtaskDtlsRow['message_from']=='Client') {
                  $bgcolor = "background-color:#F8E0EC";
              } else {
                  $bgcolor = "background-color:#E7FFD6";
              }
              $id = $msgMngtaskDtlsRow['id'];
              $msgres = getMsgDoc($id);
              ?&gt;
              &lt;tr height="44px" class="tr_check"&gt;
                  &lt;td style="padding-left:15px;&lt;?php echo $bgcolor;?&gt;"&gt;&lt;?php echo $msgMngtaskDtlsRow['msg_date'];?&gt;&lt;/td&gt;
                  &lt;td style="padding-left:15px;&lt;?php echo $bgcolor;?&gt;"&gt;&lt;?php echo $msgMngtaskDtlsRow['message_from'];?&gt;&lt;/td&gt;
                  &lt;td style="padding-left:15px;&lt;?php echo $bgcolor;?&gt;"&gt;&lt;?php echo $msgMngtaskDtlsRow['message_mode'];?&gt;&lt;/td&gt;
                  &lt;td style="padding-left:15px;&lt;?php echo $bgcolor;?&gt;"&gt;&lt;?php echo substr($msgMngtaskDtlsRow['message'],0,100);?&gt;&lt;a href="#divForm&lt;?php echo $id;?&gt;" id="messages&lt;?php echo $id;?&gt;" class="fmsg" data-toggle="tooltip" title="" style="color:blue;float: right;"&gt;Read More..&lt;/a&gt;&lt;/td&gt;
                  &lt;div id="divForm&lt;?php echo $id;?&gt;" class="fancybox" style="display:none;"&gt;
                      &lt;p&gt;&lt;?php echo $msgMngtaskDtlsRow['message'];?&gt;&lt;/p&gt;
                  &lt;/div&gt;
                  &lt;td style="border-right: medium none;padding-left:15px;&lt;?php echo $bgcolor;?&gt;"&gt;
                      &lt;?php while($res = mysql_fetch_array($msgres)) {
                          echo "&lt;br/&gt;&lt;a href='".PROJECT_FILE_PATH.$msg_doc."/".$res['message_docs']."' target='_blank' style='color:blue;text-decoration: underline;'&gt;".$res['message_docs']."&lt;/a&gt;&lt;br/&gt;"; 
                      }
                      ?&gt;
                  &lt;/td&gt;
              &lt;/tr&gt;
              &lt;tr class="hidetr tr_check acctr_&lt;?php echo $msgMngtaskDtlsRow['id']; ?&gt;" &gt;&lt;td colspan="8" style="border-right:0px;"&gt;&lt;/td&gt;&lt;/tr&gt;
          &lt;?php
          }
      } else { ?&gt;
          &lt;tr height="44px" class="tr_check"&gt;
              &lt;td align="center" colspan="12"&gt;
                  &lt;div id="err"&gt;&lt;div id="errormsg" class="no-record"&gt;&lt;strong&gt; No Records Found &lt;/strong&gt;&lt;/div&gt;&lt;/div&gt;
              &lt;/td&gt;
          &lt;/tr&gt;
      &lt;?php
      } ?&gt;
  &lt;/table&gt;
  
  &lt;link rel="stylesheet" type="text/css" href="css/datepicker.css" /&gt; 
  &lt;script type="text/javascript" src="js/datepicker.js"&gt;&lt;/script&gt; 
  &lt;script type="text/javascript" src="js/jquery.min.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="js/jquery.form.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="js/tabber.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="js/paddRow.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="js/addUnitRow.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5.0/jquery.min.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.9/jquery-ui.min.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/tinymce/4.5.2/tinymce.min.js"&gt;&lt;/script&gt;
  &lt;script src="https://cdnjs.cloudflare.com/ajax/libs/fancybox/2.1.5/jquery.fancybox.js"&gt;&lt;/script&gt;
  &lt;link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/fancybox/2.1.5/jquery.fancybox.min.css" /&gt;
  &lt;script&gt;
      $('.fmsg').live('click', function () {
          var id = $(this).attr('id');
          alert(id);
          $("#"+id).fancybox({
              'width':800,
              'height':450,
              'autoSize' : false,
              helpers: {
                  title : {
                      type : 'float'
                  }
              }
          });
      });
  &lt;/script&gt;
  </code></pre>
  
  <p>Sometimes it shows - <code>ement.prop is not defined</code>. </p>
  
  <p>It appears often.</p>