|
Revision 1301, 0.7 kB
(checked in by dramirez, 1 year ago)
|
Moved from units to mod:
Updated .htaccess rules
|
- Property svn:eol-style set to
native
|
| Line | |
|---|
| 1 |
<?php |
|---|
| 2 |
|
|---|
| 3 |
|
|---|
| 4 |
|
|---|
| 5 |
// Check permissions |
|---|
| 6 |
// run("permissions:check", "object"); |
|---|
| 7 |
|
|---|
| 8 |
// To add permission functionality to your own units, add code to |
|---|
| 9 |
// $function['permissions:check'] in your main.php |
|---|
| 10 |
|
|---|
| 11 |
// You can use this file as a template; $page_owner should already |
|---|
| 12 |
// be set - if the user is on a page specific to your unit, it should |
|---|
| 13 |
// be set in run("your_unit_name:init") |
|---|
| 14 |
|
|---|
| 15 |
global $page_owner; |
|---|
| 16 |
|
|---|
| 17 |
if ($parameter == "profile") { |
|---|
| 18 |
|
|---|
| 19 |
if ($page_owner == $_SESSION['userid']) { |
|---|
| 20 |
$run_result = true; |
|---|
| 21 |
} |
|---|
| 22 |
|
|---|
| 23 |
} |
|---|
| 24 |
|
|---|
| 25 |
?> |
|---|