Customer Support Portal
Home>Knowledge Base>Root>Dotnetnuke Modules>Content Rotator>How can I use the dynamic content feature of the rotator module?
User Login
Article ID17
Created On7/31/2009
Share With Others

How can I use the dynamic content feature of the rotator module?

The Content Rotator module for DNN allows you to get data from your database which will be used to rotate. To do this open up the module settings and extend the dynamic content section.

Place your SQL query in the sql query box and press "execute query". This will execute your query and create tokens for you based on the colum names in the query results.
For example:
  1. Use the following query: SELECT * FROM TABS
  2. Execute the query
  3. You have tokens like "[TabID]" and "[TabName]" etc.

Next you have to create a template for your items. You are free to setup the template as you see fit using HTML and CSS. Wherever you want dynamic information to be displayed simply place the corresponding token inside your template.

You can use the tokens inside html tags for example:
  • <img> tag to create dynamic images. For example: <img src="[ImageUrl]" alt="[ProductName]" > This will create an image with an image url with the value you got from the database.
  • <a href> tag to create dynamic links. For example: <a href="http://[Url]">[Title]</a> This will create a dynamic url linked to the [Url] value from your query.