TinyPortal

Development => Support => Topic started by: dimdom on September 14, 2008, 12:55:36 PM

Title: Hardcoded change
Post by: dimdom on September 14, 2008, 12:55:36 PM
Is there a way to remove left and right TP panels from a mods template php by altering its code?

Lets say for example that i dont want these panels to be shown in SMF Gallery page. And that i dont have a way to do it other than changing the code of SMF Gallery php files.

Is it possible to achive that?

The above is just an example of what I would like to do.

Thank you.
Title: Re: Hardcoded change
Post by: JPDeni on September 14, 2008, 01:11:08 PM
I don't think so. The code for the panels isn't in the mod, it's in the TP files. You probably could hard-code an exception into the TP files.
Title: Re: Hardcoded change
Post by: G6Cad on September 14, 2008, 01:22:15 PM
In the sourcefiles for the mod ( only for TP V098 ) add in directly under the globalstatment that the mod uses

tp_hidebars();

For TP v1.0.5, you can hide the panels where ever you like in the tp settings by just yping in the action the mod uses.
Title: Re: Hardcoded change
Post by: Ken. on September 14, 2008, 01:40:27 PM
Please read the Posting Guidelines.html (http://www.tinyportal.net/index.php/topic,581)

I know... you've seen that before.  :)
But in this case there is a very easy fix for your issue if you are running TP1.x.

EDIT: Ya beat me G6.  :up:
Title: Re: Hardcoded change
Post by: dimdom on September 14, 2008, 02:21:23 PM
QuoteIn the sourcefiles for the mod ( only for TP V098 ) add in directly under the globalstatment that the mod uses

That is my issue G6. In what file should I add this code?

I would like to apply it in Blog Community mod. http://custom.simplemachines.org/mods/index.php?mod=1209

I am not a php expert so any further help would be enormously appreciated. :)
Title: Re: Hardcoded change
Post by: G6Cad on September 14, 2008, 02:24:00 PM
Allready answerd that in my first reply.
Under the first global statment in the source file that the mod uses.

You have to check the mods XML file and see what code or and files it adds to the source directory. If it holds it's own source file, then it.s in that file, but if it alter any other source file instead of having it's own, you need to add the code to that file instead.

The best would be to ask the mod author for help on that. we provided the code you hide the panels with, now it's up to them to help you find out where to put it.