Capillary bridges can form between colloids immersed in a two phase fluid, e.g., in a binary liquid mixture, if the surface of the colloids prefers the species other than the one favored in the bulk liquid. Here, we study the formation of liquid bridges induced by confining colloids to a slit, with the slit walls having a preference opposite to the one of the colloid surface. Using mean field theory, we show that there is a line of first-order phase transitions between the bridge and the no-bridge states, which ends at a critical point. By decreasing the slit width, this critical point is shifted towards smaller separations between the colloids. However, at very small separations, and far from criticality, we observe only a minor influence of the slit width on the location of the transition. Monte Carlo simulations of the Ising model, which mimics incompressible binary liquid mixtures, confirm the occurrence of the bridging transitions, as manifested by the appearance of bistable regions where both the bridge and the no-bridge configurations are (meta)stable. Interestingly, we find no bistability in the case of small colloids, but we observe a sharpening of the transition when the colloid size increases. In addition, we demonstrate that the capillary force acting between the colloids can depend sensitively on the slit width, and varies drastically with temperature, thus achieving strengths orders of magnitude higher than at criticality of the fluid.