CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Upgrading CiviCRM (Moderator: Deepak Srivastava) »
  • BUG: Joomla 2.5.x /4.3.x/4.4.x civicrm.css stylesheet link missing.
Pages: [1]

Author Topic: BUG: Joomla 2.5.x /4.3.x/4.4.x civicrm.css stylesheet link missing.  (Read 1310 times)

Generic

  • I post occasionally
  • **
  • Posts: 87
  • Karma: 4
  • CiviCRM version: 4.2.*, 4.5.*
  • CMS version: Joomla 2.5.*
  • MySQL version: 5.1.*
  • PHP version: 5.3.*
BUG: Joomla 2.5.x /4.3.x/4.4.x civicrm.css stylesheet link missing.
October 22, 2013, 02:36:52 pm
I have upgrade from 4.2.9 to 4.3.7.
Before I did this I update Joomla from 2.5.11 to 2.5.14

The issue I have is that there is no link to the civicrm.css style sheet.

To get it to load I edited /administrator/components/com_civicrm/civicrm/CRM/Utils/System/Joomla.php

Code: [Select]
  public function addStyleUrl($url, $region) {
    if ($region == 'html-header') {
      $document = JFactory::getDocument();
      $document->addStyleSheet($url);
      $document->addStyleSheet("/administrator/components/com_civicrm/civicrm/css/civicrm.css");
      return TRUE;
    }
    return FALSE;
  }

Has anyone else experienced this?
Has anyone got the same setup working as mine?


I have made sure all the caches and templates_c is cleared.
I cleared my browser cache.
I ran session reset.

I've never had stylsheet issues after an upgrade before that a cache/templates_c clear hasn't fixed.
« Last Edit: October 31, 2013, 08:57:58 am by Generic »
Document everything!
Zim-Wiki

Generic

  • I post occasionally
  • **
  • Posts: 87
  • Karma: 4
  • CiviCRM version: 4.2.*, 4.5.*
  • CMS version: Joomla 2.5.*
  • MySQL version: 5.1.*
  • PHP version: 5.3.*
Re: Joomla 2.5.14 & 4.3.7 civicrm.css stylesheet link missing.
October 31, 2013, 07:10:55 am
I still have this issue after restoring civicrm back to 4.2.9 and then upgrading to 4.4.0

Can anyone please confirm they have Joomla 2.5.14 loading the civicrm.css stylesheet?
Document everything!
Zim-Wiki

Generic

  • I post occasionally
  • **
  • Posts: 87
  • Karma: 4
  • CiviCRM version: 4.2.*, 4.5.*
  • CMS version: Joomla 2.5.*
  • MySQL version: 5.1.*
  • PHP version: 5.3.*
Re: Joomla 2.5.14 & 4.3.7 civicrm.css stylesheet link missing.
October 31, 2013, 08:46:43 am
Okay I've found the bug.

If the 'Custom CiviCRM CSS URL' field is populated it breaks the css loading.

PLEASE SEE SCREENSHOT OF THE http://joomla.demo.civicrm.org/administrator/ WHERE I CONFIRMED THIS ISSUE

Document everything!
Zim-Wiki

Generic

  • I post occasionally
  • **
  • Posts: 87
  • Karma: 4
  • CiviCRM version: 4.2.*, 4.5.*
  • CMS version: Joomla 2.5.*
  • MySQL version: 5.1.*
  • PHP version: 5.3.*
Re: Joomla 2.5.14 & 4.3.7 civicrm.css stylesheet link missing.
October 31, 2013, 08:54:36 am
http://issues.civicrm.org/jira/browse/CRM-13688
Document everything!
Zim-Wiki

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: BUG: Joomla 2.5.x /4.3.x/4.4.x civicrm.css stylesheet link missing.
October 31, 2013, 09:04:50 am

The assumption is the custom css file will provide a similar level of functionality as civicrm.css, i.e. the custom css file is used instead of civicrm.css

on the joomla demo, u've set it to point to a non-existent css and hence the issue

is this correct?

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Generic

  • I post occasionally
  • **
  • Posts: 87
  • Karma: 4
  • CiviCRM version: 4.2.*, 4.5.*
  • CMS version: Joomla 2.5.*
  • MySQL version: 5.1.*
  • PHP version: 5.3.*
Re: BUG: Joomla 2.5.x /4.3.x/4.4.x civicrm.css stylesheet link missing.
October 31, 2013, 09:47:15 am
Ever since I've used CiviCRM I have had an override stylesheet which only contained the override styles not a copy of the whole civicrm.css. This method allows the civicrm.css to still be upgraded.

Having a link in 'Custom CiviCRM CSS URL' field whether valid or not now prevents the civicrm.css and extra.css loading.
I can't believe this was intended so I assumed it was a bug.

I can't see why 4.3 and above have now prevented the 'Custom CiviCRM CSS URL' from working this way, provided the custom stylesheet is loaded after the civicrm.css it would make no difference whether one, none or all the styles are overridden and it would still allow new styles or fixes to the civicrm.css primary.

I'm sure I'm not going to be the only css developer caught out by this change.
Document everything!
Zim-Wiki

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: BUG: Joomla 2.5.x /4.3.x/4.4.x civicrm.css stylesheet link missing.
October 31, 2013, 11:46:06 am
It seems the problem was that drupal and joomla were behaving differently prior to 4.3. In drupal, civicrm.css would not load if a custom url was specified, and in joomla it would :P
In 4.3 we consolidated the code into one place, so now at least it's consistent.
I think the solution to this mess is to add a checkbox that lets you enable/disable core civicrm.css - to give you independent control over whether that file is loaded, decoupled from anything else.
I'll work on that for 4.4.1 or 4.4.2
Try asking your question on the new CiviCRM help site.

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: BUG: Joomla 2.5.x /4.3.x/4.4.x civicrm.css stylesheet link missing.
November 01, 2013, 02:54:30 pm
http://issues.civicrm.org/jira/browse/CRM-12578
Try asking your question on the new CiviCRM help site.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Upgrading CiviCRM (Moderator: Deepak Srivastava) »
  • BUG: Joomla 2.5.x /4.3.x/4.4.x civicrm.css stylesheet link missing.

This forum was archived on 2017-11-26.