Skip to content

Instantly share code, notes, and snippets.

<?
require_once 'db.php';
$target_dir = '../uploads/';
$tempName = explode('.', $_FILES['document']['name']);
$fileName = round(microtime(true)) . '.' . end($tempName);
$uploadFile = $target_dir . $fileName;
"build:android-windows": "ionic cordova build android --release && jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore vtech.keystore platforms/android/app/build/outputs/apk/release/app-release-unsigned.apk vtechtest && C:/Users/sasha/AppData/Local/Android/sdk/build-tools/28.0.3/zipalign -v 4 platforms/android/app/build/outputs/apk/release/app-release-unsigned.apk univuz-release.apk"
@Sqweez
Sqweez / index.js
Created February 13, 2019 09:33
Filling Date FROM month to month
let fill_months = () => {
let options = "<option value='0'>Все</option>";
let months = ['Январь', 'Февраль', 'Март', 'Апрель', 'Май', 'Июнь', 'Июль', 'Август', 'Сентябрь', 'Октябрь', 'Ноябрь', 'Декабрь'];
let currentDate = new Date();
let start_month = 0, start_year = 2018, current_month = currentDate.getMonth(),
current_year = currentDate.getFullYear();
for (let i = 0; i <= current_year - start_year; i++) {
if (i == (current_year - start_year)) {
for (let y = 0; y <= current_month; y++) {
options += `<option value='${start_year+i}-${current_month+1}-00'>${months[y]}, ${start_year+i} год</option>`;
$data1 = array();
if ($handle = opendir('../../upload')) {
while (false !== ($entry = readdir($handle))) {
if ($entry != "." && $entry != "..") {
array_push($data1, $entry);
}
}
closedir($handle);
}
include('../SimpleImage.php');