Plugin Directory

Changeset 160553


Ignore:
Timestamp:
10/04/2009 09:11:02 PM (16 years ago)
Author:
metacortex
Message:
 
Location:
wp-smart-image/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • wp-smart-image/trunk/readme.txt

    r153665 r160553  
    55Requires at least: 2.7
    66Tested up to: 2.8.4
    7 Stable tag: 0.3.2
     7Stable tag: 0.3.3
    88
    99This plugin helps you to set the image layout of your site in a very easy way.
     
    135135== Changelog ==
    136136
     137= 0.3.3 =
     138
     139* Bugfix: Orphan images are shown in widget editor on new posts.
     140
    137141= 0.3.2 =
    138142
  • wp-smart-image/trunk/wp-smart-image.php

    r153665 r160553  
    55Description: This plugin helps you to set the image layout of your site in a very easy way.
    66Author: Darío Ferrer (@metacortex)
    7 Version: 0.3.2
     7Version: 0.3.3
    88Author URI: http://www.darioferrer.com
    99*/
     
    5454function wpsi_options() {
    5555// Convirtiendo en variable todo lo que hemos metido en la base de datos
    56 // converting to variables all thing we've set in the database
     56// Turning to variables all thing we've set on the database
    5757    global $wpsi_configuracion, $_POST;
    5858    if (!empty($_POST)) {
     
    6868        $wpsi_configuracion['custom_compat'] = $_REQUEST['custom-compat'] ? 1 : 0;
    6969        $wpsi_configuracion['wpsi_activar_metabox'] = $_REQUEST['wpsi-activar-metabox'] ? 1 : 0;
     70
    7071        update_option('wpsi_configuracion',$wpsi_configuracion);
     72
    7173        echo '<div id="message" class="updated fade"><p>'.__('Options updated', 'wp-smart-image').'</p></div>';
    7274        echo $texto_error;
     
    579581            'post_parent' => $post->ID,
    580582            'post_type' => 'attachment',
     583            'post_mime_type' => 'image',
    581584            'orderby' => 'menu_order',
    582585            'order' => 'ASC'
     
    584587    echo '<div class="wpsi-fl-contenedor">';
    585588    $lista = '<table class="wpsi-fl-tabla">';
    586     if( !empty( $imagenes ) ) {
     589    if( !empty( $imagenes ) and !empty($post->ID) ) {
    587590        $keys = array_keys($imagenes);
    588591        $num = $keys[0];
     
    593596                $ident = $imagen->ID;
    594597            if ( $wpsi_postmeta ) {
    595                 $foto_lista_checked = $imagen->ID == $wpsi_postmeta ? 'checked="ckecked" ' : '';
     598                $foto_lista_checked = $ident == $wpsi_postmeta ? 'checked="ckecked" ' : '';
    596599                $lista = str_replace( 'id="wpsi-col-'.$wpsi_postmeta.'"' , 'id="wpsi-gris"' , $lista );
    597600            } else {
    598                 $foto_lista_checked = $imagen->ID == $num ? 'checked="ckecked" ' : '';
     601                $foto_lista_checked = $ident == $num ? 'checked="ckecked" ' : '';
    599602            }
    600603            $lista .= '
Note: See TracChangeset for help on using the changeset viewer.