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.
You are not logged in.
Pages: 1
Hi There!
I#m working on a Site update based on CE4 Pages and i want to implement some Google Fonts. but when I add the Google Font Code to the Phplugins.php as described in the documentation my site appears empty, no Navigation no nothing, plain white.
After removing the Goggle Font line from the phplugins.php it works just fine. Phplugins hook seem to work as i get the red background from the custom css, so thats fine to.
Here is the code from the phplugins.php I. trying to use:
// CUSTOM STYLESHEET
// This function implements a custom stylesheet from which users may provide additional page styling or override existing styling set by the plugin
// Edit the custom.css file in /phplugins/css/ to define styles
// Serves as an example of a function being applied globally
function ttg_head_end( $style, $path ) {
echo '
<link href='http://fonts.googleapis.com/css?family=Lobster' rel='stylesheet' type='text/css'>
<link rel="stylesheet" href="/phplugins/css/custom.css" />
';
} // END
Any Idea whats goin on here?
i'm not a programmer, its ok to copy and paste a few lines of code but when somethings failing I'm pretty much done. So any advise would be very welcome.
thanks a lot,
cheers
hans
Offline
You have to escape the single quotes inside the echo '...':
// CUSTOM STYLESHEET
// This function implements a custom stylesheet from which users may provide additional page styling or override existing styling set by the plugin
// Edit the custom.css file in /phplugins/css/ to define styles
// Serves as an example of a function being applied globally
function ttg_head_end( $style, $path ) {
echo '
<link href=\'http://fonts.googleapis.com/css?family=Lobster\' rel=\'stylesheet\' type=\'text/css\'>
<link rel="stylesheet" href="/phplugins/css/custom.css" />
';
} // END
Daniel Leu | Photography
DanielLeu.com
My digital playground (eg, Backlight tips&tricks): lab.DanielLeu.com
Offline
Hurray! Thats it.
took a while till i figured out whats the difference between our code is.
Would be great if this hint would have made it into the documentation though.
Thank you very much for this help, You Just made my day
cheers
hans
Offline
Pages: 1