I assume you are using a ZIPLink terminal and cable.
ZIPLink module: ZL-RTB40 or SL-RTB40-1
ZIPLink cable: ZL-BX-CBL40-S or ZL-BX-CBL40-1S
With the above equipment and guessing at your encoder (without seeing its specs):
Encoder A --> IN 0+ (on ZIPLink)
Encoder GND --> IN 0- (on ZIPLink)
Encoder B --> IN 1+ (on ZIPLink)
Encoder GND --> IN 1- (on ZIPLink)
And, of course, you'll have to hook your +5 VDC power supply to your encoder's Vcc, and the minus (-) terminal of your power supply to the GND of your encoder.
As I said, this is just my first guess based on the info you provided.