Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
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

This comment has been minimized.

Copy link

@joerggermany joerggermany commented Oct 1, 2021

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