Jump to content
Larry Ullman's Book Forums

Clips


Jonathon
 Share

Recommended Posts

Hi,

 

I'm going to have some rotating banners on some of my pages. As they are only on some of my pages I didn't want to include this in my layout. I thought placing them in a clip would be a good idea and then just rendering them in the view file. Is it?

Link to comment
Share on other sites

I think of clips as being better for dynamic content that could change that you'd want to create in one place (i.e., a controller) and use in a view. With banner ads, you probably have static HTML that should just go in a layout file and then you would change the layout file used when necessary. Don't you think?

Link to comment
Share on other sites

Well  it is currently in my layout file. I just thought it would be cleaner HTML wise in the view to call it from another place as it's not going to be used on every page. I'll keep it where it is. I did read that clips were more appropriate for dynamic content.

 

Thanks for getting back to me

 

Jonathon

Link to comment
Share on other sites

No, definitely not a widget. You're just talking about some static HTML, so no clip or widget is necessary. Depending upon the site, I would either create a second layout that has the banner or use renderPartial() for it.

Link to comment
Share on other sites

It really depends on wheter your banners are static or not. In my experience, adds and banners are randomized, switched out and managed by a solution. Creating a widget for such tasks make completly sense to me because of these reasons. Clips may be an even better solution for this, but I haven't really looked into their purpose yet, so that's not something I can really judge. However, I think a widget does make sense if you want more than one static banners.

Link to comment
Share on other sites

I can appreciate what you mean and it's been a long time since I've done anything with widgets and banners, but my recollection is that they use static HTML and JavaScript and the service that provides the ads is randomizing and switching the actual ads served. I could be wrong on that, though. 

Link to comment
Share on other sites

 Share

×
×
  • Create New...