After weeks of erratic charging on my HP Elitebook 8440p, I decided to open up the plug that goes into the laptop. In doing so all of the wires pulled out before I was able to see which one connected where - and there were three wires: black, white and blue. After some searching around on the web for the correct connections (involving lots of dead ends), I came across a thread on tom's guide where one user stated what the three wires were for. They said that black is ground, white is negative, and blue is for the centre pin. Since ground is universally the outer (shielding) part of the plug, all the connections were figured out. Have a look at the photos here to double-check what goes where.
Disclaimer Do this at your own risk! You could damage or destroy your charger, laptop or both. What I've said here is what worked for me, so if you're not sure then take advice from a professional computer repair shop.