When a sentence needs two object pronouns at once, they follow a fixed order rather than the order they'd have in English: me/te/se/nous/vous, then le/la/les, then lui/leur, then y, then en. So "he gives it to me" is il me le donne, and "she talks to him about it" is elle lui en parle.
This order holds in negative sentences too, with ne and pas wrapping around the whole pronoun cluster: il ne me le donne pas. The one place the order flips is the affirmative imperative, where pronouns move after the verb and le/la/les come before me/te/lui/etc.: donne-le-moi (give it to me), not donne-moi-le.