?> <tr> <td colspan="2" style="border:none"> <input type="button" value="<?php echo GetMessage("LISTS_OPTIONS_ADD_RIGHT"); ?> " onClick="addNewTableRow('tblRIGHTS', /right\[(n)([0-9]*)\]/g, 2)"> </td> </tr> </table> </td> </tr> <?php if (IsModuleInstalled('socialnetwork')) { $socnet_iblock_type_id = COption::GetOptionString("lists", "socnet_iblock_type_id"); $socnet_enable = CLists::IsEnabledSocnet(); $tabControl->BeginNextTab(); ?> <tr> <td width="40%"><?php echo GetMessage("LISTS_OPTIONS_SOCNET_ENABLE"); ?> :</td> <td width="60%"><input type="checkbox" name="socnet_enable" <?php if ($socnet_enable) { echo "checked"; } ?> value="Y"></td> </tr> <tr>
public static function EnableSocnet($bActive = false) { if ($bActive) { if (!CLists::IsEnabledSocnet()) { RegisterModuleDependences("socialnetwork", "OnFillSocNetFeaturesList", "lists", "CListsSocnet", "OnFillSocNetFeaturesList"); RegisterModuleDependences("socialnetwork", "OnFillSocNetMenu", "lists", "CListsSocnet", "OnFillSocNetMenu"); RegisterModuleDependences("socialnetwork", "OnParseSocNetComponentPath", "lists", "CListsSocnet", "OnParseSocNetComponentPath"); RegisterModuleDependences("socialnetwork", "OnInitSocNetComponentVariables", "lists", "CListsSocnet", "OnInitSocNetComponentVariables"); } } else { if (CLists::IsEnabledSocnet()) { UnRegisterModuleDependences("socialnetwork", "OnFillSocNetFeaturesList", "lists", "CListsSocnet", "OnFillSocNetFeaturesList"); UnRegisterModuleDependences("socialnetwork", "OnFillSocNetMenu", "lists", "CListsSocnet", "OnFillSocNetMenu"); UnRegisterModuleDependences("socialnetwork", "OnParseSocNetComponentPath", "lists", "CListsSocnet", "OnParseSocNetComponentPath"); UnRegisterModuleDependences("socialnetwork", "OnInitSocNetComponentVariables", "lists", "CListsSocnet", "OnInitSocNetComponentVariables"); } } }