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
(I hope this isn't explained somewhere else. I did search for it...)
I'd like to add an Adobe typekit font to my Backlight page. Where would I save the script it invokes?
Thanks as always,
Darrell Leland
"Never go creeping around old castles at night; you may find what you're looking for."
- Grimsley
Offline
you can add scripts using the phplugin ttg_scripts hook
http://backlight.theturninggate.net/doc … tg_scripts
Rod
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site
Offline
Thanks Rod. I'll work on it and holler if I have questions.
"Never go creeping around old castles at night; you may find what you're looking for."
- Grimsley
Offline
OK, I'm mostly there. Here's what I have so far:
<?php
function ttg_user_load( $style, $path ) {
$g_tsvrl = explode( ' ', $style ); // Extract gallery type
define ( 'G_STYLE', strtoupper($g_tsvrl[1]) ); // and set global for later
$g_path = str_ireplace('\\','/',$path); // change \ to /
$chunks = explode('/',$g_path); // and put into array
define ( 'G_PATH', strtoupper($chunks[count($chunks)-2]) ); // gallery folder name is second to last
//define ( 'TTG_SITE', ''); // set new site root for navigation, resources, etc.
}
function ttg_scripts( $style, $path ) {
echo '
<script>var __adobewebfontsappname__="dreamweaver"</script>
<script src="http://use.edgefonts.net/metamorphous:n4:default.js" type="text/javascript"></script>
';
return false;
} // END
?>
Clearly I need to change the adobewebfontsappname from Dreamweaver. To what? Backlight? Would that make the Metamorphous font show up in the font selector in Backlight? In the normal HTML, Dreamweaver invokes the font like this:
<body style="font-family: metamorphous; font-style: normal; font-weight: 400;">
</body>
Would that be required somewhere else? In a css file?
"Never go creeping around old castles at night; you may find what you're looking for."
- Grimsley
Offline
I don't think the font will show up in Baklight's font selector. You can try entering it in the Prepend Font-family w/ field.
I don't know that you have to change the adobewebfonsappname at all. If it's "dreamweaver" just try adding "dreamweaver" (without the quotes) to the Prepend field.
Rod
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site
Offline
I put "metamorphous" in the Prepend field and it worked!
Thanks again Rod, I've learned a lot from you.
Darrell Leland
"Never go creeping around old castles at night; you may find what you're looking for."
- Grimsley
Offline
Pages: 1