Plugin Directory

Changeset 1588183


Ignore:
Timestamp:
02/03/2017 01:01:14 PM (9 years ago)
Author:
wpklangoo
Message:

Bug fixes

Location:
magnet/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • magnet/trunk/README.txt

    r1572498 r1588183  
    4646
    4747== Changelog ==
     48= 1.0.10 =
     49* Bug fixes.
    4850= 1.0.9 =
    4951* Minor update to help clients integrate easily with the Magnet services.
  • magnet/trunk/WP-klangoo.php

    r1572498 r1588183  
    55Plugin URI: http://magnet.klangoo.com/wp-plugin
    66Description: This plugin allows Klangoo clients to integrate our services inside their WordPress sites with ease.
    7 Version: 1.0.9
     7Version: 1.0.10
    88Author: Klangoo
    99Author URI: http://klangoo.com
     
    5858            <?php
    5959            if ( has_post_thumbnail() ) {
    60                 $image = wp_get_attachment_image_src( get_post_thumbnail_id(), 'thumbnail-size', true );
     60                $image = wp_get_attachment_image_src( get_post_thumbnail_id(), 'medium', true );
    6161                ?>
    6262                <meta itemprop="thumbnailUrl" content="<?php echo esc_url( $image[ 0 ] ); ?>"/>
     
    262262    add_rewrite_rule(
    263263        '^entities/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$',
    264         'index.php?pagename=entities&entid=$matches[1]&entname=$matches[2]&lang=$matches[3]&page=$matches[4]',
     264        'index.php?pagename=entities&entid=$matches[1]&entname=$matches[2]&lang=$matches[3]&paged=$matches[4]',
     265        'top'
     266    );
     267   
     268        add_rewrite_rule(
     269        '^entities/([^/]+)/([^/]+)/([^/]+)/?$',
     270        'index.php?pagename=entities&entid=$matches[1]&entname=$matches[2]&lang=$matches[3]',
    265271        'top'
    266272    );
     
    270276/* Runs on plugin deactivation*/
    271277register_deactivation_hook( __FILE__, 'magnet_remove' );
    272 register_activation_hook( __FILE__, 'magnet_rewrite_add_rewrites' );
     278//register_activation_hook( __FILE__, 'magnet_rewrite_add_rewrites' );
    273279
    274280add_action( 'wp_head', 'magnet_head' );
  • magnet/trunk/class-fake-page.php

    r1534359 r1588183  
    164164            $post = $this -> createPost( $this -> rel_entity_slug, $this -> rel_entity_title, -800 );
    165165            $posts[] = $post;
    166             /**
    167              * Trick wp_query into thinking this is a page (necessary for wp_title() at least)
    168              * Not sure if it's cheating or not to modify global variables in a filter
    169              * but it appears to work and the codex doesn't directly say not to.
    170              */
     166
    171167            $wp_query->queried_object = $post;
    172168            $wp_query -> is_page = true;
     
    184180            $post = $this -> createPost( $this -> rel_entity_slug_new, $this -> rel_entity_title, -700 );
    185181            $posts[] = $post;
    186             /**
    187              * Trick wp_query into thinking this is a page (necessary for wp_title() at least)
    188              * Not sure if it's cheating or not to modify global variables in a filter
    189              * but it appears to work and the codex doesn't directly say not to.
    190              */
     182 
    191183            $wp_query->queried_object = $post;
    192184            $wp_query -> is_page = true;
Note: See TracChangeset for help on using the changeset viewer.