JSFiddle

  • Live Update #1 is the latest revision

    jQuery 1.9.1, HTML, CSS, JavaScript

    /*!
     * string_score.js: String Scoring Algorithm 0.1.22
     *
     * http://joshaven.com/string_score
     * https://github.com/joshaven/string_score
     *
     * Free to use ...
  • Custom Cursor

    No-Library (pure JS), HTML, CSS, JavaScript

    <button>Generate Extract</button>
  • confirm onclick

    No-Library (pure JS), HTML, CSS, JavaScript

    <a href="https://www.google.com/" onclick="return confirm('are you sure')">Google</a>
  • CSS Sign #1 is the latest revision

    No-Library (pure JS), HTML, CSS, JavaScript

    var terms = [
        "Database",
        "Datum",
        "SQL Server",
        "CRUD",
        "De-normalized",
        "Indexing",
        "Execution Plan",
        "dbMaster",
        "Schema"
    ];
    
    var buildings = [
        "Palace",
        "Hold",
        "Stronghold",
        "Castle",
        "Keep ...
  • Acrostic

    No-Library (pure JS), HTML, CSS, JavaScript

    <ul class="acrostic">
        <li>Terrible gaze</li>
        <li>His eye unwandering</li>
        <li>Ever set ahead - piercing all it sets upon</li>
    </ul>
  • Spell Checking

    No-Library (pure JS), HTML, CSS, JavaScript

    <h2>No Spell Checking</h2>
    
    <pre><code>&lt;input type=&quot;text&quot; /&gt;</code></pre>
    <input type="text" value="Spelled Wronnng"/>
    <pre><code>&lt;textarea spellcheck=&quot;false&quot;&gt;&lt;/textarea&gt;</code></pre>
    <textarea spellcheck="false">Spelled Wronnng</textarea>
    
    <h2>Spell Checking</h2>
    
    <pre><code>&lt;input type=&quot;text&quot; spellcheck=&quot;true&quot; /&gt;</code></pre>
    <input type="text" spellcheck="true" value="Spelled Wronnng"/>
    <pre><code>&lt;textarea ...</code></pre>
  • Color Wheel

    No-Library (pure JS), HTML, CSS, JavaScript

    // Creates canvas 400 × 400 at 50, 50
    var paper = Raphael(50, 50, 400, 400);
    
    var colors = [
        "RGB(209, 0,   0 ...
  • Using text-overflow: ellipsis; #1 is the latest revision

    No-Library (pure JS), HTML, CSS, JavaScript

    <h2>Ellipsis </h2>
    <p class="box ellipsis">Freshly squeezed lemon juice is used to make this zesty and tangy doughnut!  Coated in powdered sugar it's ...</p>
  • Text Selection

    No-Library (pure JS), HTML, CSS, JavaScript

    <h2>Browser Default:</h2>
    <div class="dark" >Dark-Themed </div>
    <div class="light">Light-Themed</div>
    
    <h2>Custom Selection:</h2>
    <div class="dark custom">Dark-Themed</div>
    <div class="light custom">Light-Themed</div>
    
    
    
    
    
    
    
    
    
    
    
    <!-- Post Info -->
    <div style='position:fixed;bottom:0;left:0; background:lightgray;width:100%;'>
        About this SO question:
        <a href='http://stackoverflow.com/q/32823562/1366033'>
            style of text selected (highlighted) with a mouse
        </a>
    </div>
  • Create HTML w/ JavaScript #2 is the latest revision

    No-Library (pure JS), HTML, CSS, JavaScript

    document.body.onload = addElement;
    
    function addElement () { 
      // create a new div element 
      // and give it some content 
      var newDiv = document.createElement ...