Modx GetImageList: Retrieve Every Other MIGX Entry - modx

I am trying to have GetImageList retrieve every other/second entry in the MIGX tv. This way I can have two calls and split them up between two bootstrap columns. It just looks better that way. What parameters can I include in the snippet to do so?
[[getImageList?
&tvname=`Success Stories`
&tpl=`successtpl`
]]
Thanks!

I was able to use two getImageList calls, one in each column, each with a different conditional based on [[+_alt]]:
[[+_alt:is=`1`:then=`
<div class="col-md-12 col-sm-12 col-xs-12 cl-stacked-margin-bottom">
<div id="cl-tesimonial">
<div class="testimonial-content"><i class="fa fa-quote-left" aria-hidden="true"></i>
[[+client_testimony]]
<h2 class="cl-client-name">[[+client_name]]</h2>
<div class="cl-author image-testimonial"> <img src="[[+client_img:notempty=`[[+client_img]]`:else=`[[++assets_url]]img/client_images/testimonial.jpg" alt="[[+client_name]]">
</div>
</div>
</div>
</div>
`:else=``]]
and:
[[+_alt:is=`1`:then=``:else=`
<div class="col-md-12 col-sm-12 col-xs-12 cl-stacked-margin-bottom">
<div id="cl-tesimonial">
<div class="testimonial-content"><i class="fa fa-quote-left" aria-hidden="true"></i>
[[+client_testimony]]
<h2 class="cl-client-name">[[+client_name]]</h2>
<div class="cl-author image-testimonial"> <img src="[[+client_img:notempty=`[[+client_img]]`:else=`[[++assets_url]]img/client_images/testimonial.jpg" alt="[[+client_name]]">
</div>
</div>
</div>
</div>
`]]

Related

How to repeat (adding loop) html elements with content in angular

I want to repeat the following code block using angular or node.js
<div class="test-item col-sm-6">
<div class="col-sm-4">
<img class="img-responsive" src="../../../../assets/image/ngozi.png">
</div>
<div class="col-sm-8">
<p>"Definitely worth the investment. Without sancoj, we would have gone bankrupt by now."</p>
<div>
<i class="material-icons checked">star</i>
<i class="material-icons checked">star</i>
<i class="material-icons checked">star</i>
<i class="material-icons checked">star</i>
<i class="material-icons checked">star</i>
</div>
</div>
</div>
Some ideas?
try to use *ngFor, for more details have a look at angular docs here,
<div class="test-item col-sm-6">
<div class="col-sm-4">
<img class="img-responsive" src="../../../../assets/image/ngozi.png">
</div>
<div class="col-sm-8">
<p>"Definitely worth the investment. Without sancoj, we would have gone bankrupt by now."</p>
<div>
<i class="material-icons checked" *ngFor="let star in stars">{{star}}</i>
</div>
</div>
</div>

How to add slot in repeat dom in polymer 2

i want to create a layout element, so i write the template like this
<template>
<div class="row">
<template is="dom-repeat" items="[[cols]]">
<div class$="col-[[item]]">
<slot id="id[[index]]" name="id[[index]]">no value</slot>
</div>
</template>
</div>
</template>
and in the html page file, i use this component like this:
<tcpc-row>
<span slot="id0">cc id-tcpc-col-0 </span>
<span slot="id1">cc id-tcpc-col-1 </span>
<span slot="id1">cc id-tcpc-col-3 </span>
</tcpc-row>
but i result is not correctly, when i write the template without repeat is ok, like this:
<template>
<div class="row">
<div class="col-3">
<slot name="id0"></slot>
</div>
<div class="col-3">
<slot name="id1"></slot>
</div>
<div class="col-3">
<slot name="id2"></slot>
</div>
<!--<template is="dom-repeat" items="[[cols]]">
<div class$="col-[[item]]">
<slot id="id[[index]]" name="id[[index]]">no value</slot>
</div>
</template>-->
</div>
</template>
is there have some way to add slot in repeat?
Try slotting the <div class="row">.

content of ion-content go inside ion-header-bar

I am new to ionic framework. When I use ion-content like this
<ion-view>
<ion-header-bar class="bar bar-header bar-positive">
<div class="buttons">
<button class="button" ng-click="doSomething()">Left Button</button>
</div>
<h1 class="title">Title!</h1>
<div class="buttons">
<button class="button">Right Button</button>
</div>
</ion-header-bar>
<ion-content class="has-header">
<div class="row">
<div class="col">
<i class="fa fa-university"></i>
</div>
<div class="col">.col</div>
<div class="col">.col</div>
</div>
<div class="row">
<div class="col">.col</div>
<div class="col">.col</div>
<div class="col">.col</div>
</div>
</ion-content>
</ion-view>
First row go inside header bar. What's the problem?
I've used requirejs to load controller .
I didn't inject ionic module during bootstraping.
After inject ionic in module this problem solved.

Foundation: How to stack columns in responsive layout?

Trying to figure out how to a do a responsive layout using Foundation. I am new to this and familiar with the ability to use push and pull but I am struggling trying to figure out how to stack items in a single row.
Visual: http://i.imgur.com/q1LAvIa.png
<div class="row">
<div class="small-12 large-? columns"> A </div>
<div class="small-12 large-? columns"> B </div>
<div class="small-12 large-? columns"> C </div>
</div>
Thanks in advance!
i think your code (according to your image) would be like:
<div class="row">
<div class="small-12 large-6 large-push-6 columns">A</div>
<div class="row">
<div class="small-12 large-6 large-pull-6 columns">B</div>
<div class="small-12 large-6 columns">C</div>
</div>
</div>
</div>
You could check "Advanced" & "Source Ordering" sections in http://foundation.zurb.com/docs/components/grid.html

CMSMS does not display html code in edito

I have a very weird problem with CMSMS. I have some HTML in my header file, there should be 2 links, but every time I paste a second one and click Apply- it disappears from editor. Although it shows on website.
CMSMS version: 1.11.9
<div class="header">
<div class="container">
<div class="row-fluid">
<div class="logo_wrapper">
<div class="logo"><img src="{root_url}/ui/images/logo.png" alt="" /></div>
</div>
<div class="span6 pull-right">{if $sid == 1 }
<div class="kabinet pull-right"><a class="rounded" href="apps/customer/web/profile/edit"> Профиль</a></div>
{else}
<div class="kabinet pull-right"><a class="rounded dark" href="#"> Статус доставки</a> <a class="rounded" href="apps/customer/web/login"> Личный кабинет</a></div>
{/if}</div>
</div>
<hr />
<div>
<div class="nav">
<div class="nav-inner">{menu loadprops=0}</div>
</div>
</div>
</div>
</div>
It should be after save:
<div class="header">
<div class="container">
<div class="row-fluid">
<div class="logo_wrapper">
<div class="logo"><img src="{root_url}/ui/images/logo.png" alt="" /></div>
</div>
<div class="span6 pull-right">{if $sid == 1 }
<div class="kabinet pull-right"><a class="rounded" href="apps/customer/web/profile/edit"> Профиль</a>
(this link keeps disappearing)
<a class="rounded no-bg-color" href="apps/customer/web/logout"><i class="icon-off icon-white"></i></a>
</div>
{else}
<div class="kabinet pull-right"><a class="rounded dark" href="#"> Статус доставки</a> <a class="rounded" href="apps/customer/web/login"> Личный кабинет</a></div>
{/if}</div>
</div>
<hr />
<div>
<div class="nav">
<div class="nav-inner">{menu loadprops=0}</div>
</div>
</div>
</div>
</div>
It's probably the HTML editor (MicroTiny I expect) believing that link is invalid HTML and throwing it away.
Set the editor to HTML mode so that you can edit the HTML directly (not WYSIWYG). It will then accept your edits and not try to edit them.

Resources