please tell me how to get a picture of a child in the parent document. I use the pictures for the TV image. The tpl of news is next:
<li class="prod_list_item" data-brand="[ [ +description ] ]">
<h2 class="prod_list_item_hline prod_list_item_hlink"><a href="[ [ ~[ [ +id ] ] ] ]" class="prod_list_item_hlink">[ [ +pagetitle ] ]</a></h2>
<a class="prod_list_item_img_wrap" href="[ [ ~ [ [ + id ] ] ] ]" ">" < "img" title="" src=" [ [ * image ] ]" alt="" /> </a>
<div class="prod_list_item_text"> [ [ +introtext ] ] </div>
<a class="prod_list_item_open" title="ОТКРЫТЬ" href=" [ [ ~ [ [ +id ] ] ] ]">ОТКРЫТЬ</a></li>
Thanks!
-
☆ A M B ☆
- 3,112 Posts
if you're using getResources, try to add "tv." prefix to the [ [+image]] placeholder => [ [+tv.image]]
Rico
Genius is one percent inspiration and ninety-nine percent perspiration.
Thomas A. Edison
MODx is great, but knowing how to use it well makes it perfect!
www.virtudraft.com
Security, security, security! |
Indonesian MODx Forum |
MODx Revo's cheatsheets |
MODx Evo's cheatsheets
Author of
Easy 2 Gallery 1.4.x,
PHPTidy,
spieFeed,
FileDownload R,
Upload To Users CMP,
Inherit Template TV,
LexRating,
ExerPlan,
Lingua,
virtuNewsletter,
Grid Class Key,
SmartTag,
prevNext
Maintainter/contributor of
Babel
Because it's hard to follow all topics on the forum, PING ME ON TWITTER
@_goldsky if you need my help.
thanks, but no result =(
<li data-brand="[ [ +description ] ]">
<h2><a href="[ [ ~[ [ +id ] ] ] ]">[ [ +pagetitle ] ]</a></h2>
<a href="[ [ ~ [ [ + id ] ] ] ]" ">" < "img" [ [+tv. image ] ]"" /> </a>
<a href=" [ [ ~ [ [ +id ] ] ] ]">ОТКРЫТЬ</a></li>
-
☆ A M B ☆
- 3,112 Posts
<li data-brand="[[+description]]">
<h2><a href="[[~[[+id]]]]">[[+pagetitle]]</a></h2>
<a href="[[~[[+id]]]]"><img src="[[+tv.image]]" /></a>
<a href="[[~[[+id]]]]">ОТКРЫТЬ</a>
</li>
Make sure you don't set the &tvPrefix=``
Rico
Genius is one percent inspiration and ninety-nine percent perspiration.
Thomas A. Edison
MODx is great, but knowing how to use it well makes it perfect!
www.virtudraft.com
Security, security, security! |
Indonesian MODx Forum |
MODx Revo's cheatsheets |
MODx Evo's cheatsheets
Author of
Easy 2 Gallery 1.4.x,
PHPTidy,
spieFeed,
FileDownload R,
Upload To Users CMP,
Inherit Template TV,
LexRating,
ExerPlan,
Lingua,
virtuNewsletter,
Grid Class Key,
SmartTag,
prevNext
Maintainter/contributor of
Babel
Because it's hard to follow all topics on the forum, PING ME ON TWITTER
@_goldsky if you need my help.
please tell i must use TVprefix or not in my snippet.the following snippet call:
[[!getPage@articlePaging?
&element=`getResources`
&showHidden=`1`
&includeTVs=`1`
&processTVs=`0`
&includeContent=`1`
&parents=`[[*id]]`
&tpl=`tovar`
&limit=`4`
&tvPrefix=``
&sortBy=`menuindex`
&pageNavVar=`page.nav`
]]
-
☆ A M B ☆
- 3,112 Posts
if you use &tvPrefix=``, then the placeholder is [ [+image]]
Otherwise, the default behavior will add 'tv.' to it: [ [+tv.image]]
it's up to you to use which one, as long as you know the result.
btw, your image TV must also be named as 'image', not 'tv.image'.
Rico
Genius is one percent inspiration and ninety-nine percent perspiration.
Thomas A. Edison
MODx is great, but knowing how to use it well makes it perfect!
www.virtudraft.com
Security, security, security! |
Indonesian MODx Forum |
MODx Revo's cheatsheets |
MODx Evo's cheatsheets
Author of
Easy 2 Gallery 1.4.x,
PHPTidy,
spieFeed,
FileDownload R,
Upload To Users CMP,
Inherit Template TV,
LexRating,
ExerPlan,
Lingua,
virtuNewsletter,
Grid Class Key,
SmartTag,
prevNext
Maintainter/contributor of
Babel
Because it's hard to follow all topics on the forum, PING ME ON TWITTER
@_goldsky if you need my help.
So, my last changes are:
[ [ ! getPage@articlePaging?
&element=`getResources`
&showHidden=`1`
&includeTVs=`1`
&processTVs=`0`
&includeContent=`1`
&parents=``
&tpl=`tovar`
&limit=`4`
&tvPrefix=``
&sortBy=`menuindex`
&pageNavVar=`page.nav`
] ]
and tpl chunk is :
<li data-brand="[ [ +description ] ]">
<h2><a href="[ [ ~[ [ +id ] ] ] ]">[ [ +pagetitle ] ]</a></h2>
<a href="[ [ ~ [ [ + id ] ] ] ]" ">" < "img" [ [+ image ] ]"" /> </a>
<a href=" [ [ ~ [ [ +id ] ] ] ]">ОТКРЫТЬ</a></li>
but it not work!
-
☆ A M B ☆
- 3,112 Posts
set processTvs to 1.
and fix your img html tag.
Rico
Genius is one percent inspiration and ninety-nine percent perspiration.
Thomas A. Edison
MODx is great, but knowing how to use it well makes it perfect!
www.virtudraft.com
Security, security, security! |
Indonesian MODx Forum |
MODx Revo's cheatsheets |
MODx Evo's cheatsheets
Author of
Easy 2 Gallery 1.4.x,
PHPTidy,
spieFeed,
FileDownload R,
Upload To Users CMP,
Inherit Template TV,
LexRating,
ExerPlan,
Lingua,
virtuNewsletter,
Grid Class Key,
SmartTag,
prevNext
Maintainter/contributor of
Babel
Because it's hard to follow all topics on the forum, PING ME ON TWITTER
@_goldsky if you need my help.
still does not work...I use before <i m g s r c =" [ [ +image ] ] "> simply did not show this forum, and in the field &processTvs I'm put 1, without result. I'm really didn't know how to do it...
-
☆ A M B ☆
- 3,112 Posts
Try to use the vanilla getResources first
[[!getResources?
&showHidden=`1`
&includeTVs=`1`
&processTVs=`1`
&includeContent=`1`
&parents=`[[*id]]`
&tpl=`tovar`
&limit=`4`
&tvPrefix=``
&sortBy=`menuindex`
&pageNavVar=`page.nav`
] ]
fix your parents property, too.
Rico
Genius is one percent inspiration and ninety-nine percent perspiration.
Thomas A. Edison
MODx is great, but knowing how to use it well makes it perfect!
www.virtudraft.com
Security, security, security! |
Indonesian MODx Forum |
MODx Revo's cheatsheets |
MODx Evo's cheatsheets
Author of
Easy 2 Gallery 1.4.x,
PHPTidy,
spieFeed,
FileDownload R,
Upload To Users CMP,
Inherit Template TV,
LexRating,
ExerPlan,
Lingua,
virtuNewsletter,
Grid Class Key,
SmartTag,
prevNext
Maintainter/contributor of
Babel
Because it's hard to follow all topics on the forum, PING ME ON TWITTER
@_goldsky if you need my help.