That depends on the rest of your code. But it will be something like.
rem store camera object angles before moving
cx#=object angle x(cam_obj) : cy#=object angle y(cam_obj) : cz#=object angle z(cam_obj)
rem up and down keys move player forward and back
rem left and right keys strafes player left and right
if upkey()=1 then xrotate object cam_obj,0 : move object cam_obj,1 : xrotate object cam_obj,cx#
if downkey()=1 then xrotate object cam_obj,0 : move object cam_obj,-1 : xrotate object cam_obj,cx#
if leftkey()=1 then xrotate object cam_obj,0 :yrotate object cam_obj,cy#-90 : move object cam_obj,1.5 : yrotate object cam_obj,cy#: xrotate object cam_obj,cx#
if rightkey()=1 then xrotate object cam_obj,0 :yrotate object cam_obj,cy#-90 : move object cam_obj,-1.5 : yrotate object cam_obj,cy#: xrotate object cam_obj,cx#
Hope this helps. This is almost straight out of an example that comes with DBP.
"People don't fail ..... they stop trying." Specs. P4 2.8GHz 800 FSB | 512MB DDR333
GeForce FX 5200 AGP 256MB | Windows XP Pro Full