Welcome, Guest. Please login or register.
Did you miss your activation email?
May 26, 2012, 04:56:50 AM

Login with username, password and session length
Search:     Advanced search
Wollen Sie dem WebsiteBaker Team beitreten?
Nähere Informationen finden Sie unter hier und auf unserer neuen Webseite.
155533 Posts in 21713 Topics by 7739 Members
Latest Member: audillino
* Home Help Search Login Register
Pages: [1]   Go Down
Print
Author Topic: Admin Template Guidelines?  (Read 476 times)
psmith

Offline Offline

Posts: 13


« on: February 27, 2010, 05:23:00 PM »

Just trying to find guidelines for building your own admin template. I don't see anything, have I missed it?

Thanks,
Phil
Logged
doc
Guest
« Reply #1 on: February 27, 2010, 05:49:53 PM »

Hi,

there are now guidelines for creating backend themes (admin templates).

So copy an existing one and adapt the variables template_folder and template_name in the info.php file of the theme. After reloading the Add-ons via the WB backend you can select the new theme from the backend. Then it is up to you to adapt colors, CSS or ...

Doc
« Last Edit: February 27, 2010, 06:01:29 PM by doc » Logged
psmith

Offline Offline

Posts: 13


« Reply #2 on: February 27, 2010, 07:04:01 PM »

Ok, that's the easy part.

Can you explain how the /templates/ subfolder works? In it there are quite a few .htt files.  What role do the .htt files play? Do they overwrite the code in each of the admin directory?

For example, does /templates/pages.htt overwrite the code found in /admin/pages/index.php?
Logged
doc
Guest
« Reply #3 on: February 27, 2010, 07:10:57 PM »

Hi,

the /templates/*.htt files contain the HTML code and placeholder like {PLACEHOLDER}. The placeholder will be replaced with content by PHP code loacted in the WB /admin folder. Most templates files can be linked to their corresponding PHP file (/admin/xxx/yyy.php) via it´s file name.

Example:
The template file templates/pages_modify.htt is invoked from the WB admin file /admin/pages/modify.php.
You will find the include statements in the corresponding PHP files. They should look like similar to:
Code:
$template->set_file('page', 'pages_modify.htt');

Good luck.

Doc
« Last Edit: February 27, 2010, 07:32:07 PM by doc » Logged
psmith

Offline Offline

Posts: 13


« Reply #4 on: February 27, 2010, 08:32:26 PM »

Thank you for the help.. I am having some success now in porting over a backend template, but now stuck at one more point on the pages section. See attached screenshot for reference.

Is there a way to modify the template for the data grid of the page listings?  Or do modifications to this have to happen in the /admin/pages/index.php file?

Of course, I don't really want to get into modifying the core files if at all possible!

Thanks
Phil
Logged
Stefek
WebsiteBaker Org e.V.

Offline Offline

Posts: 4884



« Reply #5 on: February 28, 2010, 12:34:19 AM »

Hello,

no, there is no way to style the page tree the way you want, unfortunately.
Not right know.

I hope it will one day, but for now it's not the case.

Regards,
Stefko
Logged

"In a time of universal deceit, telling the truth becomes a revolutionary act."
- George Orwell, Nineteen eighty-four (1984)
Pages: [1]   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!