Forums  ›  Dolphin 6.1  ›  Troubleshooting
 

Removing "Join" on Events

Hi all

How do I remove the "Join" action on Events. I have read suggestions to edit the letter that is being sent, but that is not a viable solution. I would reallly appreciate help on the matter. I am running D. 6.1.4.

Thanks in advance

Happy day to all.

If you wan't to remove the "Join" link from an event page so your members can only see the event and details but not join it and get the automated email. This should be fairly easty to just remove/hide the link. I think I am understanding what you are after.

See the attached image for the area I am thinking you are talking about.

Join Event



If so then like I said you can hide the link and image.

You will want to backup the file before editing first:
/inc/classes/BxDolEvents.php

It's a fairly big file. Search and find:
$sUsersActions = '';
$sPartProfSQL = "SELECT * FROM `SDatingParticipants` WHERE `IDEvent`={$iEventID} AND `IDMember`={$aMember['ID']}";
$aPartProfSQL = db_arr($sPartProfSQL);
if (mysql_affected_rows() == 0) { //no matches
$sUsersActions = <<<EOF
<div class="padds">
<img src="{$site['icons']}_membership.jpg" alt="{$sJoinC}" title="{$sJoinC}" class="marg_icon" />
<a class="actions" href="{$_SERVER['PHP_SELF']}" onclick="document.forms.JoinEventForm.submit(); return false;" >
{$sJoinC}
</a>
</div>


You can either comment out the referrence to the image and join using <!-- opening and closing -->

Like so:


$sUsersActions = '';
$sPartProfSQL = "SELECT * FROM `SDatingParticipants` WHERE `IDEvent`={$iEventID} AND `IDMember`={$aMember['ID']}";
$aPartProfSQL = db_arr($sPartProfSQL);
if (mysql_affected_rows() == 0) { //no matches
$sUsersActions = <<<EOF
<div class="padds">
<!--<img src="{$site['icons']}_membership.jpg" alt="{$sJoinC}" title="{$sJoinC}" class="marg_icon" />-->
<!--<a class="actions" href="{$_SERVER['PHP_SELF']}" onclick="document.forms.JoinEventForm.submit(); return false;" >
{$sJoinC}
</a>-->
</div>

Or remove them from the code completely. If you remove it though it won't come back so don't forget should you later decide you need or want it.

Also if you upgrade to a newer version you may have to do this again, as the upgrade could overwrite these changes.

Always nice to take a few notes if you really want to keep up on your site changes.

Hi there

It worked perfectly! Thanks.