Shaykh al-Islām—may Allah have mercy on him—said:
Section
If a son is in his mother’s custody and she spends on his maintenance intending to seek reimbursement from his father, she may seek reimbursement from him according to the stronger of the two scholarly views. This is Mālik’s position and the apparent position of Ahmad’s school, followed by his early adherents. A principle shared by both is that whoever discharges an obligation on another’s behalf may seek reimbursement from him, even if he acted without permission—for example, paying his debt or providing for his slave, or fearing that the enemy might kill him.
Allah Most High says:
“If they breastfeed for you, then give them their payment.”
He thus commands payment simply on account of breastfeeding, without stipulating a contract or permission. If, however, she provided the maintenance gratuitously, she has no right to seek reimbursement.
If he stipulates that she will have no claim to maintenance if she travels with the daughter, and she accepts this condition and then travels with her, she has no claim to maintenance, even if she intended to seek reimbursement. This is because, by travelling with her, she is acting wrongfully and exceeding her rights: she may not take the child travelling without her father’s permission, and he only permitted her to travel on condition that she bear the maintenance expenses gratuitously. Thus, if she travels and seeks reimbursement for those expenses, she has no right to it. And Allah knows best.