summaryrefslogtreecommitdiff
path: root/modules/node
diff options
context:
space:
mode:
Diffstat (limited to 'modules/node')
-rw-r--r--modules/node/content_types.js8
-rw-r--r--modules/node/node.js12
2 files changed, 10 insertions, 10 deletions
diff --git a/modules/node/content_types.js b/modules/node/content_types.js
index 8b32ae8ea..bee78bc83 100644
--- a/modules/node/content_types.js
+++ b/modules/node/content_types.js
@@ -1,15 +1,15 @@
// $Id$
-(function($) {
+(function ($) {
Drupal.behaviors.contentTypes = {
- attach: function() {
+ attach: function () {
if ($('#edit-type').val() == $('#edit-name').val().toLowerCase().replace(/[^a-z0-9]+/g, '_').replace(/_+/g, '_') || $('#edit-type').val() == '') {
$('#edit-type-wrapper').hide();
- $('#edit-name').keyup(function() {
+ $('#edit-name').keyup(function () {
var machine = $(this).val().toLowerCase().replace(/[^a-z0-9]+/g, '_').replace(/_+/g, '_');
if (machine != '_' && machine != '') {
$('#edit-type').val(machine);
- $('#node-type-name-suffix').empty().append(' Machine name: ' + machine + ' [').append($('<a href="#">' + Drupal.t('Edit') + '</a>').click(function() {
+ $('#node-type-name-suffix').empty().append(' Machine name: ' + machine + ' [').append($('<a href="#">' + Drupal.t('Edit') + '</a>').click(function () {
$('#edit-type-wrapper').show();
$('#node-type-name-suffix').hide();
$('#edit-name').unbind('keyup');
diff --git a/modules/node/node.js b/modules/node/node.js
index 59647b34e..4a0c49d63 100644
--- a/modules/node/node.js
+++ b/modules/node/node.js
@@ -1,26 +1,26 @@
// $Id$
-(function($) {
+(function ($) {
Drupal.behaviors.nodeFieldsetSummaries = {
- attach: function(context) {
- $('fieldset#edit-revision-information', context).setSummary(function(context) {
+ attach: function (context) {
+ $('fieldset#edit-revision-information', context).setSummary(function (context) {
return $('#edit-revision', context).is(':checked') ?
Drupal.t('New revision') :
Drupal.t('No revision');
});
- $('fieldset#edit-author', context).setSummary(function(context) {
+ $('fieldset#edit-author', context).setSummary(function (context) {
var name = $('#edit-name').val(), date = $('#edit-date').val();
return date ?
Drupal.t('By @name on @date', { '@name': name, '@date': date }) :
Drupal.t('By @name', { '@name': name });
});
- $('fieldset#edit-options', context).setSummary(function(context) {
+ $('fieldset#edit-options', context).setSummary(function (context) {
var vals = [];
- $('input:checked', context).parent().each(function() {
+ $('input:checked', context).parent().each(function () {
vals.push(Drupal.checkPlain($.trim($(this).text())));
});