HP C8941 Photosensor wire colors
The colors differ from module to module. Some modules have Black-Green-Blue instead of White-Green-Red - At least Google Images say so.
The module itself is nothing different from a LED-Phototransistor Combo. According to your drawing, from the top-view, left side is LED (you can verify this by seeing a diode symbol on the topside) and right side is transistor. And the connection should be something like this:



simulate this circuit &ndash; Schematic created using CircuitLab
From a Google search, you can find a picture from the bottom side of the module. And this picture verifies what I've shown above:

So;

Middle (Green) is GND because it's a common connection
Top (white) is LED's anode (should be positive supply through a resistor)
Bottom (Red) is open-collector output