Jump to content

shaili_shah

Members
  • Posts

    111
  • Joined

  • Last visited

  • Days Won

    2

Posts posted by shaili_shah

  1. On 4/25/2020 at 5:08 PM, Michele Costantino said:

    Is it possible to have link 4,5,6 on the right of of dropdown2 ?

    I'm fighting with this since 3 days...

    So you can use this css

     position: relative;    
     left: 100%;
      top: 0;

    Hope it'll help.

    Thanks!

  2. I am unclear about your question.

    But the more I understood, the more I would explain. Here is my code for darkmode option.

    Example :

    <style>
            body {
                padding: 25px;
                background-color: white;
                color: black;
                font-size: 25px;
            }

            .dark-mode {
                background-color: black;
                color: white;
            }
        </style>

    <body>

    <h2>Dark mode</h2>

    <p>tap the button.</p>

    <button onclick="myFunction()">dark mode</button>

    <script>

    function myFunction() {
                var element = document.body;
                element.classList.toggle("dark-mode");
            }

    </script>

    </body>

    I hope you'll understand.

    If you have any doubt then you can freely ask.

    Thank You.

  3. As you said i have written some code here it is.

    function copy() {
      var copyText = document.getElementById("myInput");
      copyText.select();
      document.execCommand("copy");
      alert("Copied the text: " + copyText.value);
    }

    <form action="https://www.w3docs.com/" method="get" target="_blank">
    <input type="text" value="Hello World" id="myInput">
    <button onclick="copy()">Copy text</button>
    </form>

    I hope it'll be helpful to you.

     

     

  4. function myFunction() {
      var hostip = location.host;
      document.getElementById("videohls").innerHTML = hostip ;
    var url = " http:// "+ hostip + /"1.m3u8 ";
    $("#id-of-video-tag> source").attr("src", url);}
    

    I think this will work.

    Hope this will help you.

     

  5. Yes you can use onclick event as

     <asp:RadioButton ID="chkNo" Text="No" runat="server" onclick="fn()" />

    you can add your own function.

    After this you can use the JavaScript to define function.

    <script type="text/javascript">
            function fn() {
                alert("I have clicked no button");
            }
        </script>

    i hope you will understand.

  6. I have tried with this code :

    First of all you have to add this reference in link tag :

     <link rel="stylesheet" href="http://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
     <script src="https://code.jquery.com/jquery-1.12.4.js"></script>
     <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>

    Now our script is :

    <script>     
            $( function() {
                $( "#accordion" ).accordion();
            });
        </script>

    And finally out html page is :

    <body>            
        <div id="accordion">
          <h3>Section 1</h3>
          <div>
            <p>
            This is section 1.
            </p>
          </div>
          <h3>Section 2</h3>
          <div>
            <p>
            This is section 2.
            </p>
          </div>      
        </div>
    </body>

    I hope this will help you.😊

  7. <label for="option">Choose 2:</label> 
    <select id="cars" onchange="select()">
      <option value="1">1</option>
      <option value="2">2</option>
      <option value="3">3</option>
      <option value="4">4</option>
      <option value="5">5</option> 
    </select>
    <select id="cars1">
      <option value="1">1</option>
      <option value="2">2</option>
      <option value="3">3</option>
      <option value="4">4</option>
      <option value="5">5</option> 
      </select>
     

      <script>
          function select()
          {           
            var sel = document.getElementById("cars").value;                  
            var x = document.getElementById("cars1").options[sel-1].disabled = true;                  
          }            
      </script>

    Here I have take [sel-1] because it's starting index is 0.

    I hope this will help you.

  8. There is Animation, Transition and Transform property of CSS. I have used transition and transform property on image like :

     <style>
            img  {
                width: 100px;
                height: 100px;
                transition: width 2s, height 2s, transform 2s;
            }

                img : hover {
                    width: 300px;
                    height: 300px;                
                    transform: rotate(360deg);               
                }

        </style>

    And Html tag

    <body>  
        <img src="~/img.png"/>   
    </body>

    I hope you'll meet your desired output..!

     

  9. If you want to show null value then you have to try this query :

    select  t1.table1id,  t1.table2id,  t2.table2name  from  table1 t1  left join  table2 t2  on  t1.table2id  =  t2.table2id ;

     

    If you do not want to show that null values then use this query :

    select  t1.table1id,  t1.table2id,  t2.table2name  from  table1 t1  inner join  table2 t2  on  t1.table2id  =  t2.table2id ;

     

    I hope this will show you your desired answer. let me know if you do this.

×
×
  • Create New...