Moodle  2.2.1
http://www.collinsharper.com
C:/xampp/htdocs/moodle/theme/fusion/lib.php
Go to the documentation of this file.
00001 <?php
00002 function fusion_set_linkcolor($css, $linkcolor) {
00003     $tag = '[[setting:linkcolor]]';
00004     $replacement = $linkcolor;
00005     if (is_null($replacement)) {
00006         $replacement = '#2d83d5';
00007     }
00008     $css = str_replace($tag, $replacement, $css);
00009     
00010 
00011     return $css;
00012 }
00013 
00014 function fusion_set_customcss($css, $customcss) {
00015     $tag = '[[setting:customcss]]';
00016     $replacement = $customcss;
00017     if (is_null($replacement)) {
00018         $replacement = '';
00019     }
00020     $css = str_replace($tag, $replacement, $css);
00021     return $css;
00022 }
00023 
00024 
00025 
00026 
00027 
00028 function fusion_process_css($css, $theme) {
00029        
00030      if (!empty($theme->settings->linkcolor)) {
00031         $linkcolor = $theme->settings->linkcolor;
00032     } else {
00033         $linkcolor = null;
00034     }
00035     $css = fusion_set_linkcolor($css, $linkcolor);
00036 
00037      if (!empty($theme->settings->customcss)) {
00038         $customcss = $theme->settings->customcss;
00039     } else {
00040         $customcss = null;
00041     }
00042     $css = fusion_set_customcss($css, $customcss);
00043     
00044     return $css;
00045     
00046     
00047     
00048 }
00049 
 All Data Structures Namespaces Files Functions Variables Enumerations