NodeJS: Server Instantiation

var http = require("http");

var server = http.createServer(function(request, response) {
    response.writeHead(200, {"Content-Type": "text/html"});
    
    response.end('Hello You');
}).listen(8888);

 

Tags

Eclipse: Mars: Startup Script for Setting Java, NodeJS and Starting Eclipse

@echo off
set DEV_HOME=C:\d\dev
set JAVA_HOME=%DEV_HOME%\java\jdk1.8.0_71
set PATH=%PATH%;%JAVA_HOME%\bin;C:\d\DEV\tools\nodejs

set command_java=%JAVA_HOME%\bin\javaw.exe
set command_eclipse=%DEV_HOME%\tools\eclipse-mars\eclipse.exe

start %command_eclipse% -vm %command_java% -showlocation -vmargs -server -Xms512m -Xmx1024m -XX:MaxPermSize=128m

cd %DEV_HOME%

call cmd

DOS: Timestamp Script

Here's a script that gets current time/date and appends to a user-provided filename This example uses the generated filename to call 7-zip and create a zip archive
Tags

XAMPP Portabilization

Simplify XAMPP config files by assigning variables at the top of the scripts. Some scripts have multiple references, so using these variables will allow for easy duplication or moving of the xampp application folder.
Tags

D8: Video Embed HTML Snippet

Code

<div class="field__item">
<div class="video-embed-field-responsive-video">
<iframe allowfullscreen="allowfullscreen" frameborder="0" height="480" src="https://www.youtube.com/embed/8TjL98FCf5w?autoplay=0&amp;start=0&amp;rel=0" width="854">
</iframe>
</div>
</div>

 

Video Output

 

Tags
Subscribe to