Перейти к содержимому
Открыть в приложении

Удобный способ просмотра. Узнать больше.

Дизайн и модификация Invision Community

Полноэкранное приложение на главном экране с push-уведомлениями, медалями и многим другим.

Чтобы установить это приложение на iOS и iPadOS
  1. Нажмите иконку «Поделиться» в Safari
  2. Прокрутите меню и нажмите На экран «Домой».
  3. Нажмите Добавить в правом верхнем углу.
Чтобы установить это приложение на Android
  1. Нажмите меню из трёх точек (⋮) в правом верхнем углу браузера.
  2. Нажмите Добавить на главный экран или Установить приложение.
  3. Подтвердите, нажав Установить.
Русский язык для Invision Community 5

Редактирование шаблонов использующих IP.Wrapper

Все пытаюсь добавить 3 колонку для блоков, но пока безуспешно.

 

Админка

 

Templates > Page Template > Select Template XML дает возможность импорта шаблонов.

 

не пойму, как сделать домашнюю страничку используя этот вариант.

 

Есть ли готовые темплейты, которые можно было бы загрузить?

Рекомендованные сообщения

Я просто переделала шаблон, что по умолчанию прилагался, под свой скин форума. И на основе его сделала еще несколько шаблонов страниц.

Других (под другие скины) ничего не делала :)

  • Автор

колонку добавить удалось, чуть позже дам полное описание, но сейчас проблема с версткой....

 

http://a21200.ipsdemo.ipslink.com/index.php?app=ccs&module=pages&section=pages&folder=&id=2

 

<!DOCTYPE html>
   <html>
   <head>
   <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
   <title>Верстка</title>
   <style type="text/css">
   html, body {height:100%;}  
   #wrapper {height:auto !important;height:100%;min-height:100%;}
   #header {height:100px;}
   #container {min-width:800px;} /* указываем минимальную ширину */
   #center {margin:0px 200px 0px 200px;}
   #left {float:left; width:200px;}
   #right {float:right; width:200px;}
   #footer {height:100px;margin-top:-100px;} /* добавляем отступ */
   .clear {clear:both;}
   #space {height:100px;} /* стиль распорки */
   </style>
   </head>
   <body>
   <div id="wrapper">
   <div id="header"></div>
   <div id="container">
     <div id="left">{parse block="recent_articles"}</div>  
     <div id="right">{parse block="recent_articles"}</div>
     <div id="center">{parse articles}</div>
   <div class="clear">{parse block="recent_articles"}</div>
   <div id="space"></div> <!-- div-распорка -->
   </div>  
   </div>
   <div id="footer"></div>
   </body>
   </html>

 

куда поставить парсер {parse articles}, чтобы он не смещался вниз после боковых панелей а стоял в один ряд с ними?

Центральная колонка вниз проваливается.

Во-первых, надо в каком-то классе (#center) задать боковые отступы 220, а не 200 (если 200, то впритык к бокам).

Но проблема этим не решается.

Пока не поняла как поднять. Прописывание стиля в класс для формата статей не помогает

 

#container { 
min-width: 800px;
}

Снести. Там надо 100%. А оно по дефолту и так.

Все это не быстро...

И, кроме всего прочего, часть форумных css кусками повторять придется.

И заочно не сделать. Надо на месте ковыряться.

 

С форумным враппером все во много раз проще.

  • Автор

снес все ненужное

 

результат такой же

 

код выглядит теперь так

<style type="text/css">
   html, body {height:100%;}  
   #wrapper {height:auto !important;height:100%;min-height:100%;}
   #header {height:100px;}
   #center {margin:0px 200px 0px 200px;}
   #left {float:left; width:200px;}
   #right {float:right; width:200px;}
   #footer {height:100px;margin-top:-100px;} 
   .clear {clear:both;}
   #space {height:100px;} 
   </style>
   <div id="wrapper">
     <div id="left">{parse block="recent_articles"}</div>  
     <div id="right">{parse block="recent_articles"}</div>
     <div id="center">{parse articles}</div>
   <div id="space"></div> <!-- div-распорка -->
   </div>
   <div id="footer"></div>

 

ссылка

 

 

С форумным враппером все во много раз проще.
однозначно. Но еще бы понять в чем проблема...

post-39692-0-00609200-1291967480_thumb.jpg

#center {margin:0px 200px 0px 200px;}

Опять 200?

Это не поможет, но не надо в притык же все равно.

 

Спать хочу. Не соображаю ничего сейчас.

  • Автор

Опять 200?

Это не поможет
это не принципиально сейчас.

 

Не соображаю ничего сейчас.
если что найду дам знать. спасибо

однозначно. Но еще бы понять в чем проблема...

Центральному блогу не хватает место, что бы встать посередине. Очень частая ошибка при верстке.

Мне надо посмотреть свои верстки, но сейчас не могу. Попробуйте поиграть с margin и padding для центрального блока.

  • Автор

Попробуйте поиграть с margin и padding для центрального блока.

пробовал,

 

там видимо в другом дело. Все остальные парсеры вставляются и отображаются без проблем . Проблема только со вставкой {parse articles}

он тонет.

 

нашел его теплейт возможно там надо, что подправить.

 

 

 

<div class='type-1x2x2'>
<php>
	// Category or global?
	if( isset( $data['category']['category_id'] ) ){
		$rss = array( 
			'enabled' => ( substr( $data['category']['category_rss'], 0, 1 ) == 1 && $data['category']['category_show_records'] ) ? 1 : 0,
			'type' => 'category',
			'id' => $data['database']['database_id'].'c'.$data['category']['category_id'],
			'name' => $data['category']['category_name']
		);
		$title = $data['category']['category_name'];
		$this->settings['_active_cat'] = $data['category']['category_id'];
	} else {
		$rss = array( 
			'enabled' => ( substr( $data['database']['database_rss'], 0, 1 ) == 1 ),
			'type' => 'global',
			'id' => $data['database']['database_id'],
			'name' => $data['database']['database_name']
		);
		$title = $this->lang->words['fpdt_latestnews'];
	}
</php>
<div class='utilities right'>
	<if test="$data['category']['category_id']">
		<a href='{$data['category']['category_link']}?view=archive' title='{$this->lang->words['fpdt_viewarchives']}'><img src='{$this->settings['img_url']}/archive.png' alt='' /></a>
	</if>
	   
	<if test="$rss['enabled']"><a href='{parse url="app=core&module=global&section=rss&type=ccs&id={$rss['id']}" seotitle="{$rss['name']}" template="section=rss2" base="public"}' class='right'><img src='{$this->settings['img_url']}/feed.png' alt='' /></a></if>
</div>
<h2 class='section_title'>
	{$title}
	<if test="$data['database']['_can_add']">
		<a href='{$data['database']['base_link']}do=add&category={$this->request['category']}' title='{$this->lang->words['add_record_button']}' accesskey='s' class='add_link'>{$this->lang->words['add_record_button']}</a>
	</if>
	<if test="$this->memberData['member_id'] AND $this->request['category']">
		<if test="$this->settings['cpu_watch_update'] AND ( is_array( $this->memberData['_cache'] ) AND is_array( $this->memberData['_cache']['watchedContentCats'] ) AND in_array( $this->request['category'], $this->memberData['_cache']['watchedContentCats'] ) )">
			<a href='{$data['database']['base_link']}do=unwatch&category={$this->request['category']}' title='{$this->lang->words['watch_category_stop']}' class='add_link'>{$this->lang->words['watch_category_stop']}</a>
		<else />
			<a href='{$data['database']['base_link']}do=watch&category={$this->request['category']}' title='{$this->lang->words['watch_category']}' class='add_link'>{$this->lang->words['watch_category']}</a>
		</if>
	</if>
</h2>

<if test="count( $data['records'] )">
	<!-- START ARTICLE POSITION 1 -->
	<if test="$data['records'][0]">
		<div class='article block block-1<if test="!$data['records'][0]['record_approved']"> moderated</if>'>
			<if test="$data['records'][0]['article_image']">
				<img src='{$data['records'][0]['article_image']}' class='photo' {parse resize_image="$data['records'][0]['article_image']" maxwidth="225"} alt='' />
			</if>
			<div class='overview'>
				<h2><a href='{$data['records'][0]['record_link']}'>{$data['records'][0]['article_title']}</a></h2>
				<span class='desc posted_info'>{$data['records'][0]['article_date']} | <a href='{parse url="showuser={$data['records'][0]['member_id']}" base="public" template="showuser" seotitle="{$data['records'][0]['members_seo_name']}"}'>{$data['records'][0]['members_display_name']}</a> {$this->lang->words['fpdt_in']} <a href='{$data['records'][0]['category_link']}'>{$data['records'][0]['category_name']}</a></span>

				<div class='excerpt'>
					{IPSText::truncate( strip_tags( IPSText::stripAttachTag( $data['records'][0]['article_body'] ), '<br>' ), 255 )}
					<br />
					<span class='links'>
						<a href='{$data['records'][0]['record_link']}' class='read_more'>{$this->lang->words['fpdt_readstory']}</a>
						  
						<a href='{$data['records'][0]['record_link']}#comments' class='comments'>{$data['records'][0]['record_comments']} {$this->lang->words['fpdt_comments']}</a>
						  
						<if test="$data['database']['database_rate']">
							<if test="$data['records'][0]['rating_real'] >= 1">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$data['records'][0]['rating_real'] >= 2">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$data['records'][0]['rating_real'] >= 3">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$data['records'][0]['rating_real'] >= 4">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$data['records'][0]['rating_real'] >= 5">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if>
						</if>
					</span>
				</div>
			</div>
		</div>
	</if>

	<!-- START ARTICLES POSITION 2 -->
	<php>
		$this->count_p2 = 0;
	</php>
	<if test="$data['records'][1]">
		<div class='article_row'>
			<foreach loop="array( $data['records'][1], $data['records'][2], $data['records'][3], $data['records'][4] ) as $record">
				<if test="$record['primary_id_field']">
					<if test="$this->count_p2 % 2 == 0 && $this->count_p2 > 0">
						</div>
						<div class='article_row'>
					</if>
					<div class='article block block-2<if test="!$record['record_approved']"> moderated</if>'>
						<div class='overview'>
							<h2><a href='{$record['record_link']}'>{$record['article_title']}</a></h2>
							<span class='desc posted_info'>{$record['article_date']} | <a href='{parse url="showuser={$record['member_id']}" base="public" template="showuser" seotitle="{$record['members_seo_name']}"}'>{$record['members_display_name']}</a> {$this->lang->words['fpdt_in']} <a href='{$record['category_link']}'>{$record['category_name']}</a></span>
							<div class='excerpt'>
								<if test="$record['article_image']">
									<img src='{$record['article_image']}' class='photo' {parse resize_image="$record['article_image']" maxwidth="100"} alt='' />
								</if>
								{IPSText::truncate( strip_tags( IPSText::stripAttachTag( $record['article_body'] ), '<br>' ), 255 )}
							</div>
								<div class='links'>
									<a href='{$record['record_link']}' class='read_more'>{$this->lang->words['fpdt_readstory']}</a>
									  
									<a href='{$record['record_link']}#comments' class='comments'>{$record['record_comments']} {$this->lang->words['fpdt_comments']}</a>
									  
									<if test="$data['database']['database_rate']">
										<if test="$record['rating_real'] >= 1">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$record['rating_real'] >= 2">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$record['rating_real'] >= 3">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$record['rating_real'] >= 4">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$record['rating_real'] >= 5">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if>
									</if>
								</div>
						</div>
					</div>
					<if test="$this->count_p2++"></if>
				</if>
			</foreach>
		</div>
	</if>

	<!-- START ARTICLES POSITION 3 -->
	<php>
		$this->count_p3 = 0;
	</php>
	<if test="$data['records'][5]">
		<br />
		<h2 class='section_title'>Другие статьи</h2>
		<div class='article_row'>
			<foreach loop="$data['records'] as $idx => $record">
				<if test="$idx > 4">
					<if test="$this->count_p3 % 2 == 0 && $this->count_p3 > 0">
						</div>
						<div class='article_row'>
					</if>

					<div class='article block block-3<if test="!$record['record_approved']"> moderated</if>'>
						<div class='overview'>
							<h2>{$record['article_title']}</h2>
							<span class='desc posted_info'>{$record['article_date']} | <a href='{parse url="showuser={$record['member_id']}" base="public" template="showuser" seotitle="{$record['members_seo_name']}"}'>{$record['members_display_name']}</a> {$this->lang->words['fpdt_in']} <a href='{$record['category_link']}'>{$record['category_name']}</a></span>
							<br />
							<span class='links'>
								<a href='{$record['record_link']}' class='read_more'>{$this->lang->words['fpdt_readstory']}</a>
								  
								<a href='{$record['record_link']}#comments' class='comments'>{$record['record_comments']} {$this->lang->words['fpdt_comments']}</a>
								  
								<if test="$data['database']['database_rate']">
									<if test="$record['rating_real'] >= 1">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$record['rating_real'] >= 2">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$record['rating_real'] >= 3">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$record['rating_real'] >= 4">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if><if test="$record['rating_real'] >= 5">{parse replacement="rate_on"}<else />{parse replacement="rate_off"}</if>
								</if>
							</span>
						</div>
					</div>
					<if test="$this->count_p3++"></if>
				</if>
			</foreach>
		</div>
	</if>
<else />
	<div class='no_messages'>
		{$this->lang->words['fpdt_noarticles']}
		<if test="$data['database']['_can_add']">
			<a href='{$data['database']['base_link']}do=add&category={$this->request['category']}' title='{$this->lang->words['add_record_button']}'><strong>{$this->lang->words['fpdt_addone']}</strong></a>
		</if>
	</div>
</if>

<if test="$data['category']['category_id']">
	<br /><br />
	<p id='previous_bar' class='filter_bar'>
		<a href='{$data['category']['category_link']}?view=archive' title='View archives'>{$this->lang->words['fpdt_prevarts']}</a>
	</p>
</if>

<if test="$this->caches['ccs_frontpage']['paginate']">
<div class='pagelinks'>
	<if test="$this->request['p'] AND $this->request['p'] > 1">
		<div class='left'>
			<a href='<if test="$data['category']['category_id']">{$data['category']['category_link']}?p=1<else />{$data['database']['base_link']}p=1</if>'>{$this->lang->words['frontpage_previouspage']}</a>
		</div>
	</if>

	<php>
		$_ttlPgs	= $data['database']['database_record_count'] ? ceil( $data['database']['database_record_count'] / $this->caches['ccs_frontpage']['limit'] ) : 0;
		$_curPg		= $this->request['p'] ? $this->request['p'] : 1;
		$_nextPg	= $_curPg + 1;
	</php>
	<if test="$_ttlPgs AND $_curPg < $_ttlPgs">
		<div class='right'>
			<a href='<if test="$data['category']['category_id']">{$data['category']['category_link']}?p={$_nextPg}<else />{$data['database']['base_link']}p={$_nextPg}</if>'>{$this->lang->words['frontpage_nextpage']}</a>
		</div>
	</if>
</div>
</if>
</div>
<br class='clear' />

 

там видимо в другом дело. Все остальные парсеры вставляются и отображаются без проблем . Проблема только со вставкой {parse articles}

То есть, если его не вставлять, то проблем нет? Если две колонки, тоже наверное проблем нет?

 

нашел его теплейт

Я бы смотрел css. А точнее ipcontent.css

 

Обратил внимания в первую очередь на:

 

.articles-layout {
width: 100%;
}

.articles {
font-size: 13px;
width: 78%;
float: left;
}

.articles .type-1x2x2 .block-2,
.articles .type-1x2x2 .block-3 {
width: 48%;
float: left;
}

.articles .type-1x1x1 .overview {
width: 100%;
}

.articles .type-1x2x2 .block-1 .overview {
float: left;
width: 70%;
}

 

Любой элемент из articles может расширить этот articles и центральный блог откидывается вниз.

 

возможно там надо, что подправить.

Мне надо смотреть на locale. Не когда. Я переустанавливаю свой VDS

Обратил внимания в первую очередь на:

Хотя 100% это 100% от доступного места.

Можно все в таблицу вогнать. Нечего не опустится, но таблица сама по себе в блочном шаблоне не очень хороша, как каркас шаблона. :)

Проблема в h2 из модуля статей в этой конструкции

  <div class="article block block-№">
   <h2>
     <a href="http://a21200.ipsdemo.ipslink.com/index.php?/page/index.html/_/articles/frontpage/what-is-a-frontpage-r2">What Is A Frontpage?</a>
   </h2>

Если в коде его убираешь, все поднимаетя.

И странно, что совсем css нет для них. Было же в дефолте....

 

Если вы посмотрите наш исходный код (у нас без враппера), увидите, что модуль использует 2 css файла для ip.content – тот, что в скине форума, и тот, что в папке assets в ip.content

Их приходится редактировать и подстраивать под свои нужды, при этом много перенося из других css скина. Враппера нет, а функционал тащится с форума, он требует оформления.

Совсем их не использовать нельзя.

 

_http://a21200.ipsdemo.ipslink.com/index.php?/page/index.html/_/misc/templates/template-management-r5

 

Если убрать h2 с майнтитлом, статья поднимается

 

Я поняла проблему.

В ipb_styles.css прописано для h2 свойство:

clear: both;

Именно оно и выталкивает заголовок вниз (не дает блокам обтекать слева и справа)

 

Исправление:

Добавьте в css контента

 

#articles h2 {
clear: none !important;
}

  • Автор
Исправление:

Добавьте в css контента

Спасибо :)

 

получилось :)

 

правда подпортил весь ipcontent.css поисками. :)

Вот бывает так, что из-за какой-то мелочи мучаешься часами или сутками.

Помогают средства разработчиков в браузерах. Например, в опере.

Создайте аккаунт или войдите в него для комментирования

Аккаунт

Навигация

Поиск

Поиск

Настроить push-уведомления браузера

Chrome (Android)
  1. Нажмите на иконку замка рядом с адресной строкой.
  2. Нажмите Права доступа -> Уведомления.
  3. Измените свои настройки.
Chrome (компьютер)
  1. Нажмите на иконку замка в адресной строке.
  2. Выберите Настройки сайта.
  3. Найдите Уведомления и измените свои настройки.