If you don't know her Apple ID passcode, you'll need to contact Apple with proof of original purchase and see if they can help you. Can you ask your daughter for the passcode? Or, if she doesn't want to give it to you, have her remove the phone from her account through icloud.com.
What to do before you sell or give away your iPhone, iPad, or iPod touch - Apple Support