/[drupal]/contributions/modules/css/css.module
ViewVC logotype

Diff of /contributions/modules/css/css.module

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.3.2.4, Fri Dec 26 16:06:02 2008 UTC revision 1.3.2.5, Fri Dec 26 16:34:32 2008 UTC
# Line 1  Line 1 
1  <?php  <?php
2  // $Id: css.module,v 1.3.2.3 2008/12/03 18:36:09 fax8 Exp $  // $Id: css.module,v 1.3.2.4 2008/12/26 16:06:02 fax8 Exp $
3    
4  /**  /**
5   * @file   * @file
# Line 65  function css_form_alter($form_id, &$form Line 65  function css_form_alter($form_id, &$form
65    if (user_access('create css for nodes') && variable_get('css__'.$form['#node']->type, FALSE)) {    if (user_access('create css for nodes') && variable_get('css__'.$form['#node']->type, FALSE)) {
66      if (isset($form['type']) && $form['type']['#value'] .'_node_form' == $form_id) {      if (isset($form['type']) && $form['type']['#value'] .'_node_form' == $form_id) {
67        $node = $form['#node'];        $node = $form['#node'];
68        // _form_form code follows:        // create a fieldset so we can collapse it
69        $form['css_css'] = array(        $form['css_fieldset'] = array(
70            '#type' => 'fieldset',
71            '#title' => t('CSS Rules'),
72            '#collapsible' => TRUE,
73            '#collapsed' => empty($node->css_css), // show uncollapsed if we have some css rule set
74          );
75          $form['css_fieldset']['css_css'] = array(
76            '#type' => 'textarea',            '#type' => 'textarea',
77            '#title' => t('CSS'),            '#title' => t('CSS Rules'),
78            '#default_value' => $node->css_css,            '#default_value' => $node->css_css ? $node->css_css : '',
79            '#cols' => 60,            '#cols' => 60,
80            '#rows' => 10,            '#rows' => 10,
81            '#description' => t('Insert here the css rules for this node. You can use css defined for other nodes using <em>@import "?q=css/get/x";</em> where x is the identification number of the node which contains the css you want to use.'),            '#description' => t('Insert here the css rules for this node. You can use css defined for other nodes using <em>@import "?q=css/get/x";</em> where x is the identification number of the node which contains the css you want to use.'),

Legend:
Removed from v.1.3.2.4  
changed lines
  Added in v.1.3.2.5

  ViewVC Help
Powered by ViewVC 1.1.2