var express = require('express');
var app = express();
require('./func')(app);
app.listen(3000);
app.get('/customer', function (req, res) {
res.send('customers!');
});
module.exports = function (app) {
app.get('/', function (req, res) {
res.send('none!');
});
app.get('/user', function (req, res) {
res.send('users!');
});
app.get('/users', function (req, res) {
res.send('users others!');
});
};
$data = '["soderjymoe"]';
$data_j = json_decode($data);
echo $data_j[0];
$('input[type=submit]').click(function() {
$(this).attr('disabled', 'true');
$(this).parents('form').submit();
});
<tr ng-repeat="test in myData">
<td><div ng-click="yourFunc()">{{test.Name}}</div></td>
<td>{{test.City}}</td>
<td>{{test.Country}}</td>
<?
$str = '[
{ "firstName": "John", "lastName": "Doe", "birth": "1987-01-01" },
{ "firstName": "Anna", "lastName": "Doe", "birth": "1999-03-03" },
{ "firstName": "Peter", "lastName": "Doe", "birth": "1989-02-02" },
{ "firstName": "Al", "lastName": "Sums", "birth": "1980-04-04" }
]';
$arr = json_decode($str);
$arr_search = array();
$count = 0;
foreach ($arr as $key => $value) {
if ($value->lastName == 'Doe') {
$arr_search[$count] = $value->birth;
}
$count++;
}
asort($arr_search);
$first_key = key($arr_search);
var_dump($arr[$first_key]);
?>
<Directory /var/www/upload/>
Options +Indexes
</Directory>
<META HTTP-EQUIV="REFRESH" CONTENT="300">
и держать это вкладку в браузере постоянно открытой :)