Documentation

CStudent::Delete

bool
CStudent::Delete(
 int USER_ID
);

The Delete method deletes a student account of a specified user.

Parameters

ParameterDescription
USER_ID The user ID.

Return Values

The method returns true on success, or false otherwise.

See Also

  • CStudent::Add

    Example

    
    <?
    if (CModule::IncludeModule("learning"))
    {
        $USER_ID = 3;
        if ($USER->IsAdmin())
        {
            @set_time_limit(0);
            $DB->StartTransaction();
            if (!CStudent::Delete($USER_ID))
            {
                echo "Error!";
                $DB->Rollback();
            }
            else
                $DB->Commit();
        }
    }
    ?>
  • © «Bitrix24», 2001-2024