of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
*/
include_once "glob_inc.inc.php";
if (!isset($_GET['confirm_id'])) {
    $confirm = array();
} else {
    $confirm = getConfirm($_GET['confirm_id']);
}
if (!count($confirm)) {
    print_header($day, $month, $year, $area);
    echo '<h1>' . _('Confirmation') . '</h1>' . chr(10);
    echo _('Can not find confirmation from the confirmation ID you gave.');
    exit;
}
$entry = getEntry($confirm['entry_id']);
if (!count($entry)) {
    print_header($day, $month, $year, $area);
    echo '<h1>' . _('Confirmation') . '</h1>' . chr(10);
    echo _('Error.');
    exit;
}
$user = getUser($confirm['user_id']);
Example #2
0
    } else {
        //Some empty fields
        missingData();
    }
    //Validate huurderID that was fetched
    if ($hid === -1) {
        errorDatabase();
    }
    //Then create the Reservering
    $rid = getReservering($area, $startSTR, $endSTR, $aantalPers);
    if ($rid === -1) {
        errorDatabase();
    }
    //Then create the link between de verhuurder and the reservering (the actual verhuring)
    createVerhuring($hid, $rid, $groep);
    $hashEmail = getConfirm($hid, $rid);
    if ($hashEmail === "error") {
        errorDatabase();
    }
    //Then send confirmation email to verhuurder with confirm string
    sendConfirmEmail($mail, $contact, $hashEmail, $naam, $startSTR, $endSTR, $aantalPers);
    //Indicate succes
    if (!$alreadyReserved) {
        succesfullReservation();
    } else {
        succesfullReservationAlreadyReserved();
    }
} else {
    //one of the fields was not set in the POST request
    missingData();
}