TinyPortal

Development => Support => Topic started by: lebisol on October 18, 2007, 06:51:37 AM

Title: Custom 'Panel Page' - additonal variable
Post by: lebisol on October 18, 2007, 06:51:37 AM
Hello php gurus,
Perhaps you can help a code newbie.
I was wondering how to go about providing a setting/variable in TP admin--> Panels page where user can enter value?
Ideally I would like to use an additional panel setting called "logo" where user/admin can specify how big of a logo (or area where logo goes) they will be inserting.
In essence being able to use:
if($context['TPortal']['logo_area'])  then ....

Why?lol you ask if they can just inset the logo and logo will 'expand' the object (cell,div) to its size.
Well, with a small HTML trick we would be able to provide user to choose their 'padding' around the logo wihout using css or doing anything with code for that matter
This way, there will be no need to make a large logos with transparency just to accommodate design feel.
But I lack php and TP structure knowledge....
Many thanks!
Title: Re: Custom 'Panel Page' - additonal variable
Post by: IchBin on October 18, 2007, 01:53:32 PM
Well, I think if you're going to want to give users this setting you're going to have to add it to the Profile template. If you take a look at some profile mods you'll see how they add the fields and stuff. Haven't done any profile stuff myself.
Title: Re: Custom 'Panel Page' - additonal variable
Post by: lebisol on October 18, 2007, 04:50:31 PM
Oh when I said user...I meant "admin" ...hmmm 'users of template'.
Maybe too much work for something that can just be fixed with "change this in your template" kind of an answer.
Thanks IchBin!
Title: Re: Custom 'Panel Page' - additonal variable
Post by: IchBin on October 18, 2007, 04:59:13 PM
Well if you want to add it to a template you can look at some of Blocs themes. The way he has added the support for other mods will show you exactly how to add the configuration for admins.
Title: Re: Custom 'Panel Page' - additonal variable
Post by: lebisol on October 18, 2007, 05:08:11 PM
cool, I will look arround through his designs. Not a big deal, I noticed that StromLrd had simmilar concept of expansion in his XD series. If he re-surfaces again I will chat will him too.
Thanks IchBin!
Title: Re: Custom 'Panel Page' - additonal variable
Post by: IchBin on October 18, 2007, 05:40:25 PM
He got his concept from Bloc. :) Bloc is the inspiration around here as you'll come to find out. lol
Title: Re: Custom 'Panel Page' - additonal variable
Post by: lebisol on October 18, 2007, 05:58:03 PM
heheh I can imagine...all good...I am learning and experimenting...some ideas are far fetched as you got to see by my posts. LOL.
Thanks! ;)