determine the value k so that x-4 is a factor of $\displaystyle x^2+8x+k$

i know that answer is going o be 12, i got it by dividing x-4 into $\displaystyle x^2+8x+k$ but im not sure about the remainder, bcz i got k+48

does that change the answer.

$\displaystyle m^2-k^2+6k-9$ has a factor of (m-k+3) what is the other