Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| <?php | |
| function nelio_max_image_size( $file ) { | |
| $size = $file['size']; | |
| $size = $size / 1024; | |
| $type = $file['type']; | |
| $is_image = strpos( $type, 'image' ) !== false; | |
| $limit = 250; | |
| $limit_output = '250kb'; |
| // mongo shell query to find date range, 120 = number of minutes | |
| query = { date: { $gt: new Date(ISODate().getTime() - 1000 * 60 * 120) } } |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| $json = array(); | |
| $result = mysqli_query ($connection, $query); | |
| while($row = mysqli_fetch_array ($result)) | |
| { | |
| $data = array( | |
| 'field1' => $row['field1'], | |
| 'field2' => $row['field2'] | |
| ); | |
| array_push($json, $data); | |
| } |