Jump to content

Search the Community

Showing results for tags 'example'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • W3Schools
    • General
    • Suggestions
    • Critiques
  • HTML Forums
    • HTML/XHTML
    • CSS
  • Browser Scripting
    • JavaScript
    • VBScript
  • Server Scripting
    • Web Servers
    • Version Control
    • SQL
    • ASP
    • PHP
    • .NET
    • ColdFusion
    • Java/JSP/J2EE
    • CGI
  • XML Forums
    • XML
    • XSLT/XSL-FO
    • Schema
    • Web Services
  • Multimedia
    • Multimedia
    • FLASH

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Languages

Found 10 results

  1. What's the issue? The example I am referring to is the Fisher Yates implementation on this page: https://www.w3schools.com/js/js_array_sort.asp This is the code in question: var points = [40, 100, 1, 5, 25, 10]; for (i = points.length -1; i > 0; i--) { j = Math.floor(Math.random() * i) k = points[i] points[i] = points[j] points[j] = k } If you run the example you will see the elements of the array shuffle around and everything will seem to be working as expected. The issue is subtle. With the above code block the element in the last position of the array can never
  2. I have tried some custom code to insert a road sign image into my lecture title, but it's not showing. Here's my snapshot screen I photoshopped (green highlight). This code is not showing up in the title. <img src="https://upload.wikimedia.org/wikipedia/commons/thumb/b/b2/Liberian_Road_Signs_-_Regulatory_Sign_-_Stop.svg/120px-Liberian_Road_Signs_-_Regulatory_Sign_-_Stop.svg.png" style="width:10%;height:10%;"> Your assistance will be very much appreciated. James
  3. Hi all, please pardon me if i post to wrong section (it took me 3 days to even gain access this site). In your xsd tutorial, the Example 2 description is plain wrong, and it is confusing people. The faulty page is here: https://www.w3schools.com/xml/el_all.asp The error must be there for a long time, it even has its own post on stackoverflow https://stackoverflow.com/questions/5677154/how-do-i-make-items-optional-in-xsall Quote: "The example above indicates that the "firstname" and the "lastname" elements can appear in any order and each element CAN appear zero or one time!" To
  4. Hello everyone, I have a question about the PHP - AJAX example (http://www.w3schools.com/php/php_ajax_php.asp). In the PHP file, there is the variable " $hint ". But what is this variable used for? Here the code: $q = $_REQUEST["q"];$hint = "";// lookup all hints from array if $q is different from ""if ($q !== "") { $q = strtolower($q); $len=strlen($q); foreach($a as $name) { if (stristr($q, substr($name, 0, $len))) { if ($hint === "") { $hint = $name; } else { $hint .= ", $name"; } } }} You are dec
  5. Yes I'm a newbie in AJAX '&&' JavaScript. As I'm a pupil here, I find hurdle almost in any code... There is an AJAX code with some number value in it, like 4 - 200, but I can't understand the nature of this digits or what they are indicating... function loadDoc() { var xhttp; if (window.XMLHttpRequest) { // code for modern browsers xhttp = new XMLHttpRequest(); } else { // code for IE6, IE5 xhttp = new ActiveXObject("Microsoft.XMLHTTP"); } xhttp.onreadystatechange = function() { if (xhttp.readyState == 4 && xhttp.status == 200) { document.get
  6. According to http://www.w3.org/TR/html5/document-metadata.html#the-base-element shouldn't the example in http://www.w3schools.com/tags/tag_base.asp have a base tag that points to the current page (not just the directory)? That would solve some problems with link fragments and query strings as outlined in e.g. http://stackoverflow.com/questions/1889076/is-it-recommended-to-use-the-base-html-tag EDIT: This is a possible way I'd modify the example: <head><base href="http://www.w3schools.com/page.html'>http://www.w3schools.com/page.html" target="_blank"></head><body&g
  7. some of the Angular examples don't work with current version (1.3.11) of angular.js the example at http://www.w3schools...y_ng_controller works fine until you change the version from 1.2.26 to 1.3.11 so changing the line <script src= "http://ajax.googleapis.com/ajax/libs/angularjs/1.2.26/angular.min.js"></script> to <script src= "http://ajax.googleapis.com/ajax/libs/angularjs/1.3.11/angular.min.js"></script> breaks the example. This also applies to other examples that use controllers.
  8. CMS/Forum Session/cookie management and security, picking a good example. I am starting an opensource GPL forum project primarily for the sake of learning. I have been looking at the different implementations for user authentication and session management of different CMS and forum packages.Trying to go through and learn what is being done. Also wondering which makes for the best example of a good clean way to implement it.I would prefer to store the bare minimum cookies client side and keep most data in session variables server side.Unless there is a good reason to have another cookie or two,
  9. Hi,I tried to apply this example on my website and it didn't work.The problem is that the text is also included in the opacity and then you get a transparent text: My website: My code: shaltermain.htmlmystyle.css thanks!
  10. Firefox(and not only firefox i think, all modern browsers) have the ability of storing passwords and username so that when you go in a site where credentials are required, the browser send these automatically to the server, the result being no need to give credentials again and again when you visit a site. If the above actually happens(if i am correct i mean), is this considered an example of basic http authentication?
×
×
  • Create New...