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

Diff of /contributions/modules/jqp/jqp.module

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

revision 1.1, Tue Sep 30 20:17:12 2008 UTC revision 1.2, Wed Oct 1 01:19:20 2008 UTC
# Line 68  function jqp_plugin_exists($file_name){ Line 68  function jqp_plugin_exists($file_name){
68   *   *
69   * @return an array where key is file name and value is file path   * @return an array where key is file name and value is file path
70   *   *
71   *   Example: array('color.js' => 'plugins/twolibrary/color.js')   *   Example: array('color.js' => 'sites/all/plugins/twolibrary/color.js')
72   *   *
73   * If there are multiple plugins with the same filename in the directory,   * If there are multiple plugins with the same filename in the directory,
74   *    the LAST file read will be used.   *    the LAST file read will be used.
# Line 81  function jqp_plugin_exists($file_name){ Line 81  function jqp_plugin_exists($file_name){
81  function jqp_scan_dir() {  function jqp_scan_dir() {
82    static $files;    static $files;
83    if (!isset($files)) {    if (!isset($files)) {
84      $files = drupal_system_listing('(\.js$|\.css$)', 'plugins', 'basename', 0);      if ($cache = cache_get('jqp_plugins')) {
85          $files = $cache->data;
86        }
87        else {
88          $files = drupal_system_listing('(\.js$|\.css$)', 'plugins', 'basename', 0);
89          cache_set('jqp_plugins', $files);
90        }
91    }    }
92    return $files;    return $files;
93  }  }

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

  ViewVC Help
Powered by ViewVC 1.1.2