Thursday, June 14, 2012

Display link mailto / Href in alert box javascript


Below is the code i implemented for displaying link in href alert box ::

<!doctype html>
 <meta charset="utf-8">
 <title>Basic usage of the jQuery UI dialog</title>

 <link rel="stylesheet" type="text/css" href="">

 <script type="text/javascript" src=""></script>
 <script type="text/javascript" src=""></script>
 <script type="text/javascript">
 $(document).ready(function() {
  var $dialog = $('<div></div>')
   .html('Welcome, Please click on the Link to display blog <a href=''>Visit blog</a>')
    autoOpen: false,
    title: 'Basic Dialog'

  $('#opener').click(function() {
   // prevent the default action, e.g., following a link
   return false;

<p>This is an example from the Ujjwal's Blog</a>.</p>

<button id="opener">Show Dialog</button>


No comments: