Do a search on PIC programmers - there are plenty of designs documented here. But honestly you'd be far better off to buy a proven programmer before trying to write code and test it with an unknown quantity.