Can somebody help me out changing this for the Atmega328p controller, for PD3 --> PIN5
I assume you are referring to IO pin D3? That is controlled by timer 2 channel B.
Untested code adapted from the wiki example:
// Configure PD3 as output and preserve state of other pins
DDRD := DDRB or %00001000;
// Configure PD3 PWM mode
TCCR2A := (%10 shl COM0B) or (1 shl WGM0);
// Enable timer 0, clock / 1024
TCCR2B := TCCR2B or %101;
OCR2B := 100;
In the attached picture you can see that output compare of timer two, channel B (OC2B) is routed to PD3.