You should have mentioned right at the start that this is for people in USA, and may not apply elsewhere. (Do other countries use breakaway conductive tabs on "duplex" receptacles, to allow each of them to be on separate circuits? Here it's mainly so one of a pair can be controlled by a wall switch, while the other is always live.)
Also, here's how to tell which is the "HOT" side: A) it has gold-colored terminal screws - the neutral side has silver-colored screws. B) it has the shorter slot, to accept only the narrower blade of polarized plugs.
Either or both of these features may be missing if your duplex receptacle is more than about 40 years old...
For those who didn't "get it", this is a very simple method to put two light strings in series, rather than the normal parallel configuration - if the strings are approximately the same, each will only receive about half the normal voltage.
BTW, I would definitely use a standard electrical outlet box, preferrably plastic. If using a metal box, then a cable clamp may be needed and the box should be grounded (connected to the green wire in the grounded power cord, along with the green screw on the receptacle). Also, if using a separate cable clamp or one built into the box (if no good strain relief can be found or made to work), to get a good grip and not puncture or tear the cord's insulation, wrapping it with several layers of electrical tape at the clamping point to make it thicker and tougher is a fair alternative.