Anthony D. Rich pleaded no contest Tuesday to child abuse and attempted child abuse. He is expected to begin his sentence in October.
Prosecutors reduced the charges from sex crimes that could have branded Rich a sex offender for life. He was 17 when he posted the photo of his then-15-year-old girlfriend on the social-networking Web site that's owned by News Corp.
Rich had dated the girl for more than two years. He posted the photo after they broke up. The girl consented to having the photo taken, but Rich did not have permission to post it, authorities said.