Пример #1
0
        bh_log($bhlang['notice:permissions_changed'], "BH_NOTICE");
    }
}
# Group perms change
if (!empty($_GET['group']) || $_GET['group'] === "0") {
    $fileobj->set_grouprights($_GET['groupname'], $_GET['group']);
    bh_log($bhlang['notice:permissions_changed'], "BH_NOTICE");
}
# Public perms change
if ($_GET['public'] === "0" || $_GET['public'] === "1" || $_GET['public'] === "2") {
    # Change the public permissions to whatever was sent
    $fileobj->set_publicrights($_GET['public']);
    # Display the message
    bh_log($bhlang['notice:permissions_changed'], "BH_NOTICE");
}
# Get the users, groups and public permissions
$usersrights = $fileobj->usersrights();
$groupsrights = $fileobj->groupsrights();
$publicrights = $fileobj->publicrights();
# Open the layout
$layoutobj = new bhlayout("sharingfolder");
# Give it the content
$layoutobj->content1 = $usersrights;
$layoutobj->content2 = $groupsrights;
$layoutobj->content3 = $publicrights;
# And the name
$layoutobj->subtitle1 = $bhlang['title:sharing_'] . $filename;
# And the filepath
$layoutobj->filepath = $filepath;
# Diiiiisplay.
$layoutobj->display();