#easy-pie-cs-builtin-background-slider { width: 610px}
    #easy-pie-cs-builtin-background-slider img { height:100px; width:100px; margin-right:10px; margin-top:7px;}
</style>

<!--<script type="text/javascript" src="<?php 
echo EZP_CS_Utility::$PLUGIN_URL . '/jquery-plugins/simple-modal/jquery.simplemodal.1.4.4.min.js?' . EZP_CS_Constants::PLUGIN_VERSION;
?>
"></script>-->

<?php 
$action_updated = null;
$global = EZP_CS_Global_Entity::get_instance();
$set_index = $global->active_set_index;
$set = EZP_CS_Set_Entity::get_by_id($set_index);
$display = EZP_CS_Display_Entity::get_by_id($set->display_index);
$config = EZP_CS_Config_Entity::get_by_id($global->config_index);
$error_string = "";
if (isset($_POST['action']) && $_POST['action'] == 'save') {
    check_admin_referer('easy-pie-coming-soon-save-display');
    EZP_CS_Utility::debug('past admin check');
    // Artificially set the bools since they aren't part of the postback
    $display->background_tiling_enabled = "false";
    $error_string = $display->set_post_variables($_POST);
    if ($error_string == "") {
        $action_updated = $display->save();
    }
}
?>

<?php 
Ejemplo n.º 2
0
 function ws_copy_template()
 {
     $post = stripslashes_deep($_POST);
     if (isset($post['template_key'])) {
         $template_key = $post['template_key'];
         $global = EZP_CS_Global_Entity::get_instance();
         $set_index = $global->active_set_index;
         $set = EZP_CS_Set_Entity::get_by_id($set_index);
         $display = EZP_CS_Display_Entity::get_by_id($set->display_index);
         // RSR TODO: Have to be careful here - ensure that a single error won't hose up the state of the system - TODO: Maybe a reset to defaults option to clean out db?
         $display->delete();
         $new_display = EZP_CS_Display_Entity::create_from_template($template_key);
         $new_display->save();
         $set->display_index = $new_display->id;
         $set->save();
     }
 }