I'm trying to trigger the following modal after the page loads.  I've tried
'autofire:true' and jqmShow() to no avail.  I am receiving an error message
that 'h' has no properties.  I'm obviously doing something wrong.  Can
someone help point me in the right direction?  Here's the code:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>
<html xmlns="http://www.w3.org/1999/xhtml";>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<!-- jqModal Dependencies -->
<script type="text/javascript" src="jquery-1.2.6.pack.js"></script>
<script type="text/javascript" src="jqModal.js"></script>

<!--  jqModal Styling -->
<link type="text/css" rel="stylesheet" media="all" href="jqModal.css" />
<link type="text/css" rel="stylesheet" media="all" href="alert.css" />
<script type="text/javascript">
$().ready(function() {

        // THIS DOSEN'T WORK
        
        $('#ex3b').jqmShow({
          ajax: 'examples/3b.html', 
          target: 'div.jqmAlertContent', 
          overlay: 70, 
          autofire: true
        });
        
        
        // THIS WORKS WHEN A TRIGGER IS USED
        // BUT I WANT TO LOAD THE MESSAGE WHEN THE PAGE LOADS)

        //var triggers = $('a.ex3bTrigger')[0];  
        //$('#ex3b').jqm({
          //trigger: triggers,
          //ajax: 'examples/3b.html',
          //target: 'div.jqmAlertContent',
          //overlay: 70
        //});

    
  // Close Button Highlighting. IE doesn't support :hover. Surprise?
  if($.browser.msie) {
  $('div.jqmAlert .jqmClose')
  .hover(
    function(){ $(this).addClass('jqmCloseHover'); }, 
    function(){ $(this).removeClass('jqmCloseHover'); });
  }
});
</script>
</head>

<body>
<!-- this works when a trigger is used - so all the files are working -->
# view 

<div class="jqmAlert" id="ex3b">
  <div id="ex3b" class="jqmAlertWindow">
    <div class="jqmAlertTitle clearfix">
      <h1>Did you know?</h1> # <em>Close</em> 
    </div>
  
    <div class="jqmAlertContent">
      <p>Please wait...  inc/busy.gif </p>
    </div>
  </div>
</div>

</body>
</html>
-- 
View this message in context: 
http://www.nabble.com/jqModal-tp20443670s27240p20443670.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.

Reply via email to