Новости Joomla

0 Пользователей и 1 Гость просматривают эту тему.
  • 4 Ответов
  • 1758 Просмотров
*

runyugin

  • Захожу иногда
  • 56
  • 0 / 0
Как реализовать для определенных, разделов, категорий или отдельных материалов ввывод Заголовока страницы с картинкой?
*

danik.html

  • Живу я здесь
  • 2650
  • 353 / 4
Re: Заголовок страницы с картинкой
« Ответ #1 : 06.10.2010, 19:55:19 »
Интересно для чего, и как вы себе это представляете.
【Мегапак Virtuemart:
 • метатеги (description,keywords)
 • заголовки (title)
 • красивые алиасы (чпу) без тормозов и дублей!
*

runyugin

  • Захожу иногда
  • 56
  • 0 / 0
Re: Заголовок страницы с картинкой
« Ответ #2 : 06.10.2010, 22:51:17 »
Интересно для чего, и как вы себе это представляете.

Представляю так:



МНЕ НУЖНО ЧТОБЫ КАРТИНКА ОТОБРАЖАЛАСЬ
РЯДОМ С НАЗВАНИЕМ РАЗДЕЛА СООТВЕТСТВЕННО
У КАЖДОГО РАЗДЕЛА БЫЛА ИНДИВИДУАЛЬНАЯ КАРТИНКА
« Последнее редактирование: 06.10.2010, 22:55:49 от runyugin »
*

AlterEgo

  • Захожу иногда
  • 170
  • 71 / 5
Re: Заголовок страницы с картинкой
« Ответ #3 : 07.10.2010, 00:15:53 »
1. На странице раздела в менеджере разделов выбрать изображение. Выравнивание установить влево.
2. В настройках пункта меню данного раздела выбрать показ картинки описания.
3. Изменить php-файлы шаблона раздела ../components/com_content/views/section/tmpl
default.php стр. 1-20.
было:
Код
<?php // no direct access
defined('_JEXEC') or die('Restricted access');
$cparams =& JComponentHelper::getParams('com_media');
?>
<?php if ($this->params->get('show_page_title', 1)) : ?>
<div class="componentheading<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>">
<?php echo $this->escape($this->params->get('page_title')); ?>
</div>
<?php endif; ?>
<table width="100%" cellpadding="0" cellspacing="0" border="0" align="center" class="contentpane<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>">
<tr>
<td valign="top" class="contentdescription<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>" colspan="2">
<?php if ($this->params->get('show_description_image') && $this->section->image) : ?>
<img src="<?php echo $this->baseurl . '/' . $cparams->get('image_path'). '/'.  $this->section->image;?>" align="<?php echo $this->section->image_position;?>" hspace="6" alt="<?php echo $this->section->image;?>" />
<?php endif; ?>
<?php if ($this->params->get('show_description') && $this->section->description) : ?>
<?php echo $this->section->description; ?>
<?php endif; ?>
</td>
</tr>
стало:
Код
<?php // no direct access
defined('_JEXEC') or die('Restricted access');
$cparams =& JComponentHelper::getParams('com_media');
?>
<?php if (($this->params->get('show_page_title', 1)) || ($this->params->get('show_description_image') && $this->section->image)) : ?>
<div class="componentheading<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>">
<?php if ($this->params->get('show_description_image') && $this->section->image) : ?>
<img src="<?php echo $this->baseurl . '/' . $cparams->get('image_path'). '/'.  $this->section->image;?>" align="<?php echo $this->section->image_position;?>" hspace="6" alt="<?php echo $this->section->image;?>" />
<?php endif; ?>
<?php echo $this->escape($this->params->get('page_title')); ?>
</div>
<?php endif; ?>
<table width="100%" cellpadding="0" cellspacing="0" border="0" align="center" class="contentpane<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>">
<tr>
<td valign="top" class="contentdescription<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>" colspan="2">
<?php if ($this->params->get('show_description') && $this->section->description) : ?>
<?php echo $this->section->description; ?>
<?php endif; ?>
</td>
</tr>

blog.php стр. 1-24/23.
было:
Код
<?php
defined('_JEXEC') or die('Restricted access');
$cparams =& JComponentHelper::getParams('com_media');
?>
<?php if ($this->params->get('show_page_title')) : ?>
<div class="componentheading<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>">
<?php echo $this->escape($this->params->get('page_title')); ?>
</div>
<?php endif; ?>
<table class="blog<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>" cellpadding="0" cellspacing="0">
<?php if ($this->params->def('show_description', 1) || $this->params->def('show_description_image', 1)) :?>
<tr>
<td valign="top">
<?php if ($this->params->get('show_description_image') && $this->section->image) : ?>
<img src="<?php echo $this->baseurl . '/' . $cparams->get('image_path'). '/'. $this->section->image;?>" align="<?php echo $this->section->image_position;?>" hspace="6" alt="" />
<?php endif; ?>
<?php if ($this->params->get('show_description') && $this->section->description) : ?>
<?php echo $this->section->description; ?>
<?php endif; ?>
<br />
<br />
</td>
</tr>
<?php endif; ?>
стало:
Код
<?php
defined('_JEXEC') or die('Restricted access');
$cparams =& JComponentHelper::getParams('com_media');
?>
<?php if (($this->params->get('show_page_title', 1)) || ($this->params->get('show_description_image') && $this->section->image)) : ?>
<div class="componentheading<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>">
<?php if ($this->params->get('show_description_image') && $this->section->image) : ?>
<img src="<?php echo $this->baseurl . '/' . $cparams->get('image_path'). '/'.  $this->section->image;?>" align="<?php echo $this->section->image_position;?>" hspace="6" alt="<?php echo $this->section->image;?>" />
<?php endif; ?>
<?php echo $this->escape($this->params->get('page_title')); ?>
</div>
<?php endif; ?>
<table class="blog<?php echo $this->escape($this->params->get('pageclass_sfx')); ?>" cellpadding="0" cellspacing="0">
<?php if ($this->params->def('show_description', 1)) :?>
<tr>
<td valign="top">
<?php if ($this->params->get('show_description') && $this->section->description) : ?>
<?php echo $this->section->description; ?>
<?php endif; ?>
<br />
<br />
</td>
</tr>
<?php endif; ?>
4. Поместить измененные файлы в папку templates\текущий_шаблон\html\com_content\section
*

runyugin

  • Захожу иногда
  • 56
  • 0 / 0
Re: Заголовок страницы с картинкой
« Ответ #4 : 07.10.2010, 11:43:17 »
Спасибо!
Чтобы оставить сообщение,
Вам необходимо Войти или Зарегистрироваться
 

Изменить заголовок в шапке сайта

Автор kunsaid

Ответов: 0
Просмотров: 2770
Последний ответ 03.12.2022, 18:34:32
от kunsaid
При прокрутке страницы виджет залезает на меню

Автор coliandra

Ответов: 2
Просмотров: 1381
Последний ответ 27.11.2020, 11:33:58
от coliandra
Div с картинкой и текстом как ссылка

Автор suic

Ответов: 5
Просмотров: 2419
Последний ответ 11.04.2020, 12:47:15
от suic
Где найти HTML каждой страницы сайта

Автор Sirius02030

Ответов: 3
Просмотров: 8580
Последний ответ 08.11.2016, 20:43:22
от Sirius02030
Как вывести заголовок модуля - меню в две строки?

Автор Flame

Ответов: 3
Просмотров: 3916
Последний ответ 03.11.2016, 23:32:55
от pashaiglesias