summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAngie Byron <webchick@24967.no-reply.drupal.org>2010-11-20 09:46:22 +0000
committerAngie Byron <webchick@24967.no-reply.drupal.org>2010-11-20 09:46:22 +0000
commitd35abf8f711fa2afc8106f2227c537f415a3fe0c (patch)
tree917b954a6dd1934d87544fc72b06321b83f6e398
parented4b74024a7da131d38d973ee5688a950adaf6db (diff)
downloadbrdo-d35abf8f711fa2afc8106f2227c537f415a3fe0c.tar.gz
brdo-d35abf8f711fa2afc8106f2227c537f415a3fe0c.tar.bz2
#880368 by tstoeckler, jhodgdon: Fixed Document how to load external files with #attached
-rw-r--r--includes/common.inc9
1 files changed, 9 insertions, 0 deletions
diff --git a/includes/common.inc b/includes/common.inc
index ce0efcf4f..9b18292f6 100644
--- a/includes/common.inc
+++ b/includes/common.inc
@@ -4174,6 +4174,15 @@ function drupal_get_js($scope = 'header', $javascript = NULL, $skip_alter = FALS
* );
* @endcode
*
+ * External 'js' and 'css' files can also be loaded. For example:
+ * @code
+ * $build['#attached']['js'] = array(
+ * 'http://code.jquery.com/jquery-1.4.2.min.js' => array(
+ * 'type' => 'external',
+ * ),
+ * );
+ * @endcode
+ *
* @param $elements
* The structured array describing the data being rendered.
* @param $group