Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by Ingolme

  1. That code looks correct. If the <div class="card-content"> element has a float CSS property then it would cover up the image with an invisible wall and prevent clicks from getting through to the image. There would be no way to solve it without changing the CSS.
  2. It won't stop the responsive behavior of the layout itself, but you can remove the <meta> viewport tag from the HTML template. That will cause mobile devices to display the page at a desktop scale.
  3. Cut out everything from top.htm except for the section of code that contains the menu. w3-include is not like an iframe, it does not need a complete HTML document. You can put the Javascript into an external .js file and use a <script> tag to include it right below the place where you include top.htm. top.htm should be reduced to just this: <div class="topnav" id="myTopnav"> <a href="../index.htm">Home</a> <a href="../whatsnew.htm">What's New</a> <a href="../calculators.htm">Calculators</a> <div class="dropdown"> <button class="dropbtn">Tax <i class="fa fa-caret-down"></i> </button> <div class="dropdown-content"> <a href="../personaltax.htm">Personal Tax</a> <a href="../taxrates.htm">Tax Rates</a> </div> </div> <div class="dropdown"> <button class="dropbtn">Financial Planning <i class="fa fa-caret-down"></i> </button> <div class="dropdown-content"> <a href="../freein30.htm">Free In 30!</a> <a href="../save_money.htm">Save Money</a> </div> </div> <a href="../resources.htm">Resources</a> <a href="../sitemap.htm">Site Map</a> <!-- the &#9776 provides the hamburger icon --> <a href="#" class="icon">&#9776;</a> </div> In the external Javascript file, you would put your Javascript function and then you would add some code to attach an event listener to the link as follows: var icon = document.querySelector("#myTopNav .icon"); icon.addEventListener("click", myFunction); The code on your main HTML page should look something like this, but with the correct path to your external Javascript file. <div w3-include-html="_borders/top.htm"></div> <script> includeHTML(); </script> <script src="filename.js"></script> My preference is to not use Javascript includes because it slows down the page loading, search engines can't see the content and users who block Javascript won't see anything on your page. Usually you'll have a server-side programming language which does the includes for you.
  4. I just went through your code, you haven't written any Javascript, so I can't point out where you might be having any mistakes.
  5. I would guess that includeHTML() won't actually run any Javascript that is in the included HTML file, you should put that Javascript in a separate file and use a <script> tag in the main document for it. The w3-include should probably only be used for short pieces of pure HTML which should not contain any <!DOCTYPE>, <html>, <head>, <body>, <style> or <script> tags. Things start behaving unpredictably if you try to do anything other than load plain static content.
  6. What exactly are you trying to achieve? With a purely client-side database anybody can register and log into your website and set their own permissions. Multiple people will be able to have accounts with the same names and email addresses and if they go to a different device they will have to create the account over again. I can check your files later when I have some more time to see why they are not working as expected. Files running from the desktop usually have more restricted security settings so that may be an issue.
  7. Nobody was recommending books or websites, this looks like a pre-written response being mass posted on a lot of different forums for the purpose of advertising.
  8. The list is already ordered, you would only need to specify the type if the type itself really matters. By default it's numbers and most of the time that's good enough.
  9. The flags are wrapped in <div> tags, so they're blocks and force adjacent content to the next line. It's easy to fix. All of these divs have a class "svg-flag", so you can just display them as inline blocks. You can add vertical-align to better align them with the text. .svg-flag { display: inline-block; vertical-align: middle; }
  10. To preface this post, I am not a W3Schools staff member, I am just a forum moderator. My views are personal and don't represent W3schools at all. You probably should see the list of hundreds of well established programming languages that did not make it on W3Schools. W3Schools makes tutorials for languages that people will find useful in their job every day. If Julia becomes a widely adopted language, perhaps a tutorial will be made.
  11. The reason that the script is not working is likely because the "uploads" directory has not yet been created. You can use file_exists() to check if the directory exists yet and if it does not you can use mkdir() to create it. PHP does understand relative paths. The only reason you need to use __DIR__ is if your script is being included in another file or if the current working directory has been changed. The working directory may have been changed with the chdir() function.
  12. Ingolme


    Internet Explorer does not support WAV, other browsers do. If it's just for browser compatibility you can use WAV files if you don't care to support Internet Explorer or Microsoft Edge. As for whether you should use it, I would recommend against it. The files take longer to load for the user and they take up a lot more bandwidth on the user's end. Many people have data caps, so it is a good idea not to waste it unnecessarily.
  13. They work the same, but it preferable to use CSS as mentioned on MDN: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ol CSS should be in an external stylesheet rather than in a style attribute.
  14. Ingolme

    Unsecure Website

    You can use an internet address as the src attribute of the iframe and it will work without any problem. If you write HTML between the iframe tags, that won't work. The browser ignores it. I'm referring to code like this: <iframe> <table> <tr> <td>...</td> <td>...</td> <td>...</td> </tr> </table> </iframe> That table gets ignored, the only thing that gets shown in the iframe is whatever is in its src attribute.
  15. Ingolme

    Unsecure Website

    The link points to this page: https://www.hashimori.com/Emblem/hito.html. Regardless of whether I land on it by clicking the link or by opening it right in by browser, all it shows is nine empty iframes. I see that there is HTML inside the iframes, but browsers never display anything that is between <iframe></iframe> tags.
  16. "+" is used for string concatenation. If the values are strings then they will use the string version of the "+" operator. You have to convert the value to a number before operating in order for it to work as you intend it to. var x = Number(byyr.value); var y = x + 1;
  17. Ingolme


    Firefox says "Media resource http://c-compiler.com/myfiles/stgeorges-201219.wav could not be decoded." I'm not an expert in audio and video encoding, it's a complicated subject, but I would guess that the encoding used by the WAV file was not supported by the browser. According to this mozilla ticket: https://support.mozilla.org/en-US/questions/1228379
  18. The error message you are getting indicates that the PHP version is most likely the issue. Make an empty PHP file and run the phpversion() function to verify that the version is what you need it to be.
  19. Your server has to be running PHP 7.1 or higher to allow the public modifier on the const keyword.
  20. Ingolme


    I'm pretty sure that's true. Even if it were supported, I would recommend never using WAV because WAV files are uncompressed and would take up a whole lot of data/bandwidth for your users.
  21. The best way to make the site staff aware of the problem is to click the "REPORT ERROR" button at the bottom of the page, since they almost never visit the forums.
  22. Ingolme

    Undefined Variable

    The $lang_type variable is only being created on specific conditions, if these conditions are not met then you will get a warning. You should initialize $lang_type with a default value outside of all of the if statements.
  23. Browsers have security in place to prevent local scripts from mining information from the user's computer. Aside from that, if the image you are loading is not on your computer then the cross-origin protection will apply. I would suggest installing server software, such as XAMPP, on your computer.
  24. The value is being initialized at the beginning of the script. var slideIndex = 1; showSlides(slideIndex);
  • Create New...