It’s certainly true that there are many guys who have a preference for “long haired” girls. Then there are some guys who love “short hair” on a girl. So it totally depends on the personal preferences of a guy.
It’s quite tough to understand why a guy would break off with his girlfriend just because she cut her hair short. The only reason could be that he never really loved her in the first place and just used the “short haircut” as a reason for initiating a break up.
If a guy doesn’t care for your personal preferences, then the relationship is not ultimately going to last long. So it’s better to end it sooner than later. So if your boyfriend left you because you cut your hair short, just think of it as a “good thing” because this guy would not have lasted the course with you anyway.
In certain countries like India, it is quite traditional for a girl to wear her hair long. So most guys in India are naturally attracted to a girl with long hair, and prefer their wife to not cut her hair short. So the traditions and “house” conditioning that a guy grew up with could get him to be more attracted to a long haired girl than a short haired one. A totally “pig-headed” guy can have very strong views on the type of look he wants on his girl, such a guy would be quite willing to end the relationship on such trivial accounts.
It’s one thing to cut your hair short, so as to have a “bob” cut look. It’s a totally different thing to get yourself a “manly” haircut, where you hair is so short that it looks like a “guy’s” head. Most men would feel a bit “repulsed” if a girl has a guy type look to her hair. It’s important to retain a “feminine” look with a short hair.
In any case, love would need to go beyond looks for it to be long lasting. If your guy is so hung up with your hair, that he quits on you when you cut it short, it does not speak much about his love for you. So it’s good riddance.