Skip to content

Instantly share code, notes, and snippets.

View unoframille's full-sized avatar

Francesco Mosca unoframille

View GitHub Profile
function checkAvailability() {
var dataLezione = $("#dateTime").val();
var start = $('#oraInizio').val();
var end = $("#oraFine").val();
$.post("ajax/stanze/availability.php", {
'start': dataLezione + ' ' + start,
'end': dataLezione + ' ' + end
}).done(function(json) {
var result = jQuery.parseJSON(json);
$requete = $database->select(
'embassy_calendario',
[
"embassy_calendario.id_stanza",
"embassy_calendario.id_insegnante"
],
" WHERE
(start >= '".date("Y-m-d H:i:s", strtotime($_POST['start']))."' AND start < '".date("Y-m-d H:i:s", strtotime($_POST['end']))."') OR
(end > '".date("Y-m-d H:i:s", strtotime($_POST['start']))."' AND end <= '".date("Y-m-d H:i:s", strtotime($_POST['end']))."') OR
(start >= '".date("Y-m-d H:i:s", strtotime($_POST['start']))."' AND end <= '".date("Y-m-d H:i:s", strtotime($_POST['end']))."') OR
@unoframille
unoframille / storefront-remove-sidebar.php
Last active February 16, 2017 10:18
Elimina la barra laterale dal tema StoreFront di WooCommerce
<?php
/**
* Plugin Name: StoreFront Remove Sidebar
* Plugin URI: https://francescomosca.info
* Description: Leva la sidebar dalle pagine WooCommerce dal template StoreFront
* Version: 1.0.0
* Author: fruitfulwp
* Author URI: https://francescomosca.info
* License: GPL-2.0+