Jump to content


  • Content count

  • Joined

  • Last visited

  • Days Won


Everything posted by Funce

  1. Funce

    Multiple SlideShows on same HTML page

    You could pass along the SlideShow's ID as an argument. That's the most simple way. (Instead using separate IDs rather than classes)
  2. What issues are you having in regards to it? I need something a bit more specific. Is it the webpage doesn't reach the bottom of the browser in some resolutions? That's fixable. Is it layout issues, and has nowhere for it to fit? That's fixable.
  3. My suggestion is to not use a fixed footer? Just put it in at the bottom of the page.
  4. Funce

    AJAX - A Question of Strategy

    I've created this implementation with a Currency API that has very stringent limits. I managed to get it, so even if someone was always using the page that needed the API data, it would never go over. By reusing the old data with a data age check. (By storing what time the data was saved) AJAX call into 'controller' which then checks the Database, to see how old the data is. If its new, I get the data from the Database and return it. If its old, I get the data from the API, update the database and return the information. It works quite well. It also makes 'subsequent' calls to the 'controller' lightning fast.
  5. Funce

    Feedback on web page's semantic elements

    A lot of these things that you've asked about will be unique to you unless you're working with enforced styling such a development team. Code wise, a lot of it looks good. Only things that I'll pick out it: Try throwing your CSS into a separate file. It will unclutter the main HTML code, and you'll be able to reuse it for other pages. In my opinion <br /> tags are kind of a crutch? They have their place but, most of the time, you'll be able to do better with CSS And on the note of the <br /> tags, one of them doesn't have an ending slash. This just looks like its been forgotten and it isn't make or break, however something that's really important is to be consistent across your tags. Your <a> tags inside the <footer> have spaces in between the href and = whereas the ones on your <aside> do not. Just the main thing is to be consistent. Have a look into the DRY principle. "Don't repeat yourself"
  6. You've stated that you have a page that requires users to be logged in to view. Could you duplicate the code that checks if they're logged in and place it before the code you've posted?
  7. Funce

    Calling javascript in html

    Probable Duplicate of
  8. Funce

    adding java script to html

    @JRJ Also take a look at this thread, it may have a couple of notes you may be able to pick up on
  9. Funce

    Help: "Simple" issue driving me insane.

    Has your Zapier whitelisted your first submission location? To prevent others from using it? "Thanks for your message!" Is this an alert? Like one you press OK on? What browser do you use? If chrome, try checking the network tab (in Developer Tools) with the 'preserve log' option set when you submit. And find the one which matches your Zapier URL. That might give you a little insight into what's going on. Whether its redirecting or doing anything in particular.
  10. Funce

    alert for dropdown list

    Is this a new requirement? If not, I apologise for misunderstanding. What you'll need to do is bind an `onchange` event to a function which: Checks the value of `v` (used in my example) If its not "(empty)" then show the other dropdown list.
  11. Funce

    adding java script to html

    Visual Studio Code. Although you would find out with any editor that has error checking for syntax errors. Have you been able to communicate with the Data Logger? Or is your Data Logger more of a page preprocessor that would inject the values on page load?
  12. Funce

    Table has error

    Apologies for the abruptness, but do you have a new question? I'm not able to figure it out from your last posts.
  13. Funce

    adding java script to html

    I apologise for the confusion. I'm referring to the contents of the file posted. This is what's currently defined as the style body. <style> html, body { height: 100%; width:100%; font-family:helvetica; margin:0; padding:0; background-color: #000000; color:white; } .button { position:absolute; top:2.5vh; border:0; background: #0087cc; border-radius: .3vw; box-shadow: 0 .375vw 0 #006599; color: #fff; cursor: pointer; font-size:1.2vw; margin: 0; outline: 0; padding: .5vw .5vw; transition: all .1s linear; } .button:active { box-shadow: 0 .15vw 0 #006599; transform: translateY(3px); } .displayBox { width:49vw; background-color:#008800; margin:0 auto; margin-bottom: 1.5vh; border-radius:1vw; } .header { height:10vh; border-top: 1px solid black; /* For some reason, without this, browsers will sometimes display scrollbars unnecessarily. Bad browsers. Bad. */ border-bottom: .4vw solid white; } .displayTable { margin:0 auto; margin-left:1vw; margin-right:1vw; width:47vw; font-size:2.4vw; } .displayTable td { width:21%; } .displayTable td:nth-child(1) { width:36%; } .smallTable { padding: .5vw 1vw; font-size:2.4vw; background-color:#0033cc; border-radius:1vw; width:100%; } .smallTable td:nth-child(2) { text-align:right; } .statisticColumn { width:49vw; } .statisticParent { position:absolute; top:11vh; width:100vw; height:80%; } .title { border-radius: 1.5vw; width: 40vw; font-size: 3vw; font-weight:bold; margin: 0 auto; margin-top: 1vh; background-color:#0033cc; border: 5px solid #3366ff; text-align:center; } #a80, #a81, #a82, #a83, #a84, #a85, #a86, #a87, #a88, #a89 { background-color: yellow; color:black; } #a0,#a1, #a2, #a3, #a4, #a5, #a6, #a7, #a8, #a9, #a10, #a11, #a12, #a13, #a14, #a15, #a16, #a17, #a18, #a19, #a20, #a21, #a22, #a23, #a24, #a25, #a26, #a27, #a28, #a29, #a30, #a31, #a32, #a33, #a34, #a35, #a36, #a37, #a38, #a39, #a40, #a41, #a42, #a43, #a44, #a45, #a46, #a47, #a48, #a49, #a50, #a51, #a52, #a53, #a54, #a55, #a56, #a57, #a58, #a59, #a60, #a61, #a62, #a63, #a64, #a65, #a66, #a67, #a68, #a69, #a70, #a71, #a72, #a73, #a74, #a75, #a76, #a77, #a78, #a79 { background-color: red; } <script= text/javascript> var StopTimePivatic = [[175]]; if (StopTimePivatic != 0){ #b[[141]]{ style.background-color= silver; } } else{ #b80, #b81, #b82, #b83, #b84, #b85, #b86, #b87, #b88, #b89, #b90 { style.background-color = Yellow; style.color = black; } #b0, #b1, #b2, #b3, #b4, #b5, #b6, #b7, #b8, #b9, #b10, #b11, #b12, #b13, #b14, #b15, #b16, #b17, #b18, #b19, #b20, #b21, #b22, #b23, #b24, #b25, #b26, #b27, #b28, #b29, #b30, #b31, #b32, #b33, #b34, #b35, #b36, #b37, #b38, #b39, #b40, #b41, #b42, #b43, #b44, #b45, #b46, #b47, #b48, #b49, #b50, #b51, #b52, #b53, #b54, #b55, #b56, #b57, #b58, #b59, #b60, #b61, #b62, #b63, #b64, #b65, #b66, #b67, #b68, #b69, #b70, #b71, #b72, #b73, #b74, #b75, #b76, #b77, #b78, #b79 { style.background-color = red; } } </script> </style> When I pass it through my editor, numerous errors are thrown. The Javascript is using CSS selectors, with Javascript commands. Its quite... interesting.
  14. Funce

    Table has error

    I wouldn't have an answer for why that is. Have you read further? Is it a chapter on error checking? I know some examples in books do that on purpose to teach the value of debugging errors. I have a C# book that did just that.
  15. Funce

    Table has error

    I didn't read it too thoroughly. It might've been a transcription error. CREATE TABLE IF NOT EXISTS forum( post_id INT UNSIGNED NOT NULL AUTO_INCREMENT, first_name VARCHAR(20) NOT NULL, last_name VARCHAR(40) NOT NULL, subject VARCHAR(60) NOT NULL, message TEXT NOT NULL, post_date DATETIME NOT NULL, PRIMARY KEY (post_id) ) Try this. It doesn't have multiple `first_name` columns.
  16. Funce

    Table has error

    Where are you pasting this code? That error doesn't look like a PHP error. (Which I'm assuming that is being written in) If you've pasted that in directly to phpMyAdmin for instance, you'll need to try something like this instead. Please let me know how it goes! CREATE TABLE IF NOT EXISTS forum( post_id INT UNSIGNED NOT NULL AUTO_INCREMENT, first_name VARCHAR(20) NOT NULL, last_name VARCHAR(40) NOT NULL, first_name VARCHAR(20) NOT NULL, subject VARCHAR(60) NOT NULL, message TEXT NOT NULL, post_date DATETIME NOT NULL, PRIMARY KEY (post_id) )
  17. Funce

    alert for dropdown list

    I'm hoping this is a snippet, I couldn't get this to run originally, but you said you could so no matter. Try adding a value to the Select Option, and then check if that is the option currently selected. <select id='opt2' name='USUnits' onchange="showForm1()"> <option value="">Select Option</option> <option value="0">Lbs/Sec</option> <option value="1">Lbs/min</option> </select> Then it would be as simple as var v = document.forms["myForm"]["USUnits"].value; if (v == "") { alert("SMass flow unit selection must be selected"); return false; } I highly recommend you use more descriptive variable and field names. It was a little hard impossible to follow the jq, jjq, jqq, ojq, and what they meant without checking the definitions of them.
  18. Funce

    adding java script to html

    I'm not sure very many browsers have the capacity to run JavaScript inside CSS. Does this otherwise work with any verbose commands like Alert or Console.Log? <script> tags have no meaning inside <style> tags. Not to mention that the 'JavaScript' you have written is of totally the wrong format. What are you attempting to achieve here?
  19. Funce

    Help: "Simple" issue driving me insane.

    Does your Zapier have any logging systems? If so, is there any difference in logging results between using local and using the server? Are you expecting a different result? Are you supposed to redirect to a separate page? Does your webhook activate at all?
  20. Funce

    Inconsistent results when using the color: property

    I've had a look through and its the variations on handling between `color`, `text-shadow` and `background-clip` I noticed that some browsers handle their styling groupings differently. Its illustrated clearly with the discrepancy between Chrome, Edge, and Internet Explorer. Internet Explorer doesn't obey `background-clip: text`. Hence you can't see the text at all. Take a peek at https://developer.mozilla.org/en-US/docs/Web/CSS/background-clip to check for compatibility. Edge groups its opacity for its `text-shadow` with that of its normal `color` hence when you use `transparent` it makes the shadow transparent also. It does however obey `background-clip` so you can still see the text. Chrome seems to keep all of them separate with none affecting the others. If you wish to support these browsers you might want to look into browser specific styling.
  21. Funce

    Responsive Design - More iPhone Alignment Problems

    It looks like to me you're missing a `float: none;` for that section that you're referring to. The specific spot you're looking for is gc_template.css - Line 112 #middle { width: auto; width: -moz-auto; margin-left: 0px; float: none; /* Add this */ } From my end, this looks like it works. Feel free to let me know if it does not. This section, in particular, was escaping the page wrapper, making me think there was some alignment or flex going on. I was not incorrect.
  22. Funce

    Line Break in email not working

    Can confirm, your issue stems from using `mysqli_real_escape_string`. That function just half-protects your queries from any anomalous characters, by escaping them, that may end up executing unwanted things. Not particularly useful in any case. Any special characters inside that function are taken literally `\r\n` rather than as they're supposed to be which is a Carriage Return and LineFeed Character. (Basically new line) In this case you won't even need to use mysqli_real_escape_string. You're not putting the data into the database are you? If you are I suggest reading up on 'Prepared Statements'.
  23. Funce

    having trouble navigating your website.

    Here is the documentation on Javascript Sessions. https://www.w3schools.com/jsref/prop_win_sessionstorage.asp Its stored under 'Window' in your link.
  24. Funce

    How do I get specific values from a rss feed

    If you've already managed to pull the RSS feed, and you know WHERE to get this XML from on your local file system(or otherwise), what you want is to find out how Python can parse XML strings/files for you. Just note that the inbuilt abilities of python are vulnerable to maliciously constructed XML so I recommend checking some of these out. For Python3: https://docs.python.org/3/library/xml.html https://pypi.org/project/defusedxml/ You seem pretty onto things, so don't hesitate to ask questions. There are loads of knowledgeable people here. Welcome to the W3Schools Forum!
  25. Funce


    That's cool! I suggest checking out the HTML tutorial here: https://www.w3schools.com/html/default.asp You can find nearly everything there, but it should be a good thing to start with.