[dev] potential optimizations: static css and javascript

Jan Schneider jan at horde.org
Thu Oct 14 01:16:12 PDT 2004


Zitat von Chuck Hagenbuch <chuck at horde.org>:

> Quoting Jan Schneider <jan at horde.org>:
>
>>> While I like this idea generally, I see some problems that are not easy to
>>> circumvent with static CSS files, namely style sheets that use images,
>>> like:
>>>
>>> $css['body']['background-image'] = "url('" . 
>>> $registry->getParam('graphics',
>>> 'horde') . "/themes/kolab/bg.png')";
>>>
>>> I can't really imagine dropping this design feature. Uh, wait, 
>>> isn't the url
>>> relative to the CSS file?
>>
>> Thinking a bit slow today. Yes, these paths are relative, but the "graphics"
>> directory is configurable. Perhaps we could live with this inconsistency,
>> requiring administrators to change CSS files if they want a different
>> graphics path.
>
> Now I'm confused. :) Isn't the url that's generated in the php code
> above *not*
> relative?

Exactly, but it *can* be made relative, so we no longer need the registry
call for default tarball or cvs installs.

> This is a good point on the css files, though. But I think I agree with
> you that
> we could live with the tradeoff, perhaps adding a generation script that'd
> substitute the path correctly for the .css files.

Jan.

-- 
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/


More information about the dev mailing list