Page 1 of 1
How To Display Plugins On The Index Page Only
Posted: Sat Jun 19, 2010 9:25 pm
by Maccsta
Hi!
Is there any way of controlling a plugin so it
only displays on the index page?
In particular I wanted to do this for the ‘External PHP Application’ and ‘HTML Nugget’ - I don't want particular plugins site wide.
Thanks in advance

Re: How To Display Plugins On The Index Page Only
Posted: Sun Jun 20, 2010 1:39 pm
by garvinhicking
Hi!
I think the HTML nugget should have an option for that?! External PHP doesn't, one would need over the PHP code for those checks there...
Regards,
Garvin
Re: How To Display Plugins On The Index Page Only
Posted: Sun Jun 20, 2010 4:53 pm
by Don Chambers
garvinhicking wrote:I think the HTML nugget should have an option for that?!
No, it does not..... but I think it would be a nice addition. Current options for the HTML nugget are extended entry only, overview pages, and all times.
Re: How To Display Plugins On The Index Page Only
Posted: Sun Jun 27, 2010 6:17 pm
by Maccsta
Yeah the ability to disable any plugin site wide would be a great addition to Serendipity.
I've set certain HTML nuggets to show on overview pages only which it better, but not perfect.
Is there a quick fix I could use to achieve the "overview page only" on the External PHP application?
Thanks for any help

Re: How To Display Plugins On The Index Page Only
Posted: Sun Jun 27, 2010 7:40 pm
by garvinhicking
Hi!
Yes, you can edit the sidebar.tpl template file, and inside the foreach loop make a check for if $startpage and pluginname == BLABLA then do nothing, else show the plugin.
Hope that gets the idea, I don't have the time for actual code right now
Regards,
Garvin
Re: How To Display Plugins On The Index Page Only
Posted: Sun Jun 27, 2010 8:18 pm
by Maccsta
garvinhicking wrote:Hi!
Yes, you can edit the sidebar.tpl template file, and inside the foreach loop make a check for if $startpage and pluginname == BLABLA then do nothing, else show the plugin.
Hope that gets the idea, I don't have the time for actual code right now
Regards,
Garvin
Thanks Gavin, celebrating the Germany win I guess
Programming isn't my strong point, I'll try it on a test blog, I have a feeling I won't get it working without the actual code though!
Re: How To Display Plugins On The Index Page Only
Posted: Fri Jul 09, 2010 5:44 pm
by Maccsta
Any idea what code I should be implementing into the sidebar.tpl?
I'm stuck and it's not working

Re: How To Display Plugins On The Index Page Only
Posted: Fri Jul 09, 2010 6:01 pm
by Don Chambers
I'll take a look at this when I get back this afternoon. Should be simple.
Re: How To Display Plugins On The Index Page Only
Posted: Fri Jul 09, 2010 9:53 pm
by Don Chambers
I was thinking each html nugget had a unique identifier... but that does not seem to be the case. They all have the same class of container_serendipity_html_nugget_plugin (container_ is a prefix).... are you using nuggets on any other pages, or just the front page?
Re: How To Display Plugins On The Index Page Only
Posted: Fri Jul 16, 2010 1:57 am
by tpelia
I'm searching answers to this very problem -- I'm pretty sure I'm the least knowledgeable person in programming matters on this thread, as well as the other one I started asking this same question!
I think there a way to do this in HTML on Word Press -- but I can't seem to do the same on Serendipity. Or is there?
Re: How To Display Plugins On The Index Page Only
Posted: Fri Jul 16, 2010 9:50 pm
by Maccsta
Don Chambers wrote:I was thinking each html nugget had a unique identifier... but that does not seem to be the case. They all have the same class of container_serendipity_html_nugget_plugin (container_ is a prefix).... are you using nuggets on any other pages, or just the front page?
Ok what I am trying to achieve is being able to select which plugins appear on each page such as on an individual blog post, static pages, and category pages or even page 2 or 3 of the main blog.
Obviously I want the plugins that are going to make me money on every page i.e. advertisements, links to sponsors etc (I can nofollow these links no problem) but for SEO reasons I would like the plugins for link trades and blog directory submissions to just appear on the front index page.
So if I could apply this flexibility to the external PHP application and html nugget that would be perfect!
Re: How To Display Plugins On The Index Page Only
Posted: Fri Sep 24, 2010 1:24 am
by Maccsta
ny solution to this problem?
Re: How To Display Plugins On The Index Page Only
Posted: Fri Sep 24, 2010 3:31 am
by Don Chambers
Didn't Garvin already answer this
here?