ipad wont charge when connected
I have an ipad air 1 and recently it wont charge at all, I connect it to the computer and it is detected but just wont charge, I connect it to the wall outlet and it wont charge and the charger is not detected (apple branded charger). However, the only way I can charge the ipad is by connecting it to the wall outlet and turning the ipad off and while it is off and connected to the wall charger it charges up. Any idea what is causing this issue. thank you greatly.