Forum Replies Created

Viewing 5 replies - 1 through 5 (of 5 total)
  • I had the same problem with a client of mine and found this post. Here’s how I worked around it.

    You can create a salient-tribe-events-fix.php file in your plugins directory with this code.

    
    <?php
    
    /*
    Plugin Name: Salient Tribe Events Fix
    Description: Allow month view to show all events
    */
    
    class Salient_Tribe_Events_Fix
    {
        public function __construct()
        {
            add_action('pre_get_posts', array($this, 'pre_get_posts'), 1000, 1);
        }
    
        public function pre_get_posts($query)
        {
            // Salient theme sets a default posts_per_page value of 12 for all search queries
            // This interferes with Tribe Events Calendar Month view
            // See "change_wp_search_size" function in salient/functions.php
            if (function_exists('tribe_is_month') && tribe_is_month()) {
                $query->query_vars['posts_per_page'] = -1;
            }
    
            return $query;
        }
    }
    
    new Salient_Tribe_Events_Fix();
    
    • This reply was modified 1 year ago by Ryan Smith. Reason: add PHP tag
    • This reply was modified 1 year ago by Ryan Smith. Reason: add plugin header
    Thread Starter Ryan Smith

    (@rscs)

    Should just be a matter of adding this to your class:

    protected $_requires_smallest_unit = true;

    • This reply was modified 1 year, 6 months ago by Ryan Smith.
    Thread Starter Ryan Smith

    (@rscs)

    I see you made a change in r2110652 for this by adding a new wp_insert_adwidgets_register_widget() function, but you’re not actually calling it. The action hook is still calling create_function().

    Line 25 should be changed to use the new function:

    add_action('widgets_init', 'wp_insert_adwidgets_register_widget');

    Thread Starter Ryan Smith

    (@rscs)

    Looks good in v1.2.3 now. Thanks!

    Thread Starter Ryan Smith

    (@rscs)

    This
    This is still not fixed. Using the latest update (v1.2.2), I still see 3 high-bit ASCII characters before the opening PHP tag.

    [rscs@xenon add-fields-to-checkout-page-woocommerce]$ hexdump -c checkout-form-editor.php  | head -10
    0000000 357 273 277   <   ?   p   h   p  \r  \n   /   *  \r  \n        
    0000010       P   l   u   g   i   n       N   a   m   e   :       W   o
    0000020   o   C   o   m   m   e   r   c   e       C   h   e   c   k   o
    0000030   u   t       &       A   c   c   o   u   n   t       F   i   e
    0000040   l   d       E   d   i   t   o   r  \r  \n               P   l
    0000050   u   g   i   n       U   R   I   :           h   t   t   p   s
    0000060   :   /   /   w   o   r   d   p   r   e   s   s   .   o   r   g
    0000070   /   p   l   u   g   i   n   s   /   a   d   d   -   f   i   e
    0000080   l   d   s   -   t   o   -   c   h   e   c   k   o   u   t   -
    0000090   p   a   g   e   -   w   o   o   c   o   m   m   e   r   c   e
Viewing 5 replies - 1 through 5 (of 5 total)