IR Led & Phototransistor pair bandwidth issue
First, you do not identify what phototransistor you're using, so there is no way anyone can answer your question about collector identification. "flat side" almost certainly identifies the photosensistive face, not collector or emitter.

It doesn't help that you haven't provided a number for the ouput voltage, either. "Low" could mean 1 volt, or .5 volt, or .1 volt.

That said, you need to do the following: put your circuit (without the LED) in a completely light-tight enclosure and see what the output is. Most likely you're picking up stray IR.

If you're still having problems, go back to the data sheet for your phototransistor and look at the dark current spec. If you're using a bc847b, your DC gain could be as high as 450. Assuming "low" means 0.5 volts, that's a collector current of about .5 mA, and a dark current of 1 uA will provide enough base current to do that.