WordPress.org

Plugin Directory

Changeset 578868


Ignore:
Timestamp:
07/29/12 22:19:41 (5 years ago)
Author:
webeng
Message:
 
Location:
sliding-youtube-gallery/trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • sliding-youtube-gallery/trunk/css/admin.css

    r573877 r578868  
    106106 
    107107#galleries_table { 
    108     width: 700px; 
     108    width: 900px; 
    109109    border-radius: 10px; 
    110110    font-family: HandelGothicDLight !important; 
     
    165165 
    166166#galleries_table th.action { 
    167     width: 200px; 
     167    width: 400px; 
    168168} 
    169169 
    170170#galleries_table th.type { 
    171     width: 200px; 
     171    width: 50px; 
    172172} 
    173173 
  • sliding-youtube-gallery/trunk/engine/SygConstant.php

    r578559 r578868  
    5050     * Sql query 
    5151     */ 
    52     const SQL_GET_ALL_GALLERIES = 'SELECT id, syg_youtube_src, syg_youtube_videoformat, syg_youtube_maxvideocount, syg_description_show, syg_description_showduration, syg_description_showtags, syg_description_showratings, syg_description_showcategories, syg_style_id, syg_gallery_type FROM %s LIMIT %d, %d'; 
     52    const SQL_GET_ALL_GALLERIES = 'SELECT id, syg_youtube_src, syg_youtube_videoformat, syg_youtube_maxvideocount, syg_description_show, syg_description_showduration, syg_description_showtags, syg_description_showratings, syg_description_showcategories, syg_style_id, syg_gallery_type, syg_gallery_name, syg_gallery_details FROM %s LIMIT %d, %d'; 
    5353    const SQL_GET_ALL_STYLES = 'SELECT id, syg_style_name, syg_style_details, syg_thumbnail_height, syg_thumbnail_width, syg_thumbnail_bordersize, syg_thumbnail_bordercolor, syg_thumbnail_borderradius, syg_thumbnail_distance, syg_thumbnail_overlaysize, syg_thumbnail_image, syg_thumbnail_buttonopacity, syg_description_width, syg_description_fontsize, syg_description_fontcolor, syg_box_width, syg_box_background, syg_box_radius, syg_box_padding FROM %s LIMIT %d, %d'; 
    54     const SQL_GET_GALLERY_BY_ID = 'SELECT id, syg_youtube_src, syg_youtube_videoformat, syg_youtube_maxvideocount, syg_description_show, syg_description_showduration, syg_description_showtags, syg_description_showratings, syg_description_showcategories, syg_style_id, syg_gallery_type FROM %s WHERE id=%d'; 
     54    const SQL_GET_GALLERY_BY_ID = 'SELECT id, syg_youtube_src, syg_youtube_videoformat, syg_youtube_maxvideocount, syg_description_show, syg_description_showduration, syg_description_showtags, syg_description_showratings, syg_description_showcategories, syg_style_id, syg_gallery_type, syg_gallery_name, syg_gallery_details FROM %s WHERE id=%d'; 
    5555    const SQL_GET_STYLE_BY_ID = 'SELECT id, syg_style_name, syg_style_details, syg_thumbnail_height, syg_thumbnail_width, syg_thumbnail_bordersize, syg_thumbnail_bordercolor, syg_thumbnail_borderradius, syg_thumbnail_distance, syg_thumbnail_overlaysize, syg_thumbnail_image, syg_thumbnail_buttonopacity, syg_description_width, syg_description_fontsize, syg_description_fontcolor, syg_box_width, syg_box_background, syg_box_radius, syg_box_padding FROM %s WHERE id=%d'; 
    5656    const SQL_DELETE_GALLERY_BY_ID = 'DELETE FROM %s WHERE id = %d'; 
     
    104104     
    105105    // user message 
    106     const BE_WELCOME_MESSAGE = 'Sliding YouTube Gallery is a nice plugin, that gives you a fast way, to add video galleries in your blog directly from a youtube user\'s channel!'; 
     106    const BE_WELCOME_MESSAGE = 'Here you can manage your Sliding YouTube Galleries. To add a new gallery click on "add new gallery" button.<br/>If you want to edit a previously inserted gallery, please click on "edit" or "delete".<br/> Finally, you could have a preview of your gallery by clicking on "preview" button.'; 
    107107    const BE_MANAGE_GALLERY_MESSAGE = 'Height, width, border radius, border size, distance, padding and font size are treated as generic integer. You don\'t need to add px, em or other css suffix.<br/> Button opacity is a float between 0 and 1 (e.g. 0.5).'; 
    108108    const BE_MANAGE_STYLES_MESSAGE = 'Height, width, border radius, border size, distance, padding and font size are treated as generic integer. You don\'t need to add px, em or other css suffix.<br/> Button opacity is a float between 0 and 1 (e.g. 0.5).'; 
  • sliding-youtube-gallery/trunk/engine/SygGallery.php

    r578559 r578868  
    1414     
    1515    // object attributes 
     16    private $galleryName; 
     17    private $galleryDetails; 
    1618    private $galleryType; 
    1719    private $ytVideoFormat; 
     
    2729     
    2830    // recordset type 
    29     public static $rsType = array('%s','%d','%d','%d','%d','%d','%d','%s','%s','%d','%d'); 
     31    public static $rsType = array('%s','%s','%s','%d','%d','%d','%d','%d','%d','%s','%s','%d','%d'); 
    3032     
    3133    /** 
     
    4850        $result = (object) $result; 
    4951         
     52        $this->setGalleryName($result->syg_gallery_name); 
     53        $this->setGalleryDetails($result->syg_gallery_details); 
    5054        $this->setGalleryType($result->syg_gallery_type); 
    5155         
     
    100104    public function toDto() { 
    101105        $dto = array( 
     106                'syg_gallery_name'                  => $this->getGalleryName(), 
     107                'syg_gallery_details'               => $this->getGalleryDetails(), 
    102108                'syg_gallery_type'                  => $this->getGalleryType(), 
    103109                'syg_description_show'              => $this->getDescShow(), 
     
    301307        $this->id = $id; 
    302308    } 
     309    /** 
     310     * @return the $galleryName 
     311     */ 
     312    public function getGalleryName() { 
     313        return $this->galleryName; 
     314    } 
     315 
     316    /** 
     317     * @param field_type $galleryName 
     318     */ 
     319    public function setGalleryName($galleryName) { 
     320        $this->galleryName = $galleryName; 
     321    } 
     322 
     323    /** 
     324     * @return the $galleryDetails 
     325     */ 
     326    public function getGalleryDetails() { 
     327        return $this->galleryDetails; 
     328    } 
     329 
     330    /** 
     331     * @param field_type $galleryDetails 
     332     */ 
     333    public function setGalleryDetails($galleryDetails) { 
     334        $this->galleryDetails = $galleryDetails; 
     335    } 
    303336} 
    304337?> 
  • sliding-youtube-gallery/trunk/engine/SygPlugin.php

    r578559 r578868  
    815815            $data = serialize($_POST); 
    816816 
    817             // check youtube user 
    818             $valid = $this->sygYouTube 
    819                     ->getUserProfile($_POST['syg_youtube_username']); 
     817            // validate posted values (to implement) 
     818            $valid = true; 
    820819 
    821820            if ($valid) { 
  • sliding-youtube-gallery/trunk/js/admin.js

    r578559 r578868  
    154154                        html = html + '</td>'; 
    155155                        html = html + '<td>'; 
    156                         html = html + val.ytSrc; 
    157                         html = html + '</td>'; 
    158                         html = html + '<td>'; 
    159                         html = html + 'User Channel'; 
    160                         html = html + '</td>'; 
    161                         html = html + '<td>'; 
     156                         
     157                        html = html + '</td>'; 
     158                        html = html + '<td>'; 
     159                        html = html + val.galleryType; 
     160                        html = html + '</td>'; 
     161                        html = html + '<td>'; 
     162                        if (val.galleryType == 'list') { 
     163                            html = html + '<a href="#" onclick="javascript: jQuery.showDetails(\''+ val.id + '\');">Watch the list</a> |'; 
     164                        } else if (val.galleryType == 'feed') { 
     165                            html = html + '<a href="#" onclick="javascript: jQuery.showDetails(\''+ val.id + '\');">(' + val.ytSrc + ') Visit the channel</a> |'; 
     166                        } else { 
     167                            html = html + val.ytSrc; 
     168                        } 
    162169                        html = html + '<a href="../wp-content/plugins/sliding-youtube-gallery/views/preview.php?id=' + val.id + '" class="iframe_' + val.id + '">Preview</a> | <a href="?page=syg-manage-galleries&action=edit&id=' + val.id + '">Edit</a> | <a href="#" onclick="javascript: jQuery.deleteGallery(\''+ val.id + '\');">Delete</a>'; 
    163170                        html = html + '</td>'; 
     
    232239                    // enable and set visible feed 
    233240                    $('#syg_youtube_username_panel').css({opacity: 0.0, visibility: "visible"}).animate({opacity: 1.0}).css('height','auto'); 
    234                     $('#syg_youtube_username').attr('enabled','enabled'); 
     241                    $('#syg_youtube_username').removeAttr('disabled'); 
    235242                     
    236243                    // set list disabled and hidden 
     
    250257                    // enable and set visible list 
    251258                    $('#syg_youtube_list_panel').css({opacity: 0.0, visibility: "visible"}).animate({opacity: 1.0}).css('height','auto'); 
    252                     $('#syg_youtube_list').attr('enabled','enabled'); 
     259                    $('#syg_youtube_list').removeAttr('disabled'); 
    253260                     
    254261                    // set playlist disabled and hidden 
     
    268275                    // set playlist disabled and hidden 
    269276                    $('#syg_youtube_playlist_panel').css({opacity: 0.0, visibility: "visible"}).animate({opacity: 1.0}).css('height','auto'); 
    270                     $('#syg_youtube_playlist').attr('enabled','enabled'); 
     277                    $('#syg_youtube_playlist').removeAttr('disabled'); 
    271278                     
    272279                    break; 
  • sliding-youtube-gallery/trunk/views/adminGallery.php

    r578559 r578868  
    4040    <input type="hidden" name="id" id="id" value="<?php echo $gallery->getId(); ?>"> 
    4141     
     42    <!-- Define your new gallery --> 
     43    <fieldset> 
     44        <legend>Define your new gallery</legend> 
     45         
     46        <!-- style name --> 
     47        <label for="syg_gallery_name"><strong>Name</strong></label> 
     48        <input type="text" id="syg_gallery_name" name="syg_gallery_name" value="<?php //echo $style->getStyleName(); ?>" size="15"/> 
     49         
     50        <!-- style details --> 
     51        <label for="syg_gallery_details"><strong>Details</strong></label> 
     52        <input type="text" id="syg_gallery_details" name="syg_gallery_details" value="<?php //echo $style->getStyleDetails(); ?>" size="50"/> 
     53    </fieldset> 
     54     
    4255    <!-- youtube settings --> 
    4356    <fieldset> 
     
    5265        <div id="syg_youtube_username_panel"> 
    5366            <label for="syg_youtube_src">YouTube User: </label><br/> 
    54             <input type="text" id="syg_youtube_username" name="syg_youtube_src" value="<?php echo $gallery->getYtSrc(); ?>" size="30"> 
     67            <input type="text" id="syg_youtube_username" name="syg_youtube_src" value="<?php if ($gallery->getGalleryType() == 'feed') echo $gallery->getYtSrc(); ?>" size="30"> 
    5568        </div> 
    5669         
     
    5871        <div id="syg_youtube_list_panel"> 
    5972            <label for="syg_youtube_src">Video list: </label><br/> 
    60             <textarea rows="5" cols="70" id="syg_youtube_videolist" name="syg_youtube_src" value="<?php echo $gallery->getYtSrc(); ?>"></textarea> 
     73            <textarea rows="5" cols="70" id="syg_youtube_videolist" name="syg_youtube_src"><?php if ($gallery->getGalleryType() == 'list') echo $gallery->getYtSrc(); ?></textarea> 
    6174        </div> 
    6275 
     
    6477        <div id="syg_youtube_playlist_panel"> 
    6578            <label for="syg_youtube_src">YouTube playlist: </label><br/> 
    66             <input type="text" id="syg_youtube_playlist" name="syg_youtube_src" value="<?php echo $gallery->getYtSrc(); ?>" size="30"> 
     79            <input type="text" id="syg_youtube_playlist" name="syg_youtube_src" value="<?php if ($gallery->getGalleryType() == 'playlist') echo $gallery->getYtSrc(); ?>" size="30"> 
    6780        </div> 
    6881         
  • sliding-youtube-gallery/trunk/views/adminStyle.php

    r573300 r578868  
    3939    <input type="hidden" name="id" id="id" value="<?php echo $style->getId(); ?>"> 
    4040 
    41     <!-- thumbnail appereance --> 
     41    <!-- Define your new style --> 
    4242    <fieldset> 
    4343        <legend>Define your new style</legend> 
Note: See TracChangeset for help on using the changeset viewer.