Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Re: [Paul] Decide if plugin executed on admin interface or website?

Quote Reply
Re: [Paul] Decide if plugin executed on admin interface or website? In reply to
Quote:
You are still going to have the same problem using an "internal" method. How can Links SQL know whether you are using the admin script or not?
I checked a bit into admin.cgi and I see just one solution:
- to ask Alex, to add $ADMIN variable within sub main or just before calling main function (this is how I solved it in Links 2.0).
I simply do not see other solution.

Quote:
No you don't $is_admin would be global.
Yes, I understood.
But $is_admin could be only defined, right at the start of a plugin, not earlier (the best would be in admin.cgi, but due to plugin system this is not possible of course). So all plugins will have the /admin\.cgi$/ hard coded text. Therefore I will have to change all references in those plugins, which are used on both admin and site pages.

Best regards,
Webmaster33


Paid Support
from Webmaster33. Expert in Perl programming & Gossamer Threads applications. (click here for prices)
Webmaster33's products (upd.2004.09.26) | Private message | Contact me | Was my post helpful? Donate my help...
Subject Author Views Date
Thread; hot thread Decide if plugin executed on admin interface or website? webmaster33 10763 Sep 5, 2002, 3:47 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
Andy 10333 Sep 5, 2002, 3:52 AM
Thread; hot thread Re: [Andy] Decide if plugin executed on admin interface or website?
webmaster33 10315 Sep 5, 2002, 4:01 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
Paul 10342 Sep 5, 2002, 4:05 AM
Thread; hot thread Re: [Paul] Decide if plugin executed on admin interface or website?
webmaster33 10371 Sep 5, 2002, 4:09 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
Paul 10336 Sep 5, 2002, 4:19 AM
Thread; hot thread Re: [Paul] Decide if plugin executed on admin interface or website?
webmaster33 10299 Sep 5, 2002, 4:30 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
Paul 10274 Sep 5, 2002, 5:07 AM
Post; hot thread Re: [Paul] Decide if plugin executed on admin interface or website?
webmaster33 10254 Sep 5, 2002, 5:15 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
yogi 10321 Sep 5, 2002, 4:23 AM
Thread; hot thread Re: [yogi] Decide if plugin executed on admin interface or website?
webmaster33 10362 Sep 5, 2002, 4:33 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
yogi 10326 Sep 5, 2002, 4:41 AM
Thread; hot thread Re: [yogi] Decide if plugin executed on admin interface or website?
webmaster33 10321 Sep 5, 2002, 5:17 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
Paul 10265 Sep 5, 2002, 5:23 AM
Post; hot thread Re: [Paul] Decide if plugin executed on admin interface or website?
webmaster33 10320 Sep 5, 2002, 6:03 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
Alex 10314 Sep 5, 2002, 1:10 PM
Thread; hot thread Re: [Alex] Decide if plugin executed on admin interface or website?
webmaster33 10227 Sep 6, 2002, 12:56 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
Alex 10345 Sep 6, 2002, 10:50 AM
Thread; hot thread Re: [Alex] Decide if plugin executed on admin interface or website?
webmaster33 10338 Sep 6, 2002, 11:05 AM
Thread; hot thread Re: [webmaster33] Decide if plugin executed on admin interface or website?
Alex 10311 Sep 6, 2002, 11:09 AM
Post; hot thread Re: [Alex] Decide if plugin executed on admin interface or website?
webmaster33 10207 Sep 6, 2002, 11:12 AM