| Invis1ble | 
			18.09.2010 22:05 | 
		 
		 
		
		 
		
		
			IE ругается, объясните причину   
		
		
		
		Привет всем!!! Есть такой js-скрипт (я в js новичок, поэтому ногами не бейте): 
function ResetEdit()
{
  editForm.empty();
  editableBlock.slideUp(600);
  addCommentForm.load('?page=comment-add' , {}, function()
  {
    jQuery('input#comment-add').click(function()
    {
      RefreshCommentAddForm();
    })
  })
  formHeader.text('ДОБАВЛЕНИЕ КОММЕНТАРИЯ');
}
function RefreshCommentAddForm()
{
  var comment = jQuery('textarea:last').val();
  addCommentForm.load('?page=comment-add&tid=' + tid + '&offset=' + offset, {comment: comment}, function()
  {
    var location = jQuery('input#redirect-location').val();
    if (location != undefined)
      window.location.reload(location);
    else
    {
      jQuery('input#comment-add').click(function()
      {
        RefreshCommentAddForm();
      })
    }
  })
}
function RefreshCommentEditForm()
{
  var edComment = jQuery('textarea#comment').val();
  editForm.load('?page=comment-edit&tid=' + tid + '&offset=' + offset + '&id=' + id, {comment: edComment}, function()
  {
    var location = jQuery('input#redirect-location').val();
    if (location != undefined)
    {
      editableBlock.slideUp(600);
      window.location.reload(location);
    }
    else
    {
      jQuery('input#comment-edit').click(function()
      {
        RefreshCommentEditForm();
      })
    }
  })
}
function RefreshTopicEditForm()
{
  editForm.load('?page=topic-edit&tid=' + tid, {topic_name: jQuery('input#topic-name').val(), topic_description: jQuery('input#topic-description').val(), topic_message: jQuery('textarea#topic-message').val()}, function()
  {
    var location = jQuery('input#redirect-location').val();
    
    if (location != undefined)
    {
      editableBlock.slideUp(600);
      window.location.reload(location);
    }
    else
    {
      jQuery('input#topic-edit').click(function()
      {
        RefreshTopicEditForm();
      })
    }
  })
}
function RefreshMessageEditForm()
{
  editForm.load('?page=topic-edit&tid=' + tid, {topic_message: jQuery('textarea#topic-message').val()}, function()
  {
    var location = jQuery('input#redirect-location').val();
    if (location != undefined)
    {
      editableBlock.slideUp(600);
      window.location.reload(location);
    }
    else
    {
      jQuery('input#topic-edit').click(function()
      {
        RefreshMessageEditForm();
      })
    }
  })
}
jQuery(document).ready(function()
{
  addCommentForm = jQuery('#add-comment-form');
  editableBlock = jQuery('#editableBlock');
  editForm = jQuery('#edit-form');
  formHeader = jQuery('#formHeader');
  tid = jQuery('input#tid').val();
  offset = jQuery('input#offset').val();
  editableBlock.hide();
  addCommentForm.load('?page=comment-add' , {}, function()
  {
    jQuery('input#comment-add').click(function()
    {
      RefreshCommentAddForm();
    })
  })
  jQuery('a.comment-edit').click(function()
  {
    var link = jQuery(this);
    id = link.attr('id');
    var block = link.parent().parent();
    editableBlock.html(
      '<div class="editHeader">редактируемый комментарий | ' +
      '<a class="ResetEdit" onclick="ResetEdit();" href="javascript: void(0);">' +
      'отменить редактирование</a></div>').append(jQuery('#comment-content', block).html());
    editForm.load('?page=comment-edit&id=' + id, {}, function()
    {
      jQuery('input#comment-edit').click(function()
      {
        RefreshCommentEditForm();
      })
    })
    formHeader.text('РЕДАКТИРОВАНИЕ КОММЕНТАРИЯ');
    addCommentForm.empty();
    editableBlock.slideDown(600);
  })
  jQuery('a.comment-delete').click(function(event)
  {
    var responce = confirm('Вы действительно хотите удалить этот комментарий?');
    if (!responce) event.preventDefault();
  })
  jQuery('a.topic-edit').click(function()
  {
    var blockHtml = jQuery('#captionTopicName').html() + '<br />' +
                    jQuery('#captionTopicDescription').html() + '<br />' +
                    jQuery('#topic-message').html();
    editableBlock.html(
      '<div class="editHeader">редактируемая тема | ' +
      '<a class="ResetEdit" onclick="ResetEdit();" href="javascript: void(0);">' +
      'отменить редактирование</a></div>').append(blockHtml);
    editForm.load('?page=topic-edit&tid=' + tid, {}, function()
    {
      jQuery('input#topic-edit').click(function()
      {
        RefreshTopicEditForm();
      })
    });
    formHeader.text('РЕДАКТИРОВАНИЕ ТЕМЫ');
    addCommentForm.empty();
    editableBlock.slideDown(600);
  })
  jQuery('a.topic-delete').click(function()
  {
    var responce = confirm('Вы действительно хотите удалить эту тему?');
    if (!responce) event.preventDefault();
  })
  jQuery('a.message-edit').click(function()
  {
    var blockHtml = jQuery('#topic-message').html();
    editableBlock.html(
      '<div class="editHeader">редактируемое сообщение | ' +
      '<a class="ResetEdit" onclick="ResetEdit();" href="javascript: void(0);">' +
      'отменить редактирование</a></div>').append(blockHtml);
    editForm.load('?page=topic-edit&tid=' + tid, {}, function()
    {
      jQuery('input#topic-edit').click(function()
      {
        RefreshMessageEditForm();
      })
    });
    formHeader.text('РЕДАКТИРОВАНИЕ СООБЩЕНИЯ');
    addCommentForm.empty();
    editableBlock.slideDown(600);
  })
})
В опере и гугл-хроме скрипт работает нормально, IE выдает "Объект не поддерживает это свойство или метод (строка 106, символ 3)". Это он ругается на
 
editableBlock = jQuery('#editableBlock');
Объсните плиз, причину  
	 |