Send private message

You must be logged in to send a private message.


No friends yet.

Group membership

  • Beginning Developers

    Beginning Developers

    This space is for newcomers, who wish to build a new plugin or to customize an existing one to their liking


  • Fonzo added a new discussion topic CSS edit Time Theme Pro in the group Beginning Developers
    Hi, i use the Time Theme Pro theme and want to do some extented CSS editing on it.  I always use stylizer 7 for CSS editing, but i cannot find where to put the CSS code after i am done with editing. Stylizer 7 saves a CSS file, put cant...
    • You can do this in 2 ways:

      Method: 1 - If you want to load the css through out the site

      You can add the following code in your start.php file:

      elgg_extend_view('elgg.css', 'path/to/your/custom.css');

      Method 2 - if you want to load the css file in specific pages

      You can add the following code in your start.php file:

      then use this code in the files where you want to load the css
    • Elgg has no single CSS file which all CSS code included. Instead there are several CSS already in core that are providing the CSS stuff in kind of a thematic order (e.g. forms, layouts, buttons, navigation etc.). Additionally, there are separate CSS files for the normal GUI and for the admin pages (not necessarily everything is separatetely defined for the admin pages but only what differs). Then theme plugins and also other plugins can come with their own CSS files that alter the core CSS classes or add new CSS definitions.

      So, it is not much use trying to change the CSS code in total and asking where to put any CSS code you got from some CSS tool. As Rohit explained you could put the CSS code you got into a plugin (e.g. mod/my_plugin/views/default/my_plugin/custom.css) and then use elgg_extend_view to load it. With the same CSS lass names used it will override the previously defined CSS stuff either by Elgg core or another plugin if you place your plugin below the other plugins you want to make changes to in the plugin list.

      But it might be better in the long run if you try to keep the structure of the Elgg viewing system (the files within the views folders) in a consistent manner and instead of trying to change everything with a single file override the view files of Elgg core and other plugins as described at You would have slightly more work to do at the beginning as you would have to search for the CSS files where the classes are defined that you want to change. You could use a grep tool or some other search tool that allows fulltext search in text files to find where the classes names occur. In the long run you would have a consistent theme plugin where you know quite easy which core files (or files of other plugins) you have modified and you can compare the files easier to see what you have changed as it might happen in some later version of Elgg or a plugin that there are changes made in these files and you might have to adjust your own CSS modifications accordingly.