BuddyDev

Search

Replies

  • Participant
    Level: Guru
    Posts: 907
    Tosin on in reply to: Buddyblog text change on edit #48850

    Hi Brajesh

    After further testing I noticed that the encoding issue only occurs when publishing or editing with the buddyblog medium editor.

    After deactivating the buddyblog medium editor, everything works fine and there are no more encoding issues.

  • Participant
    Level: Guru
    Posts: 907
    Tosin on in reply to: Buddyblog text change on edit #48837

    I just found out its an encoding problem that can occur on old post when database has been migrated,

    I tried this code but it did not work

    function fix_weird_characters() {
        global $wpdb;
        $replacements = array(
            '“' => '“',
            '”' => '”',
            '’' => '’',
            '‘' => '‘',
            '—' => '–',
            '–' => '—',
            '•' => '-',
            '…' => '…'
        );
        foreach ($replacements as $key => $value) {
            $query = $wpdb->prepare(
                "UPDATE {$wpdb->posts} SET post_content = REPLACE(post_content, %s, %s)",
                $key,
                $value
            );
            $wpdb->query($query);
        }
    }
    add_action('wp_loaded', 'fix_weird_characters'); 
  • Participant
    Level: Guru
    Posts: 907
    Tosin on in reply to: Buddyblog reorganise form fields #48831

    Thanks Brajesh

    Illbe looking forward to the next update

  • Participant
    Level: Guru
    Posts: 907

    Thanks for the feedback

    So if this is not scalable, then its better I stick to your advise as am planning or a large community platform

  • Participant
    Level: Guru
    Posts: 907

    By default new users are subscribers but their role changes to contributor on first login, so I want to hide all activities of subscribers who have never logged in.

    Inactive users are subscribers
    Active users are contributors

  • Participant
    Level: Guru
    Posts: 907

    Thanks Ravi

    I have tested the latest version which works perfectly so this issue is now resolved.

  • Participant
    Level: Guru
    Posts: 907

    Gentle reminder sir

    Thanks

  • Participant
    Level: Guru
    Posts: 907

    (alphabetical) works by default with or without it, I have also tried online, newest, random and popular which are all not working.

    I also made sure to clear my cache everytime

  • Participant
    Level: Guru
    Posts: 907

    I also have this code

     function open_external_links_in_new_tab_bp_activity( $query_string, $object ) {
      if ( $object != 'activity' ) {
        return $query_string;
      }
      ?>
      <script type="text/javascript">
      var links = document.getElementsByTagName("a");
      for (var i = 0; i < links.length; i++) {
        var link = links[i];
        if (link.hostname != window.location.hostname) {
          link.target = "_blank";
        }
      }
      </script>
      <?php
      return $query_string;
    }
    add_filter( 'bp_ajax_querystring', 'open_external_links_in_new_tab_bp_activity', 10, 2 ); 
  • Participant
    Level: Guru
    Posts: 907

    I have this code in my bp-custom.php file

     function theme_alter_members_parse_args( $loop ) {
    	if ( bp_is_members_directory() ) {
    		{
    		$loop['per_page'] = 12;
    		}
    	}
    	return $loop;
    }
    add_filter( 'bp_after_has_members_parse_args', 'theme_alter_members_parse_args' ); 

    and this is the shortcode im using

    [bp-featured-members view=”default” type=”newest” enable_type=”1″ max=”30″]