No chance at all in the manner described.
Its simple really, the pressure within the explosion radius is higher than the pressure outside. The pressure is high because everything was heated very rapidly in the explosion.
To reverse the outward motion induced by the higher pressure, you would have to either 1) apply greater pressure outside the explosion radius or 2) Suddenly massively cool everything within the current blast radius to lower the pressure (or a combination of these effects).
1) How can you apply greater pressure? You would have to have a pressure vessel of some form, or I suppose if you could invoke Star Trek force fields (very unlikely physics). Besides if you had such magical force fields, why wouldn't you simply employ them. There is also nothing in known physics suggests such force fields are possible.
The answer already supplied suggesting underwater/underground explosion is actually a suggestion to use water/ground pressure as the containment vessel for the explosion. This would not behave as you described, but it is probably about as close as possible in the real world.
2) You cannot cool something like an explosion with anything close to realistic physics. You can make stuff explode because you can release a great deal of energy via a violent chemical or nuclear reaction, but to remove heat from a system, you must dump the heat into a lower temperature region - or create an endothermic reaction (another form of heat dumping actually), however there is no known endothermic reaction that could affect the explosion as needed. Theory strongly suggests that such an exothermic reaction is simply impossible. Melting ice, or dissolving ammonium chloride or real-world examples of endothermic reactions which inherently have much less potential energy change than strong exothermic reactions, much less nuclear reactions.
Implosion bombs are used in science-fiction solely because they sound futuristic, not because they could exist short of Star Trek force fields, but why bother with them if you have that?
Re: extreme planetary conditions, very thick and/or cold atmospheres. As you approach extreme conditions, gas does begin to resemble liquid and you could see at least see some similar effects, but not really the same effects as an underwater/underground. Such extreme conditions would naturally preclude humans living on them of course.
The difference is that you are creating a phase change of water (or rock) into gas, and once the explosion has cooled sufficiently, it reverts to it initial phase state - this is the true source of the explosion collapse. Converting water to steam is roughly an expansion of 1700:1, so when steam changes back to water, it collapses by 1700:1.
Even under extreme atmospheric conditions, if you start off in the atmosphere a gas, then undergo an explosion the net result after cooling back off is also a gas. So, no collapse due to a phase change.
High pressures / low temperatures would reduce the blast radius, but not really change the nature of the explosion.