To answer your first question about the 40-gallon, it certainly would be better. Personally, I wouldn't use a combo light in a tank less than 50 gallons, but 10 gallons less isn't that much, I suppose. Check the temp with a thermometer to be sure the temp is OK.
For hanging it, I use a Zoo-Med lamp stand for one of my set-ups. I think you can see what it is at
www.4littlepets.com (click Reptile, then Dome Lights, then scroll down). It works well; it comes in two sizes, get the regular one not the smaller one. You hang the light off of just about anything that's safe and stable. I use a flag stand to hang the MVB lamp over the basking area in a 110-gallon stock tank.
You also have the option of using clamp lamps (UVB light and basking lights). It's up to you. For me, how big the set up is and the kind of basking area being used determines what kind of lighting used.
"You become responsible, forever, for what you have tamed." -Antoine de Saint Exupery-