Project

General

Profile

« Previous | Next » 

Revision 4636b248

Added by Andreas Kohlbecker over 11 years ago

fixing layout for IE8 and IE7 (using css3pie and box-sizing-polyfill)

View differences:

7.x/themes/zen_dataportal/theme-settings.php
1 1
<?php
2 2

  
3
define("POLYFILL_TEST_URL", "/polyfills/box-sizing-polyfill/boxsizing.htc");
4

  
3 5
/**
4 6
 * Provides the image names which can be configured in the theme settings to all
5 7
 * theme setting functions.
......
21 23
 *   A keyed array containing the current state of the form.
22 24
 */
23 25
function zen_dataportal_form_system_theme_settings_alter(&$form, &$form_state, $form_id = NULL)  {
26
  global $base_root;
27

  
24 28
  // Work-around for a core bug affecting admin themes. See issue #943212.
25 29
  if (isset($form_id)) {
26 30
    return;
27 31
  }
28 32

  
33
  $path_to_theme = drupal_get_path('theme', 'zen_dataportal');
34

  
35
  // check requirements
36
  $response = drupal_http_request($base_root . POLYFILL_TEST_URL, array("method"=>"HEAD"));
37
  if($response->code != 200){
38
    drupal_set_message('The ' . l('polyfills folder' ,'/polyfills/', array('external'=>TRUE)) .' is not found. The theme will not be rendered correctly in InternetExplorer 8 and 7'
39
        . 'Please read the installation instructions in the ' .l('README', $path_to_theme . '/README.txt') .' of this theme.', 'error');
40
  }
41

  
42

  
29 43
  // will be available in the page.tpl.php
30 44
   $form['zen_dataportal_misc'] = array(
31 45
          '#type' => 'fieldset',
......
62 76

  
63 77
  // TODO : site-name shadow: text-shadow: black 0 10px 20px, black 0 5px
64 78

  
65

  
66
  $path_to_theme = drupal_get_path('theme', 'zen_dataportal');
67 79
  drupal_add_css($path_to_theme . '/js/colorpicker/css/colorpicker.css', 'file');
68 80
  drupal_add_js($path_to_theme. '/js/colorpicker/js/colorpicker.js', 'file');
69 81
  drupal_add_js($path_to_theme . '/js/settings-ui.js', 'file');

Also available in: Unified diff