Plugin Directory

Changeset 653469


Ignore:
Timestamp:
01/16/2013 08:58:35 AM (13 years ago)
Author:
JonathanMH_com
Message:

added override option for lazy load

Location:
privacy-friendly-facebook/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • privacy-friendly-facebook/trunk/index.php

    r652469 r653469  
    5252            , 'show_stream'         => $instance['show_stream']
    5353            , 'show_header'         => $instance['show_header']
    54             , 'disable_priv'        => 'false'
     54            , 'disable_priv'        => $instance['disable_priv']
    5555        );
    5656       
     
    6666        $instance = $old_instance;
    6767        $instance['title'] = strip_tags($new_instance['title']);
     68        if (strip_tags($new_instance['disable_priv']) != 'true'){
     69            $instance['disable_priv'] = 'false';
     70        }
     71        else {
     72            $instance['disable_priv'] = 'true';
     73        }
    6874        $instance['page_url'] = strip_tags($new_instance['page_url']);
    6975        $instance['placeholder'] = $new_instance['placeholder'];
     
    97103        $default =  array(
    98104              'title'               => 'Privacy Friendly FB Widget'
     105            , 'disable_priv'        => 'false'
    99106            , 'page_url'            => 'https://www.facebook.com/pages/JonathanMH/159526834122370'
    100107            , 'type'                => 'like-box'
  • privacy-friendly-facebook/trunk/readme.txt

    r652491 r653469  
    55Requires at least: 2.8
    66Tested up to: 3.5
    7 Stable tag: 0.1
     7Stable tag: 0.11
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    3232* enable/disable: facepile, stream of posts
    3333* define colours
     34* disable click to load
    3435
    3536I plan to increase the functionality with:
     
    6970== Changelog ==
    7071
     72= 0.11 =
     732013-1-16
     74
     75added option to override lazy load
     76
    7177= 0.1 =
    72782013-1-14
  • privacy-friendly-facebook/trunk/templates/form.php

    r652469 r653469  
    1717    .esc_attr( $instance['title'] )
    1818    .'" /></p>';
     19
     20/* DISABLE PRIV */
     21$field_disable_priv_id = $this->get_field_id('disable_priv');
     22$field_disable_priv = $this->get_field_name('disable_priv');
     23
     24if ($instance['disable_priv'] == 'true'){
     25    $checked = 'checked="checked"';
     26}
     27else {
     28    $checked = '';
     29}
     30
     31echo "\r\n"
     32    .'<p><input type="checkbox" id="'
     33    .$field_disable_priv_id
     34    .'" name="'
     35    .$field_disable_priv
     36    .'" value="true"'
     37    .$checked
     38    .'/> <label for="'
     39    .$field_disable_priv_id
     40    .'">'
     41    .__('Disable Privacy Protection and load directly')
     42    .' </label></p>';
    1943
    2044
Note: See TracChangeset for help on using the changeset viewer.