The reason for your latest error is you left out the "x->" that I had. Compare these:
In[1]:= q[f[x],x]/.x->{1≥x≤4}
ln[106]= q[f[x],x] /.{1<=x<=4}
Now if you need to use replacement rules and you need to start with {1<=x<=4} then I would look at
FullForm[{1<=x<=4}]
and see if you can think of a way to use rules to turn that into
{x,1,4}
If you can use replacement rules to accomplish that then you will be half way to then using that result as another replacement to turn x into {x,1,4}.
But you have two x that you have to worry about, one inside f[x] and one inside q[ ,x]. You only want to replace the second one, not the first one.
You might look at this
http://reference.wolfram.com/mathematica/ref/Replace.html
and pay particular attention to levelspec. Levels are not exactly obvious to a new user, but with the hint that you want to pay attention to that then you might be able to figure out how to have a replacment only change the particular x that you are wanting it to and leave the other x alone.
So look at that FullForm result and see if you can solve that problem first. Then you can study levels.