# give/4.16.8.1/src/Campaigns/Blocks/CampaignComments/render.php

GiveWP – Donation Plugin and Fundraising Platform, version 4.16.8.1. 19 lines.

- Page: https://pluginprobe.com/plugins/give/4.16.8.1/code/src/Campaigns/Blocks/CampaignComments/render.php
- Raw: https://pluginprobe.com/plugins/give/4.16.8.1/raw/src/Campaigns/Blocks/CampaignComments/render.php
- Modified: 2026-06-29T13:55:54+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/give/4.16.8.1/code/src/Campaigns/Blocks/CampaignComments/render.php#L10-L20`.

```php
<?php

use Give\Campaigns\Blocks\CampaignComments\Controller\BlockRenderController;
use Give\Campaigns\Models\Campaign;
use Give\Campaigns\Repositories\CampaignRepository;

/**
 * @var array    $attributes
 * @var Campaign $campaign
 */

if (!isset($attributes['campaignId'])
    || !$campaign = give(CampaignRepository::class)->getById($attributes['campaignId'])
) {
    return;
}

echo (new BlockRenderController())->render($attributes, $campaign->secondaryColor ?? '#27ae60');

```
