Please login or register.

Login with username, password and session length
Advanced search  

News:

You need/want an older version of sNews ? Download an older/unsupported version here.

Author Topic: edit link shows at bottom of content to registered users (not editors)  (Read 2227 times)

lessismore

  • Jr. Member
  • **
  • Karma: 0
  • Posts: 67

If content is customized to "allow others to edit" - an edit link shows at the bottom of the content to all registered users.

Fortunately, the link is dead to level 4 users (non-editors) - so I think this is a cosmetic oops.

In order to stop the edit link from being displayed, find in function center() (around line 747 in original file):
Code: [Select]
## MULTI_USER
                                        else if ($_SESSION[db('website').'Logged_In'] == token() && get_identity($_SESSION['id'], 'level')) {echo '<p>'.$edit_link.'</p>';} // modded for MULTI_USER
                                        ## END MULTI_USER
                                }
                                else if (substr($position, 0, 1) != '2' && empty($currentPage)) {
                                        if ($infoline == true) {
and change the AND (&&) on the get_identity to make sure the link doesn't show to registered (level 4) users to:
Code: [Select]
(get_identity($_SESSION['id'], 'level') != '4'))
Logged