diff --git a/attachments_for_content/attachments_for_content.php b/attachments_for_content/attachments_for_content.php index 56fe76a1..f7c40c74 100644 --- a/attachments_for_content/attachments_for_content.php +++ b/attachments_for_content/attachments_for_content.php @@ -162,11 +162,6 @@ protected function getTextFieldName(&$row, $parent_entity) { $text_field_name = 'text'; } - - if (($view == 'article') AND ($layout == 'blog') AND ($parent_entity == 'article')) - { - $text_field_name = 'text'; - } return $text_field_name; } diff --git a/attachments_plugin/attachments.php b/attachments_plugin/attachments.php index 4c81cb08..a39c05f3 100644 --- a/attachments_plugin/attachments.php +++ b/attachments_plugin/attachments.php @@ -130,14 +130,14 @@ public function onContentPrepare(Event $event) if ( $parent_type == 'com_content' ) { if (in_array($parent_entity, Array('featured', 'article'))) { - $parent_entity = 'article'; - } + return false; + } if ($parent_entity == 'category.title') { // Do not add attachments to category titles (Joomla 3 only) return false; - } + } - + $parent_entity = 'category'; } $input = $this->app->getInput();