How to get file path without the file name

Hello all
im doing this to build batch cp command :

find ../php/ -type f | awk '{print "cp "$1 }'

now I missing the second part of the command that will give me the destination path that is
the same but without the file name , how can I drop the filename with awk so the result will be :

"cp php/admin/foo.php ../php/admin/ "

thanks for the help.

echo 'a/b/c/d' | nawk '{match($1, "^.*/"); print substr($1, 1, RLENGTH-1)}'

see something like

find ../php/ -type f | awk '{print "cp `dirname $1`" }'

dirname: this will give you path of file excluding filename.