Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more

Courasol image slider in EPI server

Vote:
 

Hi ,

Am new to EPI.

I want to implement image slilder block with another block type data.

I have a block which store some images with some data.

i want to get images from this block and i want to display those images in courasol image slider block.

#174240
Jan 23, 2017 8:37
Vote:
 

Hi Sandeep,

To this in your let's say your block called CarouselBlock. You need a list of content references to drag and drop your images:

public class CarouselBlock : BlockData

{

  [AllowedTypes(typeof(ImageData))]
public virtual IList<ContentReference> Images { get; set; }

}

and in your razor template you  can go:

@foreach (var imageContentRefernece in Model.Images)
{
    <img src="@Url.ContentUrl(imageContentRefernece)" />
}

Aria

#174246
Jan 23, 2017 10:16
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.