Marijuana plants are a few weeks away from harvest.

The Associated Press / 2015

PHOENIX — A appellate court ruling has overturned Arizona's law making it a crime for medical marijuana cardholders to possess pot on college and university campuses.

The Court of Appeals ruling Thursday says the 2012 law prohibiting medical-marijuana on higher education campuses violates protections for voter-approved laws.

Arizona's 2010 medical-marijuana law prohibits possession in prisons, at schools and on school buses, but the ruling says lawmakers can't add college and university campuses to the prohibition list.

The ruling says that's because it doesn't "further the purpose" of the voter-approved medical marijuana law.

However, the ruling says the state and other landowners still can regulate what items or materials are taken onto their property, so a person violating an educational institution's restrictions could be removed from the property or charged with trespassing.