This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html> | |
| <head> | |
| <!-- Run in full-screen mode. --> | |
| <meta name="apple-mobile-web-app-capable" content="yes"> | |
| <!-- Make the status bar black with white text. --> | |
| <meta name="apple-mobile-web-app-status-bar-style" content="black"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script type="text/javascript"> | |
| $(document).ready(function() { | |
| var href = $("#redirect_url")[0].href; | |
| $("a#replace_me").attr("href", href); | |
| $("a#replace_me").text(href); | |
| $("#redirect_to").hide(); | |
| }); | |
| </script> | |
| <p>Greetings. We are now redirecting you to the site that you requested.</p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>JS Bin</title> | |
| </head> | |
| <body> | |
| <script id="jsbin-javascript"> | |
| /* Below is the structure of the JSON data that will be stored in MongoDB */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <title>Document</title> | |
| </head> | |
| <body> | |
| Input: <input type="text" ng-model="hello"><br> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // http://localhost:4000/api/postcodesNear?postcode=4101&range=2 | |
| action('postcodesNear', function () { | |
| var earthRadius = 6378; | |
| var qPostcode = req.query.postcode || 4101; | |
| var qRange = Number(req.query.range) || 2; | |
| Postcode .findOne({ 'postcode': qPostcode }) | |
| .run(function(err, postcode) { | |
| if (err) send(err); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>JS Bin</title> | |
| </head> | |
| <body> | |
| <script id="jsbin-javascript"> | |
| var _fragment = document.createDocumentFragment(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| uiData = uiData.replace('?',''); | |
| var uiDataArray = uiData.split('&'); | |
| var eObj = {}; | |
| uiDataArray.map(function(data){ | |
| var eArray = data.split('='); | |
| eObj[eArray[0]] = eArray[1]; | |
| console.log(eObj); | |
| return eObj | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var emails = querySelectorAll('.email); | |
| var emailsArr = [].slice.call(emails); | |
| var d = []; emailsArr.forEach(function(email){ d.push(email.textContent)}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html ng-app="myApp"> | |
| <head> | |
| <script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.0.3/angular.min.js"></script> | |
| <script type="text/javascript"> | |
| var myApp = angular.module('myApp', [], function ($interpolateProvider) { | |
| $interpolateProvider.startSymbol('[['); | |
| $interpolateProvider.endSymbol(']]'); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function getParameterByName(name) { | |
| var match = RegExp('[?&]' + name + '=([^&]*)').exec(window.location.search); | |
| return match && decodeURIComponent(match[1].replace(/\+/g, ' ')); | |
| } | |
| // Useful for a url like www.iframe.com/93493434?pram_name=2323 |