Forum Replies Created

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
  • in reply to: Visual composer bugs #29336
     orbitkiller
    Participant

    Well i found the issue myself at least a part of the issue i suppose.

    Why wasn’t i able to define a sepecific category to filter, in built query section, was the question?
    -Well i noticed that there weren’t any posts assigned to that specific cat i wanted to enter and filter for, so if you want the category filter option to be functionning for a specific cat, there has to be at least one single post assigned to it, else it will not be available for selection.

    The other issue i ran into now is that i am able to enter a filterable cat, but it does no filtering at all, as it always shows me all posts on frontpage 🙁

    Well the post grid filter (query) seems not to work either, even with a specific category defined for the query.

    Could you please provide me help as i am stuck now, for sure.

    Regards,
    Charel

    in reply to: Visual composer bugs #29330
     orbitkiller
    Participant

    Hi,

    i am experiencing a weird issue that does not let me set filters for posts using vc posts grid. The post grid settings let me built a query to filter posts by categories, but it seems like the built query function does not accept any parameters, especially posts category, neither post id or slug. Even after updating today to the latest versions, no success.

    Is there sth i am missing?

    Thx in advance for any help.

    Regards,
    Charel

    Attachments:
    You must be logged in to view attached files.
    in reply to: Animated number question #27838
     orbitkiller
    Participant

    Let me correct only one thing, line 16 in my previous code post is not needed.

    in reply to: Animated number question #27837
     orbitkiller
    Participant

    Hi,

    i finally did a whole solution for this issues, at least to the best of my knowledge.

    My Code:

    COPY CODE
    <?php 
    /*******************************************************************
    :: Extends functions.php
    ********************************************************************/
    
    /**
     * @author orbitkiller
     * @function get num rows of db tables / buddypress group / blog count by row
     */
    function ok_get_row_count( $table_name ) {
    	
    	//$table_name -> db table to count the rows of
    	
    	global $wpdb;
    	$array = $wpdb->get_results( "SELECT * FROM $table_name");
    	$rows = mysql_num_rows($count);
    	
    	//simple array iteration with count to retrieve row count
    	$rows = 0;
    	foreach ($array as $key => $value) {
    		$rows++;
    	}
    	
    	return $rows;
    }
    
    /**
     * @author orbitkiller
     * @function adds shortcode support to get user and group count for animated kleo numbers
     */
    function ok_get_option_shortcode( $theme_option ) {
    	return get_option( $theme_option['key'] );
    }
    add_shortcode( 'get-theme-option', 'ok_get_option_shortcode' );
    
    /**
     * @author orbitkiller
     * @function bp add group count and blog count to custom options
     */
    //create options
    add_option( "_ok_bp_member_count", 0, "", "yes");
    add_option( "_ok_bp_group_count", 0, "", "yes");
    add_option( "_ok_bp_blog_count", 0, "", "yes");
    //add_option( "_ok_bp_message_count", 0, "", "yes");
    
    //get bp group count and blog count
    /*
    db table names for extended counts display
    bp active members -> wp_bp_groups_members
    bp active groups -> wp_bp_groups
    bp blogs -> wp_bp_user_blogs
    bp written messages -> wp_bp_messages_messages
    */
    $okBPmembers = ok_get_row_count("wp_bp_groups_members");
    $okBPgroups = ok_get_row_count("wp_bp_groups");
    $okBPblogs = ok_get_row_count("wp_bp_user_blogs");
    //$okBPblogs = ok_get_row_count("wp_bp_messages_messages");
    
    //update options
    update_option( "_ok_bp_member_count", $okBPmembers);
    update_option( "_ok_bp_group_count", $okBPgroups);
    update_option( "_ok_bp_blog_count", $okBPblogs);
    //update_option( "_ok_bp_message_count", $okBPblogs);
    
    ?>

    Hope i could help.

    Bye
    Charel

    in reply to: Animated number question #27361
     orbitkiller
    Participant

    Hi, i developed a solution myself, it is not yet finished but it should get you (people that want to use it) an idea.

    Animated Kleo Numbers
    ######
    Issue: Kleo shortcode only lets you animated static number. What we want is to get these animated numbers in real dynamically

    My Solution:

    functions.php EDIT/ADD
    ######

    COPY CODE
    
    
    /**
     * @author orbitkiller
     * @function adds shortcode support to get user and group count for animated kleo numbers
     */
    function ok_get_option_shortcode( $theme_option ) {
    return get_option( $theme_option['key'] );
    }
    add_shortcode( 'get-theme-option', 'ok_get_option_shortcode' );
    
    
    Use de following Option shortcode to retrieve the wanted data
    ######
    [get-theme-option key="<yourOptionNameYouWantDataFrom>"]
    
    
    
    KLEO Animated Number Shortcode MODIFIED
    ######
    members
    [kleo_animate_numbers animation="animate-when-almost-visible" timer="3000"][get-theme-option key="_transient_bp_active_member_count"][/kleo_animate_numbers]
    public blogs
    [kleo_animate_numbers animation="animate-when-almost-visible" timer="3000"][get-theme-option key="blog_public"][/kleo_animate_numbers]
    
    

    Further issues
    ######
    For group count and active topics i did not find any option, but i am developing a function that retrieves these count values and i will put them into custom option.
    I did not have much time today, i will post this function in the coming days to complete this solution…

    Hints
    #######
    Where to find option names / options store data -> /wp-admin/options.php (when logged-in)
    Can be applied to other displayable values if needed/wanted…

    Have fun.
    Charel

    in reply to: Animated number question #27360
     orbitkiller
    Participant

    Hi,

    your theme is really a blast!

    But is there any way to get these numbers shown in your example “xxx” dynamically, by shortcode for example, means that they really reflect the numbers of your current site, without editing them manually?

    Thank you.
    Charel

Viewing 6 posts - 1 through 6 (of 6 total)

Log in with your credentials

Forgot your details?