a case where contraction of a principal ideal is principal Let $K$ be a field and $R_1,\cdots,R_n$ DVRs of $K$ with $m_i$ the maximal ideal of $R_i$. Define $A=\cap R_i$. Then $A$ is semilocal with maximal ideals $p_i=m_i \cap A$. Also, $A_{p_i} = R_i$. 
Question: How can we see that $p_i$ is principal?
My effort: certainly $m_i$ is principal and in view of the isomorphism $A_{p_i} \cong R_i$ we have $p_i A_{p_i} = m_i = x_i A_{p_i}$ and we can take $x_i$ to be in $A$. Then $x_i$ is inside $p_i$. Now for every $y \in p_i$ we have $y s = a x_i$ with $s$ not inside $p_i$. That's as far as i got.
Reference: Theorem 12.2 in Matsumura.
Note: Matsumura's argument is unclear to me.
 A: Note: This is edited to correct a blunder pointed out by YACP in comments below.

Let $J := p_1 \cap \cdots \cap p_n$; this is the Jacobson radical of $A$.
Note that the inclusion $J p_1 \subset p_1^2 \cap p_2 \cap \cdots \cap p_n$
is an equality (check after localizing at each $p_i$).  Thus the Chinese Remainder Theorem shows that $p_1/J p_1 \cong p_1 /p_1^2 \times A/p_2 \times \ldots \times A/p_n,$ which is $\cong m_1/m_1^2 \times A/p_2 \times \ldots \times A/p_n$, 
and hence is a cyclic module. (If $C_i$ is a collection of cyclic modules over the rings $A_i$, then $\prod C_i$ is cyclic over $\prod A_i$ (a cyclic generator
is given by taking a product of cyclic generators).  By Nakayama, we see that $p_1$ itself is cyclic,
i.e. a principal ideal.  The same argument applies to each $p_i$.
Some more details added at OP's request: $p_1$, $p_2$, etc. are distinct maximal
ideals, thus each pair $p_i, p_j$ ($i \neq j$) generates the unit ideal.  Then $p_1^2, p_2,\ldots, p_n$ have the same property, and so CRT gives $A/Jp_1 = A/(p_1^2 \cap p_2 \cap \cdots \cap p_n) = A/p_1^2 \times A/p_2 \times \cdots A/p_n.$
Thus the image of $p$ in  $A/ J p_1,$ which is equal to $p_1/J p_1$,
is equal to the ideal generated by $p_1$ in the product.  In each $A/p_i$ ($i > 1$) we have $p_1$ generates the unit ideal, and so we see that $p_1 / J p_1$
equals $p_1/p_1^2 \times A/p_2\times \cdots \times A/p_n$, as claimed.

A variation of this is as follows: a Dedekind domain with only finitely many prime ideals is necessarily a PID, by the same Chinese Remainder Theorem argument.  Note that this gives a proof of the infinitude of primes: if it were false,
then by general Dedekind domain theory, each ring of algebraic integers
would again only have finitely many prime ideals, and hence would be a PID.  But e.g. $\mathbb Z[\sqrt{-5}]$ is easily checked to not be a PID, and so there must actually be infinitely many primes!  (This proof is due to Larry Washington, see here.)
