I am copying the text for my easy reference. Credit goes to Martha Stewart's Space Saver Desk
Using a twist on under-bed storage, the area below a store-bought loft bed becomes a welcoming small-scale study. An adjustable desk is made of painted plywood attached to a homemade wooden frame, which was screwed to the bed's base for stability.
Desk How-ToWe made our simple frame out of one-by-fours and two-by-fours cut down to match the dimensions of the store-bought loft bed's legs and horizontal supports. The desk and chalkboard are each made from 3/4-inch-thick plywood and attached to the structure with piano hinges. The adjustable desk is also supported by casement window adjusters, as shown.
1. Attach the part of each adjuster that has the tightening knob to the sides of the frame at the center points.
2. Screw the tops of the adjusters to the desktop's underside. The knobs allow a child to angle the desk surface, like a drafting table, or make it lie flat.
3. To create the blackboard, first prime and paint the plywood. Then tape off the edges of the board with 1-inch-wide masking tape.
4. Apply two coats of chalkboard paint to the un-taped area, let dry, and peel away the tape.