Welcome to Geeklog, Anonymous Thursday, March 28 2024 @ 01:53 pm EDT

Geeklog Forums

Submissions Link To User Edit


Status: offline

emagin

Forum User
Regular Poster
Registered: 08/05/03
Posts: 92
Hello, I am trying my hand at some hacking to make my life easier. I run GL in user Approval mode, so I approve users as they SIGN IN. I would like to make the User link on the Submissions page (/admin/moderation.php) go like this: FROM: /users.php?mode=profile&uid=25 TO: /admin/user.php?mode=edit&uid=25 This allows me to see the user specifics, change their user ID or whatever if necessary. The Profile page is quite useless for USER admin, while it is very useful for STORY admin. So on moderation.php line 350 I've changed: FROM:
Text Formatted Code
$mod_templates->set_var('edit_submission_url', $_CONF['site_url'] . '/admin/user.php?mode=editset_var('edit_submission_url', $_CONF['site_url'] .
      '/users.php?mode=profile&uid=' . $A['uid']);
TO:
Text Formatted Code
$mod_templates->set_var('edit_submission_url', $_CONF['site_url'] . '/admin/user.php?mode=edit&uid=' . $A['uid']);
No luck, the moderation.php page shows no change when I try to click on a user. Can someone help me understand what I am missing? Thanks
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
This works for me:
Text Formatted Code
    $mod_templates->set_var('edit_submission_url', $_CONF['site_admin_url']
            . '/user.php?mode=edit&uid=' . $A['uid']);
bye, Dirk
 Quote

Status: offline

emagin

Forum User
Regular Poster
Registered: 08/05/03
Posts: 92
Thank you Dirk! Aha, yes, 'site_admin_url' was the trick. I'm learning PHP ! Is it critical that the line of code be split with the
Text Formatted Code
. '/user.php?
on the line below? For neatness I've been doing one line, but maybe that's no good? Thanks again
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by emagin:For neatness I\'ve been doing one line, but maybe that\'s no good?
It\'s a matter of personal style only. I prefer lines to be no longer than 80 characters. Btw, I\'ve added this to CVS now, so you won\'t have to patch future versions of Geeklog Wink bye, Dirk
 Quote

Status: offline

emagin

Forum User
Regular Poster
Registered: 08/05/03
Posts: 92
Wow. I am not a programmer, and obviously failed that one, but it\'s nice to see one\'s idea used for the code. I feel like I am contributing!!! Now just get us a good PHP-wiki setup so I can help with documentation! That\'s one thing GL needs - a truly simple, open, security-based wiki so we can manage a common documentation project!
 Quote

All times are EDT. The time is now 01:53 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content