WordPress.org

Plugin Directory

Changeset 868885


Ignore:
Timestamp:
03/03/14 23:44:21 (17 months ago)
Author:
joedolson
Message:

Option for permalinks

Location:
my-calendar/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • my-calendar/trunk/my-calendar-core.php

    r868877 r868885  
    16541654    // if available, and not querying remotely, use permalink. 
    16551655    $permalinks = apply_filters( 'mc_use_permalinks', get_option( 'mc_use_permalinks' ) ); 
     1656    $permalinks = ( $permalinks = 1 || $permalinks = true || $permalinks = 'true' ) ? true : false; 
    16561657    $details_link = $event->event_link; 
    16571658    if ( $event->event_post != 0 && get_option( 'mc_remote' ) != 'true' && $permalinks ) { 
  • my-calendar/trunk/my-calendar-settings.php

    r868877 r868885  
    209209        $mc_open_day_uri = ( !empty( $_POST['mc_open_day_uri'] ) ) ? $_POST['mc_open_day_uri'] : ''; 
    210210        update_option('mc_uri',$_POST['mc_uri'] ); 
     211        update_option('mc_use_permalinks', ( !empty( $_POST['mc_use_permalinks'] ) ) ? true : false ); 
    211212        update_option('mc_open_uri',( !empty($_POST['mc_open_uri']) && $_POST['mc_open_uri']=='on' && get_option('mc_uri') != '')?'true':'false'); 
    212213        update_option('mc_mini_uri',$_POST['mc_mini_uri'] ); 
     
    491492    <legend><?php _e('Calendar Link Targets','my-calendar' ); ?></legend> 
    492493    <ul> 
     494    <li><?php mc_settings_field( 'mc_use_permalinks', __( 'Use Pretty Permalinks for Events','my-calendar' ), '', '', array(), 'checkbox-single' ); ?></li>  
    493495    <?php $guess = mc_guess_calendar(); ?> 
    494496    <li><?php mc_settings_field( 'mc_uri', __( 'Where is your main calendar page?','my-calendar' ), '', "<br /><small>".__( 'Can be any Page or Post which includes the <code>[my_calendar]</code> shortcode.','my-calendar' )."$guess</small>", array( 'size'=>'60' ), 'url' ); ?></li> 
Note: See TracChangeset for help on using the changeset viewer.