[Pro] Include external CSS

Hi,

I’m trying to build a gallery into my website using JavaScript with jQuery and Galleria. Now I can include both jQuery and Galleria using an external JavaScript action, and I used a third script to call the Galleria itself (see the “Usage” section on the Galleria website).

However, there’s a CSS file that Galleria requires as well, and I can’t quite figure out how to include that CSS file into my page. I also thought about adding the tags by hand, but that didn’t quite work either.

Does anybody know how to handle the CSS in this case?

Thanks heaps!
Jens


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Basically you need to add a link to the external CSS file in the Head section of your page.

Go to the Page menu and select HTML Markup.

Choose After from the Insert list choices.

Paste the following code into the edit box:

Just change the mystylesheet.css reference to the actual name of your stylesheet. Then place your stylesheet in the CSS directory in the site folder that Freeway creates.


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Or use the External Stylesheet Action to attach it. ESS-Use External Style Sheet - ActionsForge

Walter

On Mar 7, 2010, at 11:19 PM, chuckamuck wrote:

Basically you need to add a link to the external CSS file in the
Head section of your page.

Go to the Page menu and select HTML Markup.

Choose After from the Insert list choices.

Paste the following code into the edit box:

Just change the mystylesheet.css reference to the actual name of
your stylesheet. Then place your stylesheet in the CSS directory in
the site folder that Freeway creates.


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Thanks heaps, both suggestions worked!

Next question though: how do I now use the stylesheet in my HTML element? I mean, in order to invoke the galleria, I need to add an unordered list of images using the “.galleria” style. For HTML elements, I can refer to existing styles or add individual ones, but then how do I refer to a style I’ve loaded from an external source?

Jens


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

If you create a dummy style in Freeway with the same selector as your
external sheet, you can apply that (it won’t appear to do anything in
the layout, but you will see it in the preview).

This trick will only work if the classname is meant to be added to the
list, not the individual items in it. Open the New Style dialog. Enter
ul in the Tag field. Then tab into the Name field and enter galleria
(without the leading dot). Now add one attribute to your style through
the Extended system – use cursor:default or something else completely
inconsequential. You have to add something or the style won’t publish.

Now you can select your list in Freeway and apply the style to it as a
“marker” for what the external stylesheet will do.

Walter

On Mar 8, 2010, at 10:50 AM, _savage wrote:

Thanks heaps, both suggestions worked!

Next question though: how do I now use the stylesheet in my HTML
element? I mean, in order to invoke the galleria, I need to add an
unordered list of images using the “.galleria” style. For HTML
elements, I can refer to existing styles or add individual ones, but
then how do I refer to a style I’ve loaded from an external source?

Jens


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options