Let's say you want to host domains first.com
and second.com
.
Create folders for their files:
Digital Ocean recently released private networking support in their NYC2 Data center.
They also published a blog post on how to setup a new droplet with private networking. But one thing the post doesn't do is tell you how to scale your private network for many boxes. One approach is obviously to edit /etc/hosts (but this gets annoying when you add a new box). A better way is to create an internal DNS zone (via the digital ocean web interface) and have your droplets use it:
<?php | |
class User { | |
private $firstname; | |
private $lastname; | |
public function __construct($f, $l) { | |
$this->firstname = $f; | |
$this->lastname = $l; | |
} |
All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.
Generally, all APIs that synchronously provide layout metrics will trigger forced reflow / layout. Read on for additional cases and details.
elem.offsetLeft
, elem.offsetTop
, elem.offsetWidth
, elem.offsetHeight
, elem.offsetParent
#Unix Toolbox
##Unix Toolbox revision 14.4
Model:: | |
/*Select*/ | |
select('col1','col2') | |
->select(array('col1','col2')) | |
->select(DB::raw('businesses.*, COUNT(reviews.id) as no_of_ratings, IFNULL(sum(reviews.score),0) as rating')) | |
->addSelect('col3','col4') | |
->distinct() // distinct select | |
/*From*/ |
###Install Node and Bower
curl -sL https://deb.nodesource.com/setup_0.12 | sudo bash -
sudo apt-get install nodejs
sudo npm install -g bower
git clone https://github.com/benweet/stackedit
/public/res/constants.js
:constants.BASE_URL = "http://stackedit.dev:3000/";
<input type="file" name="file" id="file"> | |
<input type="submit" id="submit" name="Upload" onclick="upload();return false;"> | |
<script type="text/javascript"> | |
function upload(){ | |
var formData = new FormData(); | |
formData.append("action", "upload-attachment"); | |
var fileInputElement = document.getElementById("file"); | |
formData.append("async-upload", fileInputElement.files[0]); |