Joonas's answer is entirely correct, but to add one note:
Sometimes it is possible to, apparently, combine prepositions in Latin. For example, a punishment ex post factō comes from (ex) a law created (factō) after (post) the action itself happened, with two prepositions (ex and post) in a row.
However, when this happens, it's usually (always?) because one of the prepositions is being treated as a prefix instead. In this example, the law is postfactum ("created-after"), a single word, and so the punishment is coming ex postfactō, "from a created-after". This is why we see factō (ablative from ex) instead of factum (accusative from post).
In this case, the simplest solution is ante priorem, "before the former". But if you want to derive something from what happens before the former, you could potentially turn that into a single word, anteprior ("pre-former"), and derive something ab antepriori "from the pre-former".