evolve_print_fonts

The evolve evolve print fonts function.

Description

evolve_print_fonts( (string) $name, $css_class, (string) $additional_css = '', (string) $additional_color_css_class = '', (string) $imp = '' ); 

Parameters (5)

0. $name (string)
The name.
1. $css_class
The css class.
2. $additional_css — Optional. (string) => ''
The additional css.
3. $additional_color_css_class — Optional. (string) => ''
The additional color css class.
4. $imp — Optional. (string) => ''
The imp.

Usage

  1. if ( !function_exists( 'evolve_print_fonts' ) ) { 
  2. require_once '/library/functions/basic-functions.php'; 
  3.  
  4. // The name. 
  5. $name = ''; 
  6.  
  7. // The css class. 
  8. $css_class = null; 
  9.  
  10. // The additional css. 
  11. $additional_css = ''; 
  12.  
  13. // The additional color css class. 
  14. $additional_color_css_class = ''; 
  15.  
  16. // The imp. 
  17. $imp = ''; 
  18.  
  19. // NOTICE! Understand what this does before running. 
  20. $result = evolve_print_fonts($name, $css_class, $additional_css, $additional_color_css_class, $imp); 
  21.  

Defined (1)

The function is defined in the following location(s).

/library/functions/basic-functions.php  
  1. function evolve_print_fonts($name, $css_class, $additional_css = '', $additional_color_css_class = '', $imp = '') { 
  2. global $evl_options; 
  3. $options = $evl_options; 
  4. $css = ''; 
  5. $font_size = ''; 
  6. $font_family = ''; 
  7. $font_style = ''; 
  8. $font_weight = ''; 
  9. $color = ''; 
  10. if ($options[$name]['font-size'] != '') { 
  11. $font_size = $options[$name]['font-size']; 
  12. $css .= "$css_class{font-size:" . $font_size . " " . $imp . ";}"; 
  13. if ($options[$name]['font-family'] != '') { 
  14. $font_family = $options[$name]['font-family']; 
  15. $css .= "$css_class{font-family:" . $font_family . ";}"; 
  16. if (isset($options[$name]['font-style']) && $options[$name]['font-style'] != '') { 
  17. $font_style = $options[$name]['font-style']; 
  18. $css .= "$css_class{font-style:" . $font_style . ";}"; 
  19. if (isset($options[$name]['font-weight']) && $options[$name]['font-weight'] != '') { 
  20. $font_weight = $options[$name]['font-weight']; 
  21. $css .= "$css_class{font-weight:" . $font_weight . ";}"; 
  22. if (isset($options[$name]['color']) && $options[$name]['color'] != '') { 
  23. $color = $options[$name]['color']; 
  24. $css .= "$css_class{color:" . $color . ";}"; 
  25. if ($additional_css != '') { 
  26. $css .= "$css_class{" . $additional_css . ";}"; 
  27. if ($additional_color_css_class != '') { 
  28. $color = $options[$name]['color']; 
  29. $css .= "$additional_color_css_class{color:" . $color . ";}"; 
  30.  
  31. return $css;