וַיְצַו֩ יְהוֹיָדָ֨ע הַכֹּהֵ֜ן אֶת־שָׂרֵ֥י המיאות [הַמֵּא֣וֹת ׀] פְּקֻדֵ֣י הַחַ֗יִל וַיֹּ֤אמֶר אֲלֵיהֶם֙ הוֹצִ֤יאוּ אֹתָהּ֙ אֶל־מִבֵּ֣ית לַשְּׂדֵרֹ֔ת וְהַבָּ֥א אַחֲרֶ֖יהָ הָמֵ֣ת בֶּחָ֑רֶב כִּ֚י אָמַ֣ר הַכֹּהֵ֔ן אַל־תּוּמַ֖ת בֵּ֥ית יְהוָֽה׃
And Jehoiada the priest commanded the captains of hundreds, the officers of the host, and said unto them: ‘Have her forth between the ranks; and him that followeth her slay with the sword’; for the priest said: ‘Let her not be slain in the house of the LORD.’
Rashi
and with the corpses of their kings whose houses were near the Temple, as we find with Solomon and with Athaliah. Sometimes they would bury them in the gardens of their houses, as He explains and says, “... by placing their threshold with My threshold.”