ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Include a stylesheet from another site [css and MSM]

June 16, 2009 6:58am

Subscribe [2]
  • #1 / Jun 16, 2009 6:58am

    Michael Hay

    65 posts

    Hello,

    I run several sites using MSM off the domains
    site1.mydomain.com
    site2.mydomain.com
    site3.mydomain.com

    I’d like to be able to include a stylesheet from site 3 on site 1. The tricky part is I need to be able to reference the site3 stylesheet from the site1 domain (because this domain is being used as a cdn).

    So I was hoping I could do something like

    <link rel='stylesheet' type='text/css' media='all' href='site1.mydomain.com/index.php/css=/site3shortname/templategroup/csstemplatename/' />

    Any ideas?

  • #2 / Jun 16, 2009 8:08am

    Ingmar

    29245 posts

    Just use an absolute href=, http://site1.example.com/index.php/css/stylesheet, hardcoding it as you would with any website.

  • #3 / Jun 16, 2009 8:18am

    Michael Hay

    65 posts

    Just use an absolute href=, http://site1.example.com/index.php/css/stylesheet, hardcoding it as you would with any website.

    Surely that will only work if “stylesheet” is a template in site1 (within the “css” template group). If stylesheet is a template in site3, how can I reference it?

  • #4 / Jun 16, 2009 8:22am

    Ingmar

    29245 posts

    Don’t all of your site have unique urls? Why, just use use site3’s URL.

  • #5 / Jun 16, 2009 9:43am

    Michael Hay

    65 posts

    The sites do all have unique urls, however because site1 is mapped to our cdn any content we call from there is cached and served from the cdn.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases