I believe Diablo II just doesn't use any mouse buttons besides left and right click.
You can get around this if your mouse has software (I have Logitech) that can make the button clicks count as a keyboard key presses.
Basically you can set up the mouse buttons that don't work as F1-F12 key presses inside the software (if you use those for skills for example).