• Content count

  • Joined

  • Last visited

  • Days Won


Everything posted by Ingolme

  1. It converts the string into a number so that math operations can be done with it. You should read about data types:
  2. You can write HTML and Javascript in any text editor.
  3. The RSS item has a <link> field specifically for the URL of the resource you're sharing. An RSS reader may not necessarily parse HTML, so you should make use of the proper RSS fields. You can't send POST variables from RSS, but a link can contain a query string from which PHP can create $_GET variables.
  4. I don't know where there's a list. Generally you should never develop for specific devices, you should just make your layout flexible enough (with help of media queries) to wotk on any screen regardless of size. This is usually achieved by testing your page in the responsive mode of your browser and resizing the viewport until it breaks, then you add a media query to correct the layout. But for reference, I start off with a design for the following devices, then make extra adjustments later: Small mobile (iPhone 4):Up to 374px (I usually use this just for specific elements that didn't fit) Mobile or small mobile in landscape): Up to 767px Tablet portrait: 768px Tablet landscape: 1024px (breakpoint usually between 800px and 900px) Desktop: 1025px and above Some people make designs for large desktop computers (1440px and above), but that's up to you. In general, there isn't one specific strategy for responsive design, this is just the approach from the companies I work with.
  5. The "pixels" used in CSS are not real pixels, they're called "device-independent pixels". A phone's native width may be 1080 pixels, but that usually translates to 375 device-independent pixels, small phones are usually 320 pixels, tablets are 768 pixels in portrait mode and 1024 pixels in landscape. Pixels are a more accurate way to measure devices because most of the time a device doesn't actually know its actual physical size and it just tries to make estimates.
  6. As far as the framework goes, W3.CSS just uses CSS. All the Javascript in the examples is added in separately from the library. I would assume people realize they're using Javascript when they start putting <script> tags on the page and copying Javascript code from the examples. I do think it's very important to teach new developers about accessibility and to provide a non-Javascript fallback when writing Javascript code, but I don't think it's necessary to put a warning about it in every single tutorial page that shows Javascript in it. Accessibility is not required by law except in government websites and banks or similar institutions.
  7. You already made a topic for this here:
  8. Please stop making duplicate threads. Your question was answered here:
  9. This is not a simple task, you would need to do a whole lot of programming to replicate this Flash application in HTML 5. Perhaps to start off you should learn a bit about HTML 5 canvas and then try to build upon your Flash source code.
  10. It appears to work in Firefox. Internet Explorer has issues with certain font files where they need some permissions to be set. It gives the following message " @font-face failed OpenType embedding permission check. Permission must be Installable." The font file has to be changed, you could also a WOFF file instead of OTF. If you're certain that you're using this font with the author's permission, you can use this tool to convert to font to be usable in Internet Explorer.
  11. So the W3Schools site does have a mistake. The staff of the website is almost never on the forums, so your best chance to provide feedback is to visit the page that has the problem and scroll down and click on the "Report Error" button at the bottom of the page.
  12. Both of those usages look valid to me. Is there any particular reason why the parentheses shouldn't be inside the ruby text?
  13. It only shows the source of files in the same local filesystem, regardless of domain name. If, for some reason, it did load a file from a URL it would only be able to show what was returned by that URL through HTTP.
  14. The issue seems to be this section of your CSS: @media only screen and ( min-width: 981px ) { .et_pb_button_4 { display: none !important; } .et_pb_text_21 { display: none !important; } .et_pb_text_23 { display: none !important; } .et_pb_text_16 { display: none !important; } .et_pb_text_9 { display: none !important; } .et_pb_text_3 { display: none !important; } .et_pb_text_5 { display: none !important; } .et_pb_text_7 { display: none !important; } .et_pb_text_1 { display: none !important; } }
  15. This is the most primitive example using just Javascript: <textarea id="source"></textarea> <button id="action">Run</button> <iframe id="destination"></iframe> <script> var source = document.getElementById("source"); var destination = document.getElementById("destination"); var button = document.getElementById("action"); button.addEventListener("click", run, false); function run() { var d = destination.contentDocument;; d.write(source.value); d.close(); } </script> We have a textarea with the HTML code, an <iframe> where the HTML page is rendered and a button that copies the code from the textarea into the page. This will not look very pretty, so you should style it with CSS. There's also a server-side way to do it, but it is more complicated and you need to learn a server-side language. The advantage of the server-side version is that it will work even on browsers that have Javascript disabled. The concept is simple: You have a form that has an iframe as a target, when the form is submitted, the HTML code that was sent to the server is printed directly onto the page inside the iframe.
  16. It looks like one of the pages has CSS setting the font family and size and the other page does not. If you included a CSS framework it most likely is setting its own default font.
  17. If you get a 301 or 302 response, check the Location header in the array and make another get_headers() call to that URL to see if it exists.
  18. That refers to a constant. It would be defined in the Feed class as const ATOM = 'Some value'
  19. This is unfamiliar to me, since other Javascript frameworks and libraries I've worked with did not actually alter Javascript syntax. If this really is a browser-side library, it seems pretty inefficient to parse all that code just to have a prettier syntax. It would have to be compiled into real Javascript, either using a server-side compiler or during runtime with a Javascript program.
  20. What does your HTML look like?
  21. Did you inspect your HTML element to see what styles are being applied to it?
  22. This does not appear to be browser Javascript, which does not support import statements or typed arrays. It seems like there would be an issue in your render() call because your string is not quoted. ReactDOM.render( '<META http-equiv="refresh" content="0;URL=Index.html">', // Added quotes to the string document.getElementById('app') );
  23. The inner list should be placed inside a list item. No element can be a direct child of <ul> or <ol> except an <li> element. <ol> <li>Inner list <ol> <li>Item 1</li> <li>Item 2</li> </ol> </li> <li>Item 2</li> <li>Item 3</li> <li><img src="" alt=""></li> </ol>
  24. I'm not seeing the issue in the example page. I tested in Firefox, Chrome and IE11. It works down to 320px wide, which is the width of the smallest phones today.
  25. I'm not sure what code you're using to get the mouse offset, but once you have it you can calculate the correct position by dividing the canvas real size by its visible size. // Assuming we already have a reference to canvas and the mouse's position // relative to it is in visibleX and visibleY var horizontalRatio = canvas.width / canvas.offsetWidth; var verticalRatio = canvas.height / canvas.offserHeight; var realX = horizontalRatio * visibleX; var realY = verticalRatio * visibleY; // Do something with realX and realY