Jump to content

ishan_shah

Members
  • Posts

    90
  • Joined

  • Last visited

Everything posted by ishan_shah

  1. You can use different class or p tag for 's' and provide color property
  2. You can use inline css like that: <input type="radio" name="click" value= "save" style="height:20px; width:20px; vertical-align: middle;" CHECKED > Or you can provide class name to particular input like Html: <input type="radio" name="click" value= "save" class="checkbox" CHECKED > Css: .chexkbox{ height:20px; width:20px; }
  3. You can use keyevents for that for example:<!DOCTYPE ht l<!DOCTYPE html> <html> <body> <h3>Trigger Button Click on Enter</h3> <p>Press the "Enter" key inside the input field to trigger the button.</p> <input id="myInput" value="Some text.."> <button id="myBtn" onclick="javascript:alert('Hello World!')">Button</button> <script> var input = document.getElementById("myInput"); input.addEventListener("keyup", function(event) { if (event.keyCode === 13) { event.preventDefault(); document.getElementById("myBtn").click(); } }); </script> <!DOCTYPE html> <html> <body> <h3>Trigger Button Click on Enter</h3> <p>Press the "Enter" key inside the input field to trigger the button.</p> <input id="myInput" value="Some text.."> <button id="myBtn" onclick="javascript:alert('Hello World!')">Button</button> <script> var input = document.getElementById("myInput"); input.addEventListener("keyup", function(event) { if (event.keyCode === 13) { event.preventDefault(); document.getElementById("myBtn").click(); } }); </script> </body> </html>
  4. You can also use jQueryUi autocomplete for that,you can find all the references here:https://jqueryui.com/autocomplete/
  5. You can use popup for that : with jQuery: Cdn:https://cdnjs.cloudflare.com/ajax/libs/magnific-popup.js/1.1.0/jquery.magnific-popup.min.js File.js: $(document).ready(function() { $('.image-link').magnificPopup({type:'image'}); }); File.htm: <a class="image-link" href="your-image-url">Open popup</a>pl Or you can also use boostrap model for that. Here is the example:https://www.w3schools.com/howto/howto_css_modal_images.as
  6. I assume you want o/p like 2015-0325 only. So for that, You can pull out the parts of a DateTimeFormat one-by-one using DateTimeFormat#format, but note that when using this method, as of March 2020, there is a bug in the ECMAScript implementation when it comes to leading zeros on minutes and seconds . const d = new Date('2010-08-05') const ye = new Intl.DateTimeFormat('en', { year: 'numeric' }).format(d) const mo = new Intl.DateTimeFormat('en', { month: 'short' }).format(d) const da = new Intl.DateTimeFormat('en', { day: '2-digit' }).format(d) console.log(`${da}-${mo}-${ye}`)
  7. Remove apostrophe ' ' This is the example that i found on Microsoft's website : The following examples return all rows from the Product table. The first example returns total sales and the discounts for each product. In the second example, the total revenue is calculated for each product. USE AdventureWorks2012; GO SELECT p.Name AS ProductName, NonDiscountSales = (OrderQty * UnitPrice), Discounts = ((OrderQty * UnitPrice) * UnitPriceDiscount)
  8. Provide same name to radio button group like: <input type="radio" id="memory" name="AnyName" value="In Memory of"> <input type="radio" id="honor" name="AnyName" name="honor" value="In Honor of">
  9. When the page loads your ready function will run, this should open the accordion section the URI's hash refers to: jQuery(document).ready(function() { // get the #section from the URL var hash = window.location.hash; // open accordion jQuery(hash).slideDown(300).addClass('open'); // set title to active jQuery(hash).prev('.accordion-section-title').addClass('active'); /* ... the rest of your code here */ }); you might get a slight performance boost if you don't get the jQuery object twice, you can chain these like this: jQuery(hash).slideDown(300).addClass('open') .prev('.accordion-section-title').addClass('active');
  10. Here are the changes that i made, hope it may help you: Findus.html
  11. You can use following code for reference.0 : /* Extra small devices (phones, 600px and down) */ @media only screen and (max-width: 600px) { height : ... /*whatever you want*/; width : ... /*whatever you want*/; /*any thing extra that you like to add like margin,padding,etc */ } /* Small devices (portrait tablets and large phones, 600px and up) */ @media only screen and (min-width: 600px) { height : ... /*whatever you want*/; width : ... /*whatever you want*/; /*any thing extra that you like to add like margin,padding,etc */ } /* Medium devices (landscape tablets, 768px and up) */ @media only screen and (min-width: 768px) { height : ... /*whatever you want*/; width : ... /*whatever you want*/; /*any thing extra that you like to add like margin,padding,etc */ } /* Large devices (laptops/desktops, 992px and up) */ @media only screen and (min-width: 992px) { height : ... /*whatever you want*/; width : ... /*whatever you want*/; /*any thing extra that you like to add like margin,padding,etc */ } /* Extra large devices (large laptops and desktops, 1200px and up) */ @media only screen and (min-width: 1200px) { height : ... /*whatever you want*/; width : ... /*whatever you want*/; /*any thing extra that you like to add like margin,padding,etc */ }
  12. The error is within your server side, when there's an error on your server side, the response comes with html tags '<' when there's an error php will add tag with the error message. Therefore your json contains the html tags and becomes invalid because of unexpected tags. if you have an array with semi colon, at last value description please remove that and try again for example : if you have array like this: $eventstArray[] = array ( 'label' => $eventsQuery2['eventTitle']; 'venue' => $eventsQuery2['venueName']; 'category' => $eventsQuery2['catDesc']; 'price' => $eventsQuery2['eventPrice']; 'description' => $eventsQuery2['eventDescription']; ); it should be like this: $eventstArray[] = array( 'label' => $eventsQuery2['eventTitle'], 'venue' => $eventsQuery2['venueName'], 'category' => $eventsQuery2['catDesc'], 'price' => $eventsQuery2['eventPrice'], 'description' => $eventsQuery2['eventDescription'] ); just remove last semi-colon
  13. Here is the solution: $("#butsend").click(function() { var grandtotal=0; var newid = id++; $("#table1").append('<tr valign="top" id="'+newid+'">\n\ <td width="100px" >' + newid + '</td>\n\ <td width="100px" class="patid'+newid+'">' + $("#patid").val() + '</td>\n\ <td width="100px" class="test_code'+newid+'">' + $("#test_code").val() + '</td>\n\ <td width="100px" class="test_name'+newid+'">' + $("#test_name").val() + '</td>\n\ <td width="100px" id="generalprice" class="generalprice'+newid+'">' + $("#generalprice").val() + '</td>\n\ <td width="100px" id=quantity class="quantity'+newid+'">' + $("#quantity").val() + '</td>\n\ <td width="100px" id="qntytolprices" class="totalprices'+newid+'">' + $("#totalprices").val() + '</td>\n\ <td width="100px" id="qntytolprice" class="totalprice'+newid+'">' + $("#totalprice").val() + '</td>\n\ <td width="100px"><a href="javascript:void(0);" class="remCF">Remove</a></td>\n\ </tr>'); for (let i =1; i<id ;i++){ grandtotal += parseInt($(".totalprices"+i+"").text() ? $(".totalprices"+i+"").text() : 0 ); } $("#subtotal").val(grandtotal); }); I have created new var of grandtotal and initialized it with 0 and used for loop for getting GrandTotal of all prices.
  14. You can try following code: <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <title>jQuery Demo</title> <script> $(document).ready(function () { $("#filter").on("keyup", function () { var Value = $(this).val().toLowerCase(); $("#myTable tr").filter(function () { $(this).toggle($(this).text().toLowerCase().indexOf(Value) > -1); }); }); }); </script> <style> table { font-family: Cambria, Cochin, Georgia, Times, 'Times New Roman', serif; border: 1px solid black; padding: 5px; } td, th { border: 1px solid black; text-align: center; padding: 5px; font-size: 20px; } </style> </head> <body> <h2>Filtering Table</h2> <input type="text" placeholder="Search.." id="filter"><br><br> <table> <thead> <tr> <th>First Name</th> <th>Last Name</th> <th>City</th> </tr> </thead> <tbody id="myTable"> <tr> <td>Ishan</td> <td>Shah</td> <td>Ahmedabad</td> </tr> <tr> <td>Parth</td> <td>Madiya</td> <td>Rajkot</td> </tr> <tr> <td>Dhiren</td> <td>Jakhariya</td> <td>Jamnagar</td> </tr> <tr> <td>Chirag</td> <td>Radadiya</td> <td>Jamnagar</td> </tr> <tr> <td>Kishan</td> <td>Lal</td> <td>Khambhaliya</td> </tr> </tbody> </table><br> </body> </html>
  15. Hey @vmars316, you can create a draggable element in easy way using jQuery plugins. Following is the example code which you can refer: <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>jQuery UI Draggable - Default functionality</title> <link rel="stylesheet" href="https://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css"> <style> </style> <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> <script> $( function() { $( "#draggable" ).draggable(); } ); </script> </head> <body> <div id="draggable" class="ui-widget-content"> <p>Move</p> <p>this</p> <p>DIV</p> <textarea class="textArea" rows="4" cols="20"> </textarea> <div id="mydiv"> <div id="mydivheader">Click here to move</div> <textarea class="textArea" rows="4" cols="20"> </textarea> </div> </div> Here <link rel="stylesheet" href="https://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> These are the CDN to import plugins to our code. you can also apply that draggable() function to multiple divs.
  16. for your questions : var can not use var i=+5 at a time, To do that you have to first declare that variable and after that you can perform that operation like var i=0 i=+5;
  17. Hey @ryanstua, You can do something like that: Html: <!DOCTYPE html> <html> <head> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"> </head> <body> <div class="navbar"> <div class="dropdown"> <button class="dropbtn">Menu <i class="fa fa-caret-down"></i> </button> <div class="dropdown-content"> <div class="row"> <div class="column"> <h3>Category 1</h3> <a href="#">Link A</a> <a href="#">Link B</a> <a href="#">Link C</a> </div> <div class="column"> <h3>Category 2</h3> <a href="#">Link 1</a> <a href="#">Link 2</a> <a href="#">Link 3</a> </div> <div class="column"> <h3>Category 3</h3> <a href="#">Link X</a> <a href="#">Link Y</a> <a href="#">Link Z</a> </div> </div> </div> </div> <a href="#home">Home</a> <a href="#news">About Us</a> </div> </body> </html> And css: * { box-sizing: border-box; } body { margin: 0; } .navbar { overflow: hidden; background-color: #333; font-family: Arial, Helvetica, sans-serif; } .navbar a { float: left; font-size: 16px; color: white; text-align: center; padding: 14px 16px; text-decoration: none; } .dropdown { float: left; overflow: hidden; } .dropdown .dropbtn { font-size: 16px; border: none; outline: none; color: white; padding: 14px 16px; background-color: inherit; font: inherit; margin: 0; } .navbar a:hover, .dropdown:hover .dropbtn { background-color: red; } .dropdown-content { display: none; position: absolute; background-color: #f9f9f9; width: 100%; left: 0; box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2); z-index: 1; } .dropdown-content .header { background: red; padding: 16px; color: white; } .dropdown:hover .dropdown-content { display: block; } .column { float: left; width: 33.33%; padding: 10px; background-color: #ccc; height: 250px; } .column a { float: none; color: black; padding: 16px; text-decoration: none; display: block; text-align: left; } .column a:hover { background-color: #ddd; } .row:after { content: ""; display: table; clear: both; }
  18. Hello @JStahn,there is no default class which will provide you to set image in background ,you can use bootstrap 4 class to create good looking navbar after that you can use custom css to override that particular class and apply background-img tag for your desire background image like this: HTML: <nav class="navbar navbar-default"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="#">WebSiteName</a> </div> <ul class="nav navbar-nav"> <li class="active"><a href="#">Home</a></li> <li><a href="#">Services</a></li> <li><a href="#">Contact Us </a></li> <li><a href="#">About us</a></li> </ul> </div> </nav> css: .navbar .navbar-default{ background-image: url("Your Image path"); }
  19. Hello, we use dir tag to apply direction to our text for example : Add dir="rtl" to the html tag any time the overall document direction is right-to-left. This sets the base direction for the whole document. No dir attribute is needed for documents that have a base direction of left-to-right, since this is the default. <!DOCTYPE html> <html dir="rtl" lang="ar"> <head> <meta charset="utf-8"> ... Adding dir="rtl" to the html element will cause block elements and table columns to start on the right and flow from right to left. All block elements in the document will inherit this setting unless the direction is explicitly overridden. Same goes for ltr(Left to right ) {rtl(Right to Left)}
  20. Hello, You can use This For Providing Date Selection <input type="date"> Or You Can Also DO this: <select name="month"> <option value="Month" Selected></option> <option value="1" Selected>Jan</option> <option value="2">Feb</option> <option value="3">March</option> ... <option value="12">Dec</option> </select> <select name="day"> <option value="Select" Selected></option> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> ... <option value="31">31</option> </select> <select name="year"> <option value="Years"selected>Select Year</option> <option value="1900">1900</option> <option value="1900">1901</option> <option value="1900">1901</option> ... <option value="2019">2019</option> </select>
  21. You Can user Bootstrap To Make It easy , here is something that i made using bootstrap that might help you to create what you want. <!DOCTYPE html> <html> <head> <meta charset='utf-8'> <meta http-equiv='X-UA-Compatible' content='IE=edge'> <title>YourTv</title> <meta name='viewport' content='width=device-width, initial-scale=1'> <link rel="stylesheet" type="text/css" href="bootstrap.css"> <link rel="stylesheet" type="text/css" href="Fmovies.css"> <link rel='stylesheet' type='text/css' media='screen' href='main.css'> <script src='main.js'></script> </head> <body> <div class="card"> <div class="card-header"> <a href="https://fmovies.wtf/" class="badge badge-Info" style="font-size: 24px; text-decoration: none;">YourTv</a> </div> <ul class="link"> <li> <a href="https://fmovies.wtf/home" class="badge badge-dark">Home</a> </li> <li> <a href="https://fmovies.wtf/az-list" class="badge badge-dark">A-Z List</a> </li> <li> <a href="https://fmovies.wtf/movies" class="badge badge-dark">Movies</a> </li> <li> <a href="https://fmovies.wtf/tv-series" class="badge badge-dark">Tv-Series</a> </li> <li> <a href="https://fmovies.wtf/most-watched" class="badge badge-dark">Most Watched</a> </li> </ul> </div> </div><br/> <div class="container"> <div class="row"> <div class="col-4"> <a href=""> <img src="image/GOT.jpg" class="img-fluid" title="Game Of Thrones" alt="GOT"></a> </div> <div class="col-4"> <a href=""><img src="image/Money.png" class="img-fluid" title="Money Heist" alt="Money Heist"></a> </div> <div class="col-4"> <a href=""><img src="image/Stranger.png" title="Stranger Things" class="img-fluid" alt="Stranger Things"></a> </div> </div> <div class="row"> <div class="col-12"> <br/> </div></div> <div class="row"> <div class="col-4"> <a href=""> <img src="image/black.png" class="img-fluid" title="Black Mirror" title="Game Of Thrones" alt="Black Mirror"></a> </div> <div class="col-4"> <a href=""><img src="image/vikings.jfif" class="img-fluid" style="height: 220px;" title="vikings" alt="vikings"></a> </div> <div class="col-4"> <a href=""><img src="image/sherlock.jfif" title="Sherlock" style="height: 220px; width: 400px;" class="img-fluid" alt="Sherlock"></a> </div> </div> <div class="row"> <div class="col-12"> <br/> </div></div> <div class="row"> <div class="col-4"> <a href=""> <img src="image/13reason.jfif" class="img-fluid" title="Black Mirror" style="height: 220px; width: 400px;" title="13 Reason Why" alt="GOT"></a> </div> <div class="col-4"> <a href=""><img src="image/friends.jfif" class="img-fluid" style="height: 220px; width: 400px;" title="Friends" alt="Friends"></a> </div> <div class="col-4"> <a href=""><img src="image/see.jpg" title="See" style="height: 220px; width: 400px;" class="img-fluid" alt="See"></a> </div> </div> </div> <footer class="card-footer text-center"style="color:white">This Page reffers To Fmovies!</footer> </body> </html> here is a ss for your use , You Can re-adjust code for color and contain as you like
  22. Hi, You should try the following CSS. I hope it will work for you. tr:before { content: "Text"; font-size: 0.5em; display: inline-block; -webkit-transform: rotate(-90deg); transform: rotate(-90deg); }
  23. Hello @briansirbu, You should start with HTML then CSS after that you can go with the JavaScript and other required stuff for your site. You can refer to this link: https://www.w3schools.com/
  24. Hello @surajt, You can simply use the table. You can place both the images into two columns. This could be the easiest solution. Although you can set its height and width in such a manner that it could place horizontally in the same line. As <img> is an inline element.
×
×
  • Create New...