Jump to content

JimTrail

Members
  • Posts

    11
  • Joined

  • Last visited

Everything posted by JimTrail

  1. Hello W3SchoolsForums; Question 1: Does the PDO module have to be installed on the server for the below query to work? Question 2: Is the $dbh variable used only to assign to the $stmt variable or does it have an additional use? $stmt = $dbh->prepare("INSERT INTO Customers (CustomerName,Address,City) VALUES (:nam, :add, :cit)"); $stmt->bindParam(':nam', $txtNam); $stmt->bindParam(':add', $txtAdd); $stmt->bindParam(':cit', $txtCit); $stmt->execute(); Source: http://www.w3schools.com/sql/sql_injection.asp Thanks.
  2. Hello W3Schools Forum! This website keeps getting better. Used to I hardly ever visited it. Now it's one of my primary go-to destination points for programming information. I really do appreciate the information. I have got a question about the DISTINCT. http://www.w3schools.com/sql/sql_distinct.asp I cannot get the two column format to work. SELECT DISTINCT column_name, column_name // Can't get this one to work. FROM table_name; I can get the query to work with one column. SELECT DISTINCT column_name // It works fine using just one column. FROM table_name; It's worth noting. I have got a GoDaddy shared hosting. GoDaddy technical support says the hosting is on one of the older machines. The highest version of PHP is PHP 5.4 on the server. It's probably got an older version of MySQL, also. That could be the problem. I have been with GoDaddy since 2003. I am starting to look around for other hosting providers.
  3. Hello w3schools forum! Question: Which one of the w3schools Javascript examples shows how to refresh a page when user selects an option from a drop-down menu? I have got a page with a month drop down menu and a day drop down menu. I want the user to select the month. After the user selects the month I want to fill the drop down select menu with the proper amount of days for that month. Which one of the w3schools Javascript examples shows how to do that? Thanks.
  4. How come down at the bottom of this page the symbols turn into squares? http://www.w3schools.com/charsets/ref_utf_symbols.asp They are squares starting at Dec 9840 and below.
  5. Ingolme; Thank you for responding to my question. I appreciate the information.
  6. The ASCII table, and another table (I think it may have been the UTF-8 table) go used to be over at the left column at Html Home. How come they're not there anymore? Have they moved to another location on the w3schools web site?
  7. Ingolme; Thanks for responding to my question. I figured out part of my problem. I can put a white border around the table 20 pixels wide on each side. That way I won't need a <div> container. I was wondering if I might could use ems for the cell widths and then calculate the em value based on the number of characters in the cell content. I tried using 16 pixels per 1 em for the width. That made my cell too wide. I may end up using a trial and error approach for the cell/column widths. Thanks again.
  8. .Question: What is the best way to set the widths of table columns/cells? Or more specifically is there a way to calculate a column/cell width that is based on the width of the contents? I am working on pricing grids for a web site. The web site is going to have many pricing grids. The pricing grids are going to have different numbers of columns. 1). The <div> container(s) below must have a width of the following: a). the sum total of the table cells/columns plus b). 20 pixels on either side of the <table> (for a total of 40 pixels wider than the <table>).2). Each of the table columns/cells must have the same width. In the style sheet I have got the font size set at 16 pixels. body{font-size: 16px;} Also in the style sheet I have got the font size for the table set at 80%. table{font-size: 80%;} I could use a trial and error approach until I got a width that worked. That's kind of like hit or miss. I need to find the logical way of determining the cell width. That is, a bona fide way to determine a cell width which is based specifically on the number of digits/characters in the number(s) contained within the cell. This table is enclosed in a <div> container. The container must be 20 pixels wider than the table on the left and 20 pixels wider than the table on the right. The table columns/cells must each have the same width. <div class="Container"> <table border="1"> <tr> <td>$78.00;</td> <td>$107.00</td> <td>$1,055.00</td> </tr> </table></div> This table is enclosed in a <div> container. The container must be 20 pixels wider than the table on the left and 20 pixels wider than the table on the right. The table columns/cells must each have the same width. <div class="Container"> <table border="1"> <tr> <td>$78.00;</td> <td>$107.00</td> <td>$705.00</td> <td>$950.00;</td> <td>$107.00</td> <td>$1,267.00</td> </tr> </table></div> This table is enclosed in a <div> container. The container must be 20 pixels wider than the table on the left and 20 pixels wider than the table on the right. The table columns/cells must each have the same width. <div class="Container"> <table border="1"> <tr> <td>$87.36</td> <td>$119.84</td> <td>$163.52</td> <td>$224.32</td> <td>$271.04</td> <td>$337.12</td> <td>$350.56</td> <td>$456.96</td> <td>$539.84</td> <td>$601.44</td> <td>$673.12</td> <td>$840.00</td> <td>$1,009.12</td> <td>$1,181.60</td> <td>$1,419.04</td> </tr> </table></div> I would appreciate any help that anyone could provide. Thanks.
  9. newseed, Ingolme; Thanks for responding to my question. I appreciate the help. Thanks again.
  10. Hello W3Schools Forums! Question: Is it proper coding technique to use the "list-style: none;" directive in the <li> tag instead of the <ul> tag. I am wanting to put a heading for a list. The heading does not need to have a list marker. I am using the list-style:none; directive in the <li> tag. I think that the list-style: none; directive is intended to be used in the <ul> tag - not the <lu> tag. However, it seems to work okay using it in the <li> tag. I am just wanting to make sure putting the list-style: none; directive in the <li> tag is proper because I don't want it to cause issues later on. Here is the style sheet code:ul{list-style-type: circle;} li.ListHead{list-style: none;} Here is the Html markup:<ul><li class="ListHead">Heading For List</li><li>List item one</li><li>List item three</li><li>List item two</li></ul> Here is the way it looks on the page:Heading For ListºList item oneºList item threeºList item two If the above is not proper code can someone tell me how to put a heading on a list of items where it complies with the rules? Thanks in advance.
×
×
  • Create New...