本文整理匯總了PHP中graphics::mark_dirty方法的典型用法代碼示例。如果您正苦於以下問題:PHP graphics::mark_dirty方法的具體用法?PHP graphics::mark_dirty怎麽用?PHP graphics::mark_dirty使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類graphics
的用法示例。
在下文中一共展示了graphics::mark_dirty方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: remove_rules
/**
* Remove all rules for this module
* @param string $module_name
*/
static function remove_rules($module_name)
{
$status = db::build()->delete("graphics_rules")->where("module_name", "=", $module_name)->execute();
if (count($status)) {
graphics::mark_dirty(true, true);
}
}
示例2: save
public function save()
{
access::verify_csrf();
$form = $this->_get_admin_form();
if ($form->validate()) {
module::set_var("gallery", "movie_allow_uploads", $form->settings->allow_uploads->value);
if ($form->settings->rebuild_thumbs->value) {
graphics::mark_dirty(true, false, "movie");
}
// All done - redirect with message.
message::success(t("Movies settings updated successfully"));
url::redirect("admin/movies");
}
// Something went wrong - print view from existing form.
$this->_print_view($form);
}
示例3: mark_dirty
/**
* Mark all PDF thumbs as dirty
* (ref: graphics::mark_dirty())
*/
static function mark_dirty()
{
graphics::mark_dirty(true, false, "movie", "application/pdf");
}
示例4: uninstall
public function uninstall()
{
$items = ORM::factory('item')->find_all();
foreach ($items as $item) {
$path = $item->file_path() . $name;
$orig = str_replace(VARPATH . 'albums/', VARPATH . 'originals/', $path);
if (file_exists($orig)) {
@unlink($path);
@rename($orig, $path);
}
}
graphics::mark_dirty(1, 1);
Database::instance()->query('DROP TABLE {emboss_overlays}');
Database::instance()->query('DROP TABLE {emboss_mappings}');
Database::instancs()->query("delete from {modules} where name='emboss'");
log::info('emboss', 'module uninstalled (database dropped/overlays removed)');
}
示例5: dirty
static function dirty($target)
{
graphics::mark_dirty($target == "thumb", $target == "resize");
}