MINOR Removed non-functional "add subsite" link behaviour from LeftAndMain_Subsites.js (was removed way back in 2007, with 8f6db47888)

This commit is contained in:
Ingo Schommer 2011-09-05 17:50:41 +02:00
parent 1697126957
commit d956d31ed4

View File

@ -21,49 +21,6 @@ Behaviour.register({
}
},
'#SubsiteActions a' : {
onclick: function() {
var subsiteName = prompt('Enter the name of the new site','');
if(subsiteName && subsiteName != '') {
var request = new Ajax.Request(this.href + '?Name=' + encodeURIComponent(subsiteName) + '&ajax=1', {
onSuccess: function(response) {
var origSelect = $('SubsitesSelect');
var div = document.createElement('div');
div.innerHTML = response.responseText;
var newSelect = div.firstChild;
while(origSelect.length > 0)
origSelect.remove(0);
for(var j = 0; j < newSelect.length; j++) {
var opt = newSelect.options.item(j).cloneNode(true);
var newOption = document.createElement('option');
/*if(opt.text)
newOption.text = opt.text;*/
if(opt.firstChild)
newOption.text = opt.firstChild.nodeValue;
newOption.value = opt.value;
try {
origSelect.add(newOption, null);
} catch(ex) {
origSelect.add(newOption);
}
}
statusMessage('Created ' + subsiteName, 'good');
},
onFailure: function(response) {
errorMessage('Could not create new subsite', response);
}
});
}
return false;
}
},
// Subsite tab of Group editor
'#Form_EditForm_AccessAllSubsites' : {
initialize: function () {