Jump to content

Ingolme

Moderator
  • Posts

    14,897
  • Joined

  • Last visited

  • Days Won

    176

Everything posted by Ingolme

  1. That's nice, but your not actually explaining how you came up with that code and why it works.
  2. There are some pages regarding Regular Expressions on W3Schools. For more in-depth reading on the subject, go to http://regular-expressions.info
  3. You can make an AJAX request each time the user stops scrolling remembering the last scroll position rather than wait for an unload event. Where you store it depends on how long you want this volatile information to last.
  4. I think in SQL it would be something like this: SELECT * FROM high_scores ORDER BY score DESC, date (Supposing the date of the high score was stored in the table)
  5. The <body> container is as small as the content it contains, but the <html> element does occupy at minimum the whole window. That's why setting a background-image to the <html> shows it on the full window.
  6. Position? You mean mouse position or something else?
  7. I've had experience with three keys being pressed at the same time and not receiving all the signals. I don't know if this is on all keyboards or just laptop keyboards but there's nothing at the Javascript level (or ActionScript as I've experienced in the past) that can be done to fix it. It's possibly a hardware limitation but I haven't really researched beyond my own experience.
  8. The click event was put onto the whole box. The "more" link is actually fake. You'll need to modify the script so that the click event is applied to the link in particular.
  9. You've used an assignment operator in the place of a comparison operator.
  10. CSS image sprites are the most common way to do this: http://w3schools.com...age_sprites.asp <div> is block element, <span> is an inline element. Block elements take up the full width of their container and push content that follows it below. Inline elements can go within text without changing the flow of the page.
  11. None of the languages are particularily different than their predecessors, they just have a few more features added to them for convenience.
  12. Ingolme

    HTML Imaging

    You need to know what directory the page is in, what directory the image is in and which is the root directory.
  13. It is possible that the <base> element is giving a wrong path to the stylesheet, see if it works when removing it. Due to the fact that an image is an inline element by default, the best way to center it is to put it into a container and set the text-align to "center"Example: .container { text-align: center; } <div class="container"> <img></div>
  14. It depends on which languages you're using.There's a forum for all the languages used in web development. If the language you're using for mobile development is not among the forums then you probably are no longer developing for the web.
  15. The second background rule is overriding the first one. The background color is meant to be displayed before and while the image is loading, and also for if the image isn't found. The color should be there to make the text in front of it visible when the image hasn't loaded. text-shadow is a CSS 3 property. It is not valid CSS 2.1, but it was valid in the short-lived CSS 2. The version of CSS doesn't matter much, all that matters is what properties browsers support and how old of a browser you're planning to support.
  16. I don't see the problem. It looks fine to me in Firefox.
  17. The <br> element before the <span> is probably using the line-height of the larger font. A quick fix would be to put the <br> element inside the <span>.
  18. It sounds like you aren't reporting errors. Either that or your program isn't meant to print anything. Add this at the very beginning of your code to make sure PHP tells you of any errors. ini_set('display_errors', 1);error_reporting(E_ALL);
  19. Ingolme

    Mathematical help

    The sin() and cos() functions use radians. Instead of 360/7 use 2*PI / 7. Also, since this is a value that never changes, calculate it once outside of the loop.
  20. Some browsers just use rel="icon" rather than "shortcut icon". Maybe that will make it work.
  21. Ingolme

    MP4 Videos

    A good technique is to use the HTML 5 <video> tag with fallback to flash.The structure would be similar to this: <video> <object> You need an HTML 5 compliant browser or the Flash plug-in to view this content. </object></video> Look up the <video> tag in the HTML 5 reference, and search for the Flash-Satay method to learn how to use the <object> tag for Flash.
  22. Given your code, one would assume that you're trying to add data to a table with unlimited fields. How many fields does the table have? image1, image2 ... imageN?
  23. In standards complicant more, the <body> element extends only as far as the content.Rather than putting it on the <body> element try putting it on the <html> element. Perhaps another solution would be to set the height of the <body> and <html> elements to 100%
  24. Once the footer goes up far enough, all the space below it is going to be the color of the <html> element's background. The best thing would be to start over from the beginning.You have multiple elements: <div id="header"></div><div id="left_column"></div><div id="right_column"></div><div id="content"></div><div id="footer"></div> You use float and clear to put them in their proper position, use margins to prevent content from wrapping around the floated elements.Apply a background color to the <html> and <body> elements to prevent white from appearing anywhere. html, body { background-color: #CCCCCC; }#left_column { float: left; width: 200px; }#right_column { float: right; width: 220px; }#content { margin-left: 200px; margin-right: 220px; }#footer { clear: both; } This is just the basics, look for tutorials on CSS float layouts to learn more.
×
×
  • Create New...