Portal Engine Questions on portal engine and web parts.
Version 5.x > Portal Engine > Carousel View modes: 
User avatar
Member
Member
ovidiu.lazar-evozon - 3/8/2011 5:52:03 AM
   
Carousel
Hi,
I'm in the (urgent) need of creating a carousel.
Basically, on the home page, the user sees a series of pictures, descriptions and text link. Just your regular carousel.
The carousel slides the images, shows the descriptions for each image and the user ca click the text and will be taken to a designated URL.

The only thing is we want the content writer to be able to define these triplets in CMS desk. By triplet I mean image, description and link.

What's the best approach to do this?

User avatar
Member
Member
ovidiu.lazar-evozon - 3/8/2011 5:54:25 AM
   
RE:Carousel
Forgot to mention: the user should be able to define the order in which the images are displayed in the carousel.

User avatar
Member
Member
Chanan - 3/8/2011 6:03:55 AM
   
RE:Carousel
The way I would start would be to create your html & Javascript in an html eidtor till you have the look and feel you want. I am sure if you look through the JQuery plugins directory you may find one that does what you want.

Once you are armed with your html & Javascript, create a custom document type that has the 3 items you mentioned - title, image & description. Also add NodeOrder from the system properties -> Node items (I am not 100% sure if you need to add it or not, but it cannot hurt).

Create a folder on your site where these documents will live (or right under the home page if you want) and create some sample documents of your new type. Drag them to be in the order you want them to appear on the homepage

Now that you have the html & the data, you are ready to edit the homepage. Add a repeater to the home page to repeat over the folder & document type you created. In the order by field enter: NodeOrder.

Next, in the transformation - transform the document into the html you need to be displayed for each item.

Lastly, in the content before and after wrap your repeater with the html needed for the carousel. Add a Java Script webpart to the page to fire off the javascript needed for the carousel.

Enjoy your spinning Carousel.

User avatar
Member
Member
ovidiu.lazar-evozon - 3/8/2011 7:28:54 AM
   
RE:Carousel
Hi Chanan and thanks for your quick response.

One thing that I didn't get is that I don't need to create a document template? I already created the document type and added the folder where my carousel items will reside.

However, when I try to add a new document, I am asked to select a document type.
Obviously, if i select the master page template, when i click on the newly created "carousel item", i get the website with the logo menu etc.

I should be getting a simple list where the user has the option to upload an image, set up a title, description and link..

I don't think I have to create a new control that has an image uploader, a text area for the description and all the rest, right? When I created the doc type I specified the types of asp.net controls i want to use for each field.. which leads me to believe Kentico will take care of generating the controls for me.

Am I missing something?

User avatar
Certified Developer 9
Certified Developer 9
charbf-gmail - 3/8/2011 8:07:33 AM
   
RE:Carousel
Hi,

Since you already have a document. you can use the scrolling text webpart.

with it, you can use a transformation to build the HTML as needed.

It's pretty simple to integrate and might what you need

User avatar
Member
Member
Chanan - 3/8/2011 8:20:08 AM
   
RE:Carousel
You shouldn't need a document template from what you explained. When Creating a new document the user should select your carousel item - it should then present the user with the form view of the page to enter in the form values (name, image and description).

User avatar
Member
Member
ovidiu.lazar-evozon - 3/8/2011 8:31:51 AM
   
RE:Carousel
My thoughts exactly.
But when I try to create a carousel item page, I only get this:

******
Please select new document type:
Page (menu item)
File
Folder
Software Product
******

I get here by right clicking on my folder in the right tree, then selecting New...

I looked at my new page type and tried to make it look exactly as the "Page (menu item) " but it still doesn't appear...

Maybe I forgot to set some property?

User avatar
Member
Member
tspring-allegra - 3/8/2011 9:21:24 AM
   
RE:Carousel
Have you selected your new document type under the "Child Types" of the parent document type you're trying to add under? (In SiteManager/Development/DocumentTypes)

In this case I think you're wanting to add the new document type under the Folder document type.

User avatar
Member
Member
ovidiu.lazar-evozon - 3/8/2011 9:46:16 AM
   
RE:Carousel
I think the reason is that I'm trying to add my doc type either in the root or in a folder inside the root page.

We already have another doc type that does work (made by a colleague of mine) but we can't figure out for the life of us why hers can be added in the root while mine can't. The only difference is that hers has a doc template associated.

I guess this means you can't add a new doc to the root if its corresponding doc type doesn't have a template.

User avatar
Member
Member
tspring-allegra - 3/8/2011 10:02:38 AM
   
RE:Carousel
Like I said, are you sure both the Root and Folder document type can both have "Child Types" of your new document? Without this your new document wont show up in the list when you click the New Document button.

User avatar
Member
Member
ovidiu.lazar-evozon - 3/8/2011 10:11:00 AM
   
RE:Carousel
You're right. Still new to kentico, i found the root , added the child and now it works.
Thanks.