Community @ The Turning Gate

Support community for TTG plugins and products.

NOTICE

The Turning Gate's Community has moved to a new home, at https://discourse.theturninggate.net.

This forum is now closed, and exists here as a read-only archive.

  • New user registrations are disabled.
  • Users cannot create new topics.
  • Users cannot reply to existing topics.

You are not logged in.

#1 2016-05-05 06:40:08

johnbrks
Member
From: Los Angeles
Registered: 2015-08-14
Posts: 147
Website

transferring CE4 php file and css

It seems i can't just past in my old phplugins file. (that would be a nice how-to post...how to transition the phplugins file).

in understanding the differences with backlight, it looks like:

the CE4 ttg_header in BL is ttg_header_top
and ttg_header_masthead has been divided into ttg_header_masthead_top
is this correct?

Offline

#2 2016-05-05 07:45:06

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: transferring CE4 php file and css

New structure so the old hooks won't work (for the most part)

there are ttg_header_top and ttg_header_bottom as well as ttg_masthead_top and ttg_masthead_bottom

I haven't played with the new hooks yet, but it stands to reason the _top will insert your code in the top, before the rest of the standard code and _bottom will insert after the standard code has run.
Probably use _top and return false; to replace the content.

What you'll probably have to do is copy html or whatever other code you're using and insert it into one of the new hooks, depending on where you want things to appear.

I'll try to set up a page on my test site that shows where the hooks appear on the pages.


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#3 2016-05-05 08:00:16

johnbrks
Member
From: Los Angeles
Registered: 2015-08-14
Posts: 147
Website

Re: transferring CE4 php file and css

awesome.  that would be helpful.

even though there are changes, this interface is much easier than the LR-based one and the website is extremely fast.

Offline

#4 2016-05-05 08:16:09

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: transferring CE4 php file and css

Yep, no more needing to find server paths.


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#5 2016-05-05 09:54:51

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: transferring CE4 php file and css

Here you go. This is a standard Backlight page showing the locations of the available hooks:
http://backlight.barbeephoto.com/hook-locations/


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#6 2016-05-05 10:04:36

johnbrks
Member
From: Los Angeles
Registered: 2015-08-14
Posts: 147
Website

Re: transferring CE4 php file and css

very helpful. thank you.

Offline

#7 2016-05-05 10:46:41

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: transferring CE4 php file and css

And depending on the template setup and masthead location, some of these might move around the page a bit. I'll probably apply this phplugins file to some other page templates just to see.


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#8 2016-05-05 11:46:01

Matthew
Administrator
From: San Francisco, CA
Registered: 2012-09-24
Posts: 5,795
Website

Re: transferring CE4 php file and css

If you open up the phplugins files -- there's two to begin with, phplugins-sample.php and theturninggate.php, the latter of which is our logo for the masthead -- you can see descriptions of the available hooks in the large commented section of the file.

The separation of the header and masthead hooks are for these reasons:

The header, even if empty, is always above the columned content area.

The masthead may be within the header, but does not have to be; it can be in either of the trays, in the content column, or disable completely; this depends on your template configuration.

Likewise, the footer is always beneath the columned content area, if even empty.

So if you disable all content from the header or footer sections, those sections still exist, and you can still inject custom content into them via PHPlugins.


Matt

The Turning Gate, http://theturninggate.net

Offline

#9 2016-05-05 11:46:33

Daniel Leu
Moderator
Registered: 2012-10-11
Posts: 1,624
Website

Re: transferring CE4 php file and css

That's a nifty file to have ;-)


Daniel Leu | Photography   
DanielLeu.com
My digital playground (eg, Backlight tips&tricks): lab.DanielLeu.com

Offline

#10 2016-05-05 11:59:35

Matthew
Administrator
From: San Francisco, CA
Registered: 2012-09-24
Posts: 5,795
Website

Re: transferring CE4 php file and css

dl wrote:

That's a nifty file to have ;-)

Which? Or both?

I've included The Turning Gate's modifications in the distributable for two reasons:

1. I'm lazy, and having it a part of the core package means I don't have to keep track of it separately.
2. I reckon it makes for a nice demonstration for how to use PHPlugins and custom CSS.

For the latest version of The Turning Gate, I'm not using a graphic for our logo; it's entirely HTML and CSS. So phplugins/theturninggate.php has the HTML, and css/theturninggate.css is exactly what you'd expect.

When I have a bit of time for frivolity, I might create a disco version of the logo ... The Disco Gate ...


Matt

The Turning Gate, http://theturninggate.net

Offline

#11 2016-05-05 12:05:15

Matthew
Administrator
From: San Francisco, CA
Registered: 2012-09-24
Posts: 5,795
Website

Re: transferring CE4 php file and css

Oh, one other thing. You might also notice that the navigation hook appears in two places -- in the navigation bar below the header, and in the tray. Navigation is a <ul> list with a few special classes sprinkled on; you should inspect the source to get these. Typically, the header nav displays on desktop and the tray nav on mobile. The hook replaces both, so that your menu is consistent in both places. Those special classes provide contextual visibility. This is something I will likely need to write a tutorial about.


Matt

The Turning Gate, http://theturninggate.net

Offline

#12 2016-05-05 16:10:22

Daniel Leu
Moderator
Registered: 2012-10-11
Posts: 1,624
Website

Re: transferring CE4 php file and css

Which? Or both?

Matt, my comment was related to Rod's "phplugins file". Your comment wasn't posted yet when I looked at the threat. Sorry for the confusion.


Daniel Leu | Photography   
DanielLeu.com
My digital playground (eg, Backlight tips&tricks): lab.DanielLeu.com

Offline

#13 2016-05-05 20:32:14

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: transferring CE4 php file and css

dl wrote:

That's a nifty file to have ;-)

I'll post it in the Tips and Tricks forum


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

Board footer

Powered by FluxBB