providing YES or NO Buttons using javascript

Posted on 2011-10-18
Last Modified: 2012-05-12
I want to provide Yes Or No Buttons using javascript, if the user clicks on Yes i have say "you are successful"
if No , no action to be taken place
can you please suggest

Question by:praveen1981
    LVL 11

    Expert Comment

    You are missing some details here. Do you want this in a browser dialog? Do you just want the buttons on the page? You can use a browser confirm box, but it only gives you 'Ok' and 'Cancel' buttons and not Yes/No.

    You would have to make a custom dialog.

    Author Comment


    I don't want to use the confirm box, as it gives only Ok and Cancel,  i would like to make a custom dialog which gives me

    Yes Or No buttons.

    Please suggest.
    LVL 10

    Expert Comment

    by:Pramod Kumar
    Please download both attached HTML and open page "dialog.html" in browser and press button
    LVL 11

    Accepted Solution

    My suggestion is to pick and use a JS ui framework like jquery-ui, yui, extjs or similar to help with this. Creating custom dialog boxes from scratch is no simple feat.

    Once you have picked one, it's pretty easy to help with getting what you want accomplished.

    Author Closing Comment

    Thanks, it solved

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Suggested Solutions

    ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
    In the modern office, employees tend to move around the workplace a lot more freely. Conferences, collaborative groups, flexible seating and working from home require a new level of mobility. Technology has not only changed the behavior and the expe…
    It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
    how to add IIS SMTP to handle application/Scanner relays into office 365.

    779 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now