SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member subhasis_bubu's Avatar
    Join Date
    Sep 2005
    Posts
    19
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Datalisting using Smarty

    Hi all,

    I just want to display the data one after another in a table.

    I am using Smarty {section} for these.

    Apparently it is working absolutely fine but what I want is that I want to add different colors in the odd and even rows of the tabular listing of data.

    any help will be highly accepted.
    Subhasis

  2. #2
    SitePoint Evangelist dscriptor's Avatar
    Join Date
    Oct 2005
    Location
    in front of my computer
    Posts
    571
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    after these lines:

    HTML Code:
    {section name=i loop=$list}
    	{strip}
    put this in your table row
    HTML Code:
    <tr bgcolor="{cycle values="#eeeeee,#eeeedf"}">
    cheers!

    happy is the man that finds wisdom....wisdom in {PHP}.



Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •