I did this job a while back . . . just like CB said.
pressure treated wood and home cheapo indoor/outdoor (UV resistant) carpet. I used monel staples. They've held up well and look great.
Some people use a carpet glue or even a little epoxy to help the rug stick and stay flat.