A folding table requires a door with hinges and 2 lengths of chain/cable/rope and 4 eye hooks. Mount door to wall so it hinges up to the wall flat. Add eye hooks to door on the opposite side from the hinges and up on the wall above mounted door. Run chain/cable/rope between eye hooks so door is parallel to floor. Then you need a latch to hold it up out of the way when not in use. No legs necessary!