Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7764285
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T14:52:19+00:00 2026-06-01T14:52:19+00:00

I have a dynamic dialog I wish to raise… for example var newDiv =

  • 0

I have a dynamic dialog I wish to raise… for example

var newDiv = $(document.createElement('div'));

$(newDiv).html('Hello World');
$(newDiv).dialog({
    closeOnEscape: false,
    draggable: false,
    modal: true,
    resizable: false,
    width: 725

});

All is great however my dynamic dialog has a title which I don’t want. Naturally I can remove this by amending the following CSS class… .ui-dialog-titlebar {display:none}

However I only wish for this instance of the dialog to not have a title and I don’t wish to apply this to all other dialogs within my system. What’s the best way of removing the title on the dynamic dialog? I was thinking of ether chaning the CSS method to the dialog, something like this… $(newDiv).dialog({… stuff}).css() but so far nothing has worked.

I think the problem is due to my dynamic div not having an ID it’s pretty hard to reference… any ideas anyone?

Please note if I haven’t described my issue well please say so and I’LL reword/expand… I’ve been up working for hours and I#m starting to go mad…

PLEASE NOTE TO CLARIFY: I want to remove the whole title bar and styling… not just have an empty string where the title usually is.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T14:52:20+00:00Added an answer on June 1, 2026 at 2:52 pm

    You can add a css class to your dynamic dialog called something like “dialog-no-title” and then add the relevant css under that class dialog-no-title {display:none}.

    To add a class to a DOM element see the jQuery documentation. It looks something like this: .addClass("dialog-no-title"). I’m guessing you could do something like:

    var newDiv = $(document.createElement('div'));  
    
    $(newDiv).html('Hello World');
    
    $(newDiv).dialog({
        closeOnEscape: false,
        draggable: false,
        modal: true,
        resizable: false,
        width: 200,
        dialogClass: 'dialog-no-title'
    });
    

    EDIT : updated the code sample to reflect the comments. And here’s a working jsFiddle for you: http://jsfiddle.net/nj2Q9/21/

    Cheers,

    James

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have dynamic content in a div called txtresults like this: <div id=txtresults></div> This
I have a dialog appear when i press a button with dynamic data but
I have a dialog box that displays a dynamic-sized form. I currently get the
I have dynamic array (object) var variables = {}; variable[var1] = someValue; variable[var2] =
I have a dynamic dialog being created that loads a page. The close buttons
I have dynamic web page with JS. There is a <textarea> and a Send
I have dynamic array filled with bytes, which are read from .raw file with
I have some divs that have dynamic heights controlled by a 'click' function as
I have some divs that have dynamic heights controlled by a 'click' function as
I have a dynamic web project in eclipse, which uses annotations to map servlets

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.