YaWK  24.1
Yet another WebKit
tourdates-copy.php
Go to the documentation of this file.
1 <?php
2 // check if language is set
3 if (!isset($language) || (!isset($lang)))
4 { // inject (add) language tags to core $lang array
5  $lang = \YAWK\language::inject(@$lang, "../system/plugins/tourdates/language/");
6 }
7 
8 include '../system/plugins/tourdates/classes/tourdates.php';
9 if (!isset($tourdates))
10 { // create new obj
12  if (isset($_GET['id']))
13  { // escape var
14  $id = $db->quote($_GET['id']);
15  $tourdates->loadProperties($db, $id);
16  }
17 }
18 if ($_GET['copy'] === "true")
19 { // copy entry
20  if ($tourdates->copy($db, $tourdates->id))
21  { // success
22  print \YAWK\alert::draw("success", "Success!", "The event " . $_GET['id'] . " was copied !","plugin=tourdates","2600");
23  }
24  else
25  { // error
26  print \YAWK\alert::draw("danger", "Error!", "The event " . $_GET['id'] . " could not be copied!","plugin=tourdates","4800");
27  }
28 }
print $lang['FILEMAN_UPLOAD']
$tourdates
Definition: tourdates.php:80
Tour Dates Plugin hands you a simple but nice, clean bootstraped & sortable Data Table....
Definition: tourdates.php:22
static inject(array $lang, string $pathToFile)
allow plugins to inject language tags to $lang array
Definition: language.php:439
if(!isset($db)) $id
print $_GET['id']
Definition: page-edit.php:357