uawdijnntqw1x1x1
IP : 216.73.216.39
Hostname : diefsweb003.fsit.ch
Kernel : Linux diefsweb003.fsit.ch 4.18.0-553.121.1.lve.el8.x86_64 #1 SMP Thu Apr 30 16:40:41 UTC 2026 x86_64
Disable Function : None :)
OS : Linux
PATH:
/
home
/
wirbesti
/
nousdecidons.ch
/
..
/
public_html
/
php
/
testmetadataupdate.php
/
/
<?php try { require_once 'setting.config.php'; require_once 'DBConnection.php'; require_once 'Metadata.php'; $database = new DBConnection($config); $metadata = new Metadata($database); $param = [ 'id' => 9999, 'campaigninfoid' => 9998, 'slogande' => 'Wir testen für unsere Freiheit', 'sloganfr' => 'Nous testons notre liberté', 'sloganit' => 'Testiamo la nostra libertà', 'imagepathde' => '', 'imagepathfr' => '', 'imagepathit' => '', 'campaignstatus' => 1, 'shortdescriptionde' => '', 'shortdescriptionfr' => '', 'shortdescriptionit' => '', 'precheckdate' => '2022-03-31 00:00:00', 'collectionstartdate' => '2022-04-01 00:00:00', 'collectionexpirydate' => '2023-10-01 00:00:00', 'submitteddate' => null, 'linktobundesblatt' => 'www.microsoft.com', 'bundesblatttitle' => 'Microsoft', 'linktosignatureform' => '', 'linktodetailpage' => '', 'campaigntype' => 'Volksinitiative', 'signatureformpathpdfde' => '', 'signatureformpathpdffr' => '', 'signatureformpathpdfit' => '', 'signatureformpathjpgde' => '', 'signatureformpathjpgfr' => '', 'signatureformpathjpgit' => '', ]; $result = $metadata->insert($param); echo 'result = '.$result.'<br/>'; $param['campaigninfoid'] = 9997; $result = $metadata->update($param); if ($result) echo 'success (campaigninfoid)<br/>'; $checkresult = $metadata->getMetadataByCampaignid(9999); if ($checkresult['campaigninfoid'] == 9997) echo 'success (campaigninfoid 2)<br/>'; $param['slogande'] = 'Ein Männlein steht im Walde'; $result = $metadata->update($param); if ($result) echo 'success (slogande)<br/>'; $checkresult = $metadata->getMetadataByCampaignid(9999); if ($checkresult['slogan-de'] == 'Ein Männlein steht im Walde') echo 'success (slogande 2)<br/>'; $param['precheckdate'] = '2022-04-07 00:00:00'; $result = $metadata->update($param); if ($result) echo 'success (precheckdate)<br/>'; $checkresult = $metadata->getMetadataByCampaignid(9999); if ($checkresult['pre-check-date'] == '2022-04-07 00:00:00') echo 'success (precheckdate 2)<br/>'; $param['shortdescriptionde'] = 'ÄÖÜËäöüéè'; $result = $metadata->update($param); if ($result) echo 'success (shortdescriptionde)<br/>'; $checkresult = $metadata->getMetadataByCampaignid(9999); if ($checkresult['shortdescription-de'] == 'ÄÖÜËäöüéè') echo 'success (shortdescriptionde 2)<br/>'; } catch (Exception $ex) { echo 'error '.$ex->getMessage().'<br/>'; } ?>
/home/wirbesti/nousdecidons.ch/../public_html/php/testmetadataupdate.php