Skip to content

Instantly share code, notes, and snippets.

@der-On
Last active August 22, 2016 08:34
Show Gist options
  • Save der-On/eabd62b85737ebf8a55bd20330e42304 to your computer and use it in GitHub Desktop.
Save der-On/eabd62b85737ebf8a55bd20330e42304 to your computer and use it in GitHub Desktop.
Syncs all files for contao metamodels openimmo
<?php
// initialize the contao framework
define('TL_MODE', 'FE');
require('../system/initialize.php');
$cron = new \MetaModelsOpenImmo\Cron();
$cron->run();
<?php
// initialize the contao framework
define('TL_MODE', 'FE');
require('../system/initialize.php');
$api = new \MetaModelsOpenImmo\Api();
$objects = $api->loadAllMetaModelObjects();
foreach($objects as $object) {
$api->syncAllFilesFor($object, 'script');
}
<?php
// initialize the contao framework
define('TL_MODE', 'FE');
require('../system/initialize.php');
$api = new \MetaModelsOpenImmo\Api();
$cron = new \MetaModelsOpenImmo\Cron();
$objects = $api->loadAllMetaModelObjects();
foreach($objects as $object) {
$cron->sync($object);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment