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

Is there a way to hook user_page() or clean_output() ?

Quote Reply
Is there a way to hook user_page() or clean_output() ?
Alex,
Is there a way to hook user_page() or clean_output() ?

I would need hook to replace user_page with a plugin sub.

Hacking or modifying the Links.pm is not a solution, because if I modify it, I can not keep compatibility with future LSQL upgrades...

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...
Quote Reply
Re: [webmaster33] Is there a way to hook user_page() or clean_output() ? In reply to
Hi,

No, there are currently no hooks for user page or clean output. What are you trying to do? Perhaps it could be implemented somewhere else?

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Is there a way to hook user_page() or clean_output() ? In reply to
Alex, check both threads below.
You will remember, what I'm talking about, and why I'm trying to modify the page displaying process, and ignoring (or correcting the bug) the clean_output().

Post 1: URL generating
Post 2: [BUG] in clean_output()

Thanks,
Webmaster33
Quote Reply
Re: [Alex] Is there a way to hook user_page() or clean_output() ? In reply to
No, there is no other solution to the problem, only if we have hook to user_page() and clean_output().

User page is always called, when something is displayed through Links::SiteHTML::display() or Links::Build::build().
Both is calling a _compile function, which calls the Links::user_page().

So hook is needed for both user_page() and clean_output().

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...
Quote Reply
Re: [Alex] Is there a way to hook user_page() or clean_output() ? In reply to
I would also like to see a hook on Links::user_page, because sometimes you want to add tags/do some useful stuff for all templates. And while you're at it, a hook on clean_output cannot do any harm, can it?

Thanks.

Ivan
-----
Iyengar Yoga Resources / GT Plugins
Quote Reply
Re: [yogi] Is there a way to hook user_page() or clean_output() ? In reply to
Yep.

I contacted Alex, and he aggreed, and already added the hook for clean_output in his development version, however there is still missing a hook for user_page.
I hope, we can convince him, that user_page() function reaaally needs a hook.

I also asked to release a patch, when user_page and clean_output hooks has been added, so we can base on it in our developments.

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...
Quote Reply
Re: [Alex] Is there a way to hook user_page() or clean_output() ? In reply to
Alex,
What is your official opinion about user_page() hook? It seems, I'm not lonely with my request...

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...
Quote Reply
Re: [Alex] Is there a way to hook user_page() or clean_output() ? In reply to
The clean_output() has hook since LSQL v2.1.2. But I still miss a hook for user_page().
I would need a hook for user_page() because it has hard coded parameters used in it:
$IN->param('t') and $IN->param('d')

Is there a specific reason why user_page() can not be hooked?

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...