Skip to content

Instantly share code, notes, and snippets.

@KaineLabs
Last active February 14, 2022 01:35
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KaineLabs/80ef281cfa7d7d1300a42ffb4be7dd78 to your computer and use it in GitHub Desktop.
Save KaineLabs/80ef281cfa7d7d1300a42ffb4be7dd78 to your computer and use it in GitHub Desktop.
Set Activity Comments Length
<?php
/**
* Set Activity Comments Length - Show the latest 2 comments.
*/
function yzc_set_activity_comments_length() { ?>
<script type="text/javascript">window.youzify_comments_length = 2;</script>
<?php
}
add_action( 'wp_head' , 'yzc_set_activity_comments_length', 999 );
@joerggermany
Copy link

Hello,

when I try to use this snipped I get a critical error.

I include the snipped in the bp-custom.php in the plugin directory.

How can I solve this?

Thank you very much!
Joerg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment