Shineyrock web design & consultancy

Shineyrock

Searched for: "undefined" / 43 results

Getting Started With New Relic in 30 Minutes

…undefined") { if (!NREUMQ.f) { NREUMQ.f=function() { NREUMQ.push(["load",new Date().getTime()]); var e=document.createElement("script"); e.type="text/javascript"; e.src=(("http:"===document.location.protocol)?"http:":"https:") + "//" + "js-agent.newrelic.com/nr-100.js"; document.body.appendChild(e); if(NREUMQ.a)NREUMQ.a(); }; NREUMQ.a=window.onload;window.onload=NREUMQ.f; }; NREUMQ.push(["nrfj","beacon-3.newrelic.com","b9119aa82e","2507356","cglYTRENCF4ERBtZB10KWRYKDABXGQ==",0,21,new Date().getTime(),"","","","",""]);}</script> <p></body> </html> There is a bunch of JavaScript that got inserted into our pages so that New Relic can monitor browser time. This is one way…


Ember.js Testing

…undefined currently. To fix this, we need to open the app.js file and add a computed property to the model that returns a string of the combined first and last name values. App.Person = Ember.Object.extend({ firstName: '', lastName: '', fullName: function() { var firstName = this.get('firstName'); var lastName = this.get('lastName');…


Using .htaccess Files for Pretty URLs

…Undefined Index error because the query string is no longer being sent to the page via the URL, and this is where .htaccess comes into play. To solve this problem, we need to write a regular expression (regex) to match our intended semantic URL, and then pass query variables from…


30 JavaScript Best Practices for Beginners

…undefined rather than removing it. In JavaScript, the best approach to remove an element from an array based on its value is to use the indexOf() function to discover the index number of that value in the array, and then use the splice() function to delete that index value. var…


HTML5 Audio and Video: What You Must Know

…undefined) direction = 1; // or -1 for reverse if (video.playbackRate != undefined) { video.playbackRate = direction == 1 ? 2 : -2; } else { // do it manually video.setAttribute('data-playbackRate’, setInterval ((function playbackRate () { video.currentTime += direction; return playbackRate; // allows us to run the function once and…


Node.js for Beginners

…undefined if errors occurred) and send response codes dependent upon the success or failure of the query. Also note that we have set the Content-Type to x-application/json, which is the valid MIME type for JSON. The rows parameter contains the result of the query, and we simply convert the data…


Build Your First JavaScript Library

…undefined") { return this.forEach(function (el) { el.innerText = text; }); } else { return this.mapOne(function (el) { return el.innerText; }); } } As you might expect, we need to check for a value in text to see if we’re setting or getting. Note that just if (text) wouldn’t work, because…


Getting Started With TypeScript

…* { box-sizing: border-box; } body {margin: 0;}*{box-sizing:border-box;}body{margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;} In late 2012, Microsoft introduced TypeScript, a typed superset for JavaScript that compiles into plain JavaScript. TypeScript is gaining popularity these days because it adds enhanced features to JavaScript and is also used in JavaScript frameworks such as Angular. TypeScript improves the…


Validation and Exception Handling: From the UI to the Backend

…undefined method UserControl::add()But we can fix that, too, in just a couple of seconds.class UserControl { public function add($username) { } }Now we can have a nice test failure telling us the whole story of our code.1) UserControlTest::testEmptyUsernameWillThrowException Failed asserting that exception of type "Exception" is thrown.Finally we can do…


HTML5: Network Information API

…undefined</span>. </li> <li class="old-api hidden"> The connection bandwidth is <span id="b-value" class="value">undefined</span>. </li> <li class="old-api hidden"> The connection is <span id="m-value" class="value">undefined</span>. </li> </ul> <small class="author"> Demo created by <a href="http://www.audero.it">Aurelio De Rosa</a> (<a href="https://twitter.com/AurelioDeRosa">@AurelioDeRosa</a>).<br /> This demo is part of the <a href="https://github.com/AurelioDeRosa/HTML5-API-demos">HTML5 API demos repository</a>. </small> <script> var…


Refine Search

Save This Search?

Saved Searches

You have not saved any searches yet.