In those photos, lamp cords are neatly tucked away as if the lamp illuminates itself. The cords are simply streamlined down the leg or base of the table that the lamp sits on.
These little gadgets called CableDrops from Bluelounge can help you eliminate cord chaos in your home. You can use them for lamps, appliances, and home office needs.
They have adhesive backs and are come in bright or muted colors. $9.95 for six.