javascript - Designation for opening jquery-ui dialoge -


I have a situation where I want to open a model with a button. However, it seems that I have to use an ID or class for my designer where it becomes difficult, I want my modal button to look like my second button, so I do not want to give it my class or id , Either it would have to duplicate the CSS or change the button.

I have two solutions:

  1. Insert a name at one of my hrefs and do my javascript to open the modal instead of class or id
  2. Enter a second empty "Model" category on my ARR and give your Javascript to open that model

    `

      $ (" #dialog ") .dialog ({autoOpen: incorrect, show: {effect:" blind ", duration: 1000}, hide: {effect:" explosion ", duration: 1000}}); $ ("#btn_sec"). Click (function () {$ ("#dialog") .dialog ("open");});   

    and my html:

      & lt; A href = "#" class = "btn" id = "btn_sec2" & gt; Click me! & Lt; / A & gt;   

    Which is more planned approach?

    The second is a common approach, I believe. Elements can have multiple squares, so you can give it a square for CSS and another class for jQuery posts.

Comments

Popular posts from this blog

python - Writing Greek in matplotlib labels, titles -

c# - LINQ to Entities does not recognize the method 'Int32 IndexOf(System.String, System.StringComparison)' method -

c# - Call function from DLL -