Can you get in trouble for using someone else's credit card with their permission?

No. People often allow others to use their card(s). Problems sometime arise if there's a question as to who should pay the charge(s). As far as the credit card company is concerned, only the card holder is responsible for charges made on the account. Unless the card has been used fraudulently.