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
Dropzone.options.mydropzone = { | |
//url: null, | |
//method: "post" | |
parallelUploads: 2, | |
maxFilesize: 0.31, // MB | |
//paramName: "file", // The name that will be used to transfer the file | |
//createImageThumbnails: true, | |
//maxThumbnailFilesize: 10, | |
thumbnailWidth: 100, | |
thumbnailHeight: 100, |
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
// MySQL config file | |
C:\xampp\mysql\bin (my.ini) | |
// | |
bind-address=0.0.0.0 |
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
// Triggering a tab a second time, the map doesn't render properly | |
// This lines solves the rendering problem | |
google.maps.event.addListener(map, 'bounds_changed', function() { | |
google.maps.event.trigger(map, 'resize'); | |
}); | |
// If a map is located in a tab "tab-bane" class | |
// the map UI is messed up, to solve it, add the lines below | |
// map-canvas is the element where you load in the map | |
.map-canvas img{ |
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
<?php | |
// Starting Point | |
/*array(2){ | |
// intersection array 1 | |
array(3) { | |
[2]=> | |
array(5) { | |
["id"]=> | |
string(1) "2" |
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
<?php | |
// Exammple function to output | |
funnction getFeed(){ | |
$data = array(); | |
$json = json_encode($data); | |
// Set the content-type - to avoid mime-type conversions | |
header('content-type: application/json; charset=utf-8'); | |
// Set Origin to allow access by javascript, | |
// if no access-controll-allow-origin header is set | |
// an Error is raised |
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
# Restrict folder access (according to permission settings) | |
# Deny all exept the listed file tpyes | |
<Files ^(*.jpeg|*.jpg|*.png|*.gif)> | |
order deny,allow | |
deny from all | |
</Files> | |
# Allow all all listed files | |
<FilesMatch "\.(ico|pdf|flv|jpg|jpeg|mp3|mpg|mp4|mov|wav|wmv|png|gif|swf|css|js)$"> | |
Allow from All |
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
// install python | |
// so-> sudo add-apt-repository ppa:ondrej/php5 gets regcognized | |
sudo apt-get install python-software-properties | |
// shut down server droplet | |
sudo shutdown -h now | |
// ------------------------------------------ | |
// install newest php and apache version from | |
// ------------------------------------------ |
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
# Copyright (c) 1993-2009 Microsoft Corp. | |
# | |
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows. | |
# | |
# This file contains the mappings of IP addresses to host names. Each | |
# Location: C:\Windows\System32\drivers\etc\hosts | |
# | |
# entry should be kept on an individual line. The IP address should | |
# be placed in the first column followed by the corresponding host name. | |
# The IP address and the host name should be separated by at least one |
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
// Basic Example of using Google Geocoding API | |
var lat; | |
var lng; | |
function getLocationFromAdress(address){ | |
var geoCoder = new google.maps.Geocoder(); | |
var address = "Unterdorfstrasse 2, 3612 Steffisburg" | |
geoCoder.geocode({ 'address': address }, function(results, status){ |