fm[f_]:=DSolve[{x''[t]+4x[t]=f,x'[t]==0,x[t]==0},x[t],t][[1,1,2]]
what does the brackets [[1,1,2]] means ?
The function DSolve does not directly return the solution as a function. It returns a List of Rules which can contain multiple solutions.
So, after running DSolve, you have to extract the function out of the result. You can use Part. It's usually better to do it with Replace or Lookup: http://support.wolfram.com/kb/12505
http://reference.wolfram.com/language/ref/Part.html