Jump to content


Popular Content

Showing content with the highest reputation on 07/20/2021 in all areas

  1. Here are steps that you can have these buttons on member's profile page. NOTE: this is only for KVS Default Theme. Step 1. Please check your theme version in Website UI -> Theme settings. If it says KVS Default (8.4) or above, then skip this step. If its version less than 8.4, then update these 2 files on your server: https://www.kvs-demo.com/static/js/main.js https://www.kvs-demo.com/static/js/main.min.js Step 2. Edit member profile template in Website UI -> Page components -> include_member_profile.tpl and add the following code at the very end: {{if $data.user_id!=$smarty.session.user_id && $lang.donations}} <div style="margin-top: 10px"> {{foreach item="donation" from=","|explode:$lang.donations}} {{assign var="donation" value=$donation|trim|intval}} {{if $donation>0}} <div style="display: inline-block; padding: 5px"> <form data-form="ajax" data-success="message" data-message="{{$lang.memberzone.success_message_donate|count_format:"%tokens%":$donation|replace:"%display_name%":$data.display_name}}"> <div class="generic-error hidden"></div> <input type="hidden" name="function" value="donate"/> <input type="hidden" name="tokens" value="{{$donation}}"/> <input type="submit" class="submit" value="{{$lang.memberzone.button_donate|count_format:"%tokens%":$donation}}"/> </form> </div> {{/if}} {{/foreach}} </div> {{/if}} Step 3. Go into Website UI -> Texts and add the following 4 texts: donations = 1, 5, 100 validation.common.tokens_not_enough_tokens = You don't have enough tokens to donate. memberzone.button_donate = Donate [count]%tokens% tokens || 1: 1 token[/count] memberzone.success_message_donate = Thank you! Your donation of [count]%tokens% tokens || 1: 1 token[/count] was send to <b>%display_name%</b>. The first one lists possible donations in tokens, adjust it to get more or less donation buttons with the needed amounts.
    1 point
  • Create New...