This file contains 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
#!/usr/bin/env node | |
const path = require('path'); | |
const cors = require('cors'); | |
const express = require('express'); | |
const bodyParser = require('body-parser'); | |
const app1 = express(); |
This file contains 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
diff --git a/gunicorn/workers/async.py b/gunicorn/workers/async.py | |
index 4cfa7a8..00bedc7 100644 | |
--- a/gunicorn/workers/async.py | |
+++ b/gunicorn/workers/async.py | |
@@ -30,6 +30,7 @@ class AsyncWorker(base.Worker): | |
def handle(self, listener, client, addr): | |
req = None | |
try: | |
+ client.settimeout(self.cfg.timeout) | |
parser = http.RequestParser(self.cfg, client) |
This file contains 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 setUpdatedLatLng(&$values, $pSettings, $oldvalues = false) { | |
if($oldvalues) { //get Edit page's fields | |
$formFields = $pSettings->getEditFields(); | |
} else { //get Add page's fields | |
$formFields = $pSettings->getAddFields(); | |
} | |
foreach($formFields as $field) { | |
//check if 'UpdateLatLng' is ticked for a field | |
if(!$pSettings->isUpdateLatLng($field)) { |
This file contains 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 setUpdatedLatLng(&$values, $pSettings, $oldvalues = false) { | |
if($oldvalues) { //get Edit page's fields | |
$formFields = $pSettings->getEditFields(); | |
} else { //get Add page's fields | |
$formFields = $pSettings->getAddFields(); | |
} | |
foreach($formFields as $field) { | |
//check if 'UpdateLatLng' is ticked for a field | |
if(!$pSettings->isUpdateLatLng($field)) { |
This file contains 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 src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script> | |
<style> | |
.progress { | |
width: 300px; | |
height: 50px; | |
background: green; | |
} | |
.bar { | |
height: 100%; |
This file contains 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 make_geocode_handler(address) { | |
var retry_count = 0, | |
retry_timeout = 5000; | |
function geocode_handler(geoResult, status) { | |
if (status == google.maps.GeocoderStatus.OK) { | |
positions[keys[i]] = {'lat' : geoResult[0].geometry.location.lat(), 'lng' : geoResult[0].geometry.location.lng()}; | |
d.resolve(); | |
} else { | |
if (++retry_count < 5) { | |
setTimeout(function() { |
This file contains 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
require.paths.unshift(__dirname + '/express/support'); | |
var express = require('express'), | |
app = express.createServer(); | |
app.use(express.logger()); | |
app.get('/', function(req, res){ | |
res.render('index.ejs'); | |
}); |
This file contains 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/1.1 206 Partial Content | |
X-Powered-By: Express | |
Content-Range: bytes 0-2563245/2563246 | |
Content-Type: application/octet-stream | |
Accept-Ranges: bytes | |
Connection: close |