This HTML is fine:
<a href="#" id="contactUs">Contact Us</a> <div id="dialog" title="Contact form"> <p>appear now</p> </div>
You need to initialize the Dialog (not sure if you are doing this):
$(function() { // this initializes the dialog (and uses some common options that I do) $("#dialog").dialog({ autoOpen : false, modal : true, show : "blind", hide : "blind" }); // next add the onclick handler $("#contactUs").click(function() { $("#dialog").dialog("open"); return false; }); });
Related Posts:
- How to change the text of a button in jQuery?
- jQueryUI dialog width
- How to use radio on change event?
- Form Submit jQuery does not work
- Slide right to left?
- Twitter Bootstrap Modal Form Submit
- Check if user is logged in using JQuery
- How to save the state of a drag and drop jQuery UI Sortables front end layout editor?
- jQuery UI Datepicker not working
- Custom function to rearrange attachments when creating posts – Almost there
- possible to make sections in theme customizer sortable and saveable at publish button clicked?
- Enqueuing jQuery in plug-ins
- How do I get my page to load the jQuery UI Effects library?
- Override default jquery ui library with newer version
- How to enable the content editor as a droppable target with jQuery-ui?
- Automatic jQuery accordion from header tags
- Jquery not showing in homepage
- Format numeric symbols in titles
- jQuery.accordion isn’t a function even when enqueued
- Override theme style with other CSS on a specific page
- Will the latest Bootstrap work properly with the default WordPress jQuery?
- Rhyzz Repeatable-fields javascript in php and wordpress
- WordPress + BlockUI or a splash page [closed]
- Return an array from get_terms and store as JavaScript array for search autocomplete
- Dukapress jQuery(“form.product_update”).livequery is not a function [closed]
- Which jQuery packages are included in WordPress 3.1.2?
- Good Solution for Adding jQuery Tabs Anywhere Within WordPress?
- Cannot enqueue jQuery correctly using Google CDN
- Adding jQuery UI elements to WordPress page
- Sorting WP Auctions by date/price?
- How to add custon UI jquery & Fancybox script to WP
- jQuery tabs plugin with callback to fetch data
- Jquery UI Google CSS, from where?
- datepicker for custom post type admin
- JQuery UI not loading without explicit loading of jQuery
- Is there a default way in wordpress to create a overlay in the dashboard?
- AJAX Success Function using JS substr() fails in WP 4.1 vs 4.0
- Recommended Use of Bootstrap, or JQuery-UI in WP/plugin development?
- Screen Options JavaScript Code
- Drag and Drop Metadata Menu Order
- A carousel slideshow plugin in JavaScript
- jQuery UI Accordion loading very slow
- Theme style overrides the plugin style
- Slide toggle Jquery UI
- jquery Autocomplete
- why does so many javascript libraries are loaded along with my website?
- Dashboard controls have all stopped working
- How can I add a new lib path without call each one on the header?
- Sorting UL Listing Within the TinyMCE Visual Editor in WordPress
- jQuery dialog prints HTML-Tags under WordPress
- using jquery autocomplete in wordpress plugin
- Theme variation conflict with jquery select2 dropdown
- jQuery datepicker not showing on admin menu
- jQuery $(this) keyword
- jQuery – Add ID instead of Class
- Can Twitter Bootstrap alerts fade in as well as out?
- jQuery – Illegal invocation
- $ not defined using jQuery in WordPress
- Why $ for jquery doesn’t work?
- Draggable item in custom gutenberg block
- How to include jquery validate in a template
- Appending anchor tag to next post
- WordPress Script Loading/Unloading — wp_deregister_script(‘jquery’)
- Simple jQuery Click Not Working, though console log recognizes the function [closed]
- Registration e-mail check with AJAX
- Updating User Profile with AJAX not working
- Why isn’t jQuery 2.1 loading in the header?
- enqueue the scripts
- wpColorPicker: How update colors on input value update?
- Getting all URLs of uploaded images using media uploader
- Reorder displayed posts with JQuery (title A-Z / last posted)
- `wp_editor()` CSS messing up the jQuery Dialog
- Ajax, Permalinks and post_thumbnail
- First Attempt at AJAX and it keeps getting Canceled. Can’t Get Results to Show
- Enque Javascript in Footer?
- How to return multiple arguments from AJAX callback function
- JS news ticker is not working on home page but working on other pages. How to solve this?
- jQuery function not working
- Remove swfobject.js in wp_head()
- Uncaught ReferenceError: jQuery is not defined: how to fix on a sunday? [closed]
- underscore template dynamically remove row Jquery
- Custom meta box with jQuery.sortable custom post type list
- echo do_shortcode for Contact Form 7 from within dynamically loaded php file
- including jquery
- Customizing the Jquery Calendar [closed]
- How to make JQuery load on top of head tag before everything
- $_POST empty in using new php file added to theme
- How to blur the_post_thumbnail() via blur.js (jquery)?
- Plugin preventing media buttons from working
- How to deregister scripts all at once
- Using jQuery DataTables and yadcf
- jQuery autcomplete not working
- Add jQuery function to media button
- Why won’t this jQuery work in WordPress?
- jQuery append only works if I select html in admin section [closed]
- jQuery color picker function on change
- Can’t get this jQuery snippet to work with WordPress
- jQuery Add/Remove Classes Not Working
- Contact Form 7 – Submit Form not working After Ajax Request [closed]
- Making the Google Maps API non readable