display plugins in static page

Creating and modifying plugins.
Post Reply
Yukari
Posts: 2
Joined: Mon May 08, 2006 4:32 am

display plugins in static page

Post by Yukari »

I'd like to know how I can display a plugin in a static page...

what i'd like to do is to show the Statistics I can see in the admin in a static page, and also the plugins to display top refereers...

I read the thread for pulling plugins out of the sidebar but he wants to display in the frontpage so it didn't really help...

if someone can help me, i'd appreciate a lot.
thanks
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: display plugins in static page

Post by garvinhicking »

Hi!

You actually can't do this without some coding skills.

There are two ways to achieve that. The one is to create yourself a Smarty function that retrieves and shows the data, then you install the "serendipity_event_smartymarkup" plugin which can be applied to static page contents. By creating a custom smarty function, you could call it via "{my_custom_function var="xxx"}".

In the case of just fetching the statistics output, you don'T need to create your own custom smarty function; it suffices to install that smartymarkup plugin and use this code in your plugin:

Code: Select all

{serendipity_hookPlugin hook="backend_sidebar_entries_event_display_statistics" hookAll=true}
(Read http://www.s9y.org/78.html for details)

The second way is to create an event plugin, or modify the statistics even plugin to show it's data on a specific event hook.

HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Yukari
Posts: 2
Joined: Mon May 08, 2006 4:32 am

Post by Yukari »

thank ya so much.
I'll try it out. :P
Post Reply