Forum Replies Created

Viewing 10 replies - 1 through 10 (of 10 total)
  • Just to add this only happens on native post type (post) but all other custom post types are unaffected.

    Each one is registered as so:

    add_action('init', 'register_my_cpt_organisation');
    function register_my_cpt_organisation() {
    register_post_type('organisation_profiles', array(
    'label' => 'Organisation Profiles',
    'description' => '',
    'public' => true,
    'show_ui' => true,
    'menu_position' => 15,
    'show_in_menu' => true,
    'capability_type' => 'post',
    'map_meta_cap' => true,
    'hierarchical' => false,
    'rewrite' => array('slug' => 'organisation-profiles', 'with_front' => true),
    'query_var' => true,
    'supports' => array('title','editor','excerpt','trackbacks','custom-fields','comments','revisions','thumbnail','author','page-attributes'),
    // 'taxonomies' => array('profiles_and_insight'),
    'labels' => array (
      'name' => 'Organisation Profiles',
      'singular_name' => 'Team Memeber',
      'menu_name' => 'Team',
      'add_new' => 'Add a Team Memeber',
      'add_new_item' => 'Add New Team Memeber',
      'edit' => 'Edit',
      'edit_item' => 'Edit Team Memeber',
      'new_item' => 'New Team Memeber',
      'view' => 'View Team Memeber',
      'view_item' => 'View Team Memeber',
      'search_items' => 'Search Team Memebers',
      'not_found' => 'No Team Memeber Found',
      'not_found_in_trash' => 'No Team Memeber Found in Trash',
      'parent' => 'Team',
    )
    ) ); }

    Yeah I having the same error too, upon wanting to publish a post. It still saves it, but goes to a blank white screen with errors. Thanks FPCSJames for offering a temporary fix.

    Thread Starter lxm7

    (@lxm7)

    Thanks Petervanderdoes, works great now, much appreciated!

    Thread Starter lxm7

    (@lxm7)

    Thanks for the responses, I’ve tried both methods, the first from Peter returns the same issue, it limits to the first 3 of all category list. So the code above for foodbank should have 3 events,it only lists 2, as it will only search the top 3 listed events of any/all categories. (this is whati think is happening as some other category outputs only display 1 or none, as their relavant cat is selected further down the list of the top 3!) For Clarity: I replace ‘your format’ with the code i had initially with the code suggested from peter.

    The second method from Angelo displays all the events and then loops through the first 3 events of any category similar to before, even after taking out the while loop. (Note, all this code im editing resides in a file in the inc folder which page.php calls and displays if is page is the relevant one AFTER the default loop used for more basic pages in the site.) I pasted the first block with its filter and edited the code like so:

    $event_category=get_term_by('name','ChristChurchKids', EM_TAXONOMY_CATEGORY);
    		$arg = array(
    				'category' => $event_category->ID,
    				'order'=>'ASC ',
    				'limit' => 3,
    				'format' => '#_CATEGORYNEXTEVENTS',
    		);
    		echo EM_Events::output($arg);

    Any other suggestions?! Thanks again.

    Thread Starter lxm7

    (@lxm7)

    Aaaah shit!. Sorry. Thanks for your reply buddy.

    Thread Starter lxm7

    (@lxm7)

    I tried this before i added meta querys, and template values and didnt work.

    Thread Starter lxm7

    (@lxm7)

    But ‘limit’ seems like the only syntax made available in the EM output array for altering number of posts. Where / how else could i change the number of output posts per category in this instance? Thanks

    Thread Starter lxm7

    (@lxm7)

    I found this was the syntax that did it, mainly on the 2nd line that I was lost on what it should be ( ‘format’=>'{has_category_cat1}: )

    $args = array( 'post_type' => 'event' );
    $loop = new WP_Query( $args );
    while ( $loop->have_posts() ) : $loop->the_post();
     	echo EM_Events::output( array( 'limit'=>3,'format'=>'{has_category_cat1}
     	<ul>
     	  <li>
     	    <h2>#_EVENTNAME</h2>
    	 	<p>#_EVENTEXCERPT</p>
     		#_24HSTARTTIME
    		#_24HENDTIME
    		#_12HSTARTTIME
    		#_12HENDTIME
    		#_EVENTTIMES
    		#_EVENTDATES
     	   </li>
     	</ul>
     {/has_category_cat1}') );
    endwhile;

    I guess this (! the format argument !) must be somewhere in the documentation but its pretty hard to find, even the #_(placeholders) seemed quite hidden, possibly the navigation isn’t quite as clear as it could be for the plugin site. Phenomenal plugin though!

    Hi, could you go into a bit more detail please with the previously sloppy named theme versions as I’m having the same issue on ipad3. Do you mean custom themes you made yourself, default ones, and what specifically in the name was causing it to cr4ash or conflict? Cheers!

    Just for anyone having the issue ( i think its very similar to bartoli) except I have SMTP configure plugin and Contact Form 7 together and there was a js clash. I removed the gmail bit in configure-smtp.php as im using Rackspace with send mail for my mail relay:

    /**
    * Outputs JavaScript
    *
    * @return void (Text is echoed.)
    */
    public function add_js() {
    $alert = __( ‘Be sure to specify your full GMail email address (including the “@gmail.com”) as the SMTP username, and your GMail password as the SMTP password.’, $this->textdomain );
    $checked = $this->gmail_config[‘smtp_auth’] ? ‘1’ : ”;
    echo <<<JS
    <script type=”text/javascript”>
    function configure_gmail() {
    // The .attr(‘checked’) == true is only for pre-WP3.2
    if (jQuery(‘#use_gmail’).attr(‘checked’) == ‘checked’ || jQuery(‘#use_gmail’).attr(‘checked’) == true) {
    jQuery(‘#host’).val(‘{$this->gmail_config[‘host’]}’);
    jQuery(‘#port’).val(‘{$this->gmail_config[‘port’]}’);
    if (jQuery(‘#use_gmail’).attr(‘checked’) == ‘checked’)
    jQuery(‘#smtp_auth’).prop(‘checked’, $checked);
    else // pre WP-3.2 only
    jQuery(‘#smtp_auth’).attr(‘checked’, {$this->gmail_config[‘smtp_auth’]});
    jQuery(‘#smtp_secure’).val(‘{$this->gmail_config[‘smtp_secure’]}’);
    if (!jQuery(‘#smtp_user’).val().match(/[email protected]$/) ) {
    jQuery(‘#smtp_user’).val(‘[email protected]’).focus().get(0).setSelectionRange(0,8);
    }
    alert(‘{$alert}’);
    return true;
    }
    }
    </script>

    JS;
    }

    /**
    * If the ‘Use GMail’ option is checked, the GMail settings will override whatever the user may have provided
    *
    * @param array $options The options array prior to saving
    * @return array The options array with GMail settings taking precedence, if relevant
    */
    public function maybe_gmail_override( $options ) {
    // If GMail is to be used, those settings take precendence
    if ( $options[‘use_gmail’] )
    $options = wp_parse_args( $this->gmail_config, $options );
    return $options;
    }

    This was causing the clash with the AJAX code, causing the infinite spinning arrows.

Viewing 10 replies - 1 through 10 (of 10 total)