If $F[x]$ is a principal domain does $F$ have to be necessarily a field? If $F$ is a field, then $F[x]$ is a principal ideal domain.

Conversely, if $F[x]$ is a principal domain does $F$ have to be necessarily a field?

My Thoughts: Suppose instead of $F$, we take the set of polynomials $R[x]$ over a commutative ring $R$ with unity.
Then, suppose $I$ is an ideal of $R[x]$. Let $g(x) \in I$ such that $g(x)$ is the polynomial of the lowest degree in $I$.
Then: $ \langle g(x) \rangle \subseteq I .......... (1)$
Let $f(x) \in I$. Then $f(x) = p(x)g(x) + r(x)~~|~~p(x),r(x) \in R[x], \deg r(x) < \deg g(x)$
Since, $I$ is an ideal $\implies f(x) - p(x)g(x) = r(x) \in I$
But, $g(x)$ is of the lowest degree in $I \implies r(x) = 0 \implies f(x) \in \langle g(x)  \rangle \implies I \subseteq \langle g(x)  \rangle ......(2)$
Then from $(1),(2) : I = \langle g(x) \rangle$
Does the Presence of zero divisors in $R[x]$ really make a difference? The only advantage I see is that if there are no zero divisors in $R[x]$ then $I=\{0\} \implies I= \langle 0  \rangle$.
But, every ideal contains the zero element. Why is there the condition of a field specifically given in textbooks for $F[x]$ to be a principal ideal domain?
Thank you for your help.
 A: Yes it does. For if not the ideal $(x)$ would not be maximal, and every prime ideal in PID is maximal. This goes through the characterization of a maximal ideal as $M\subseteq R$ is maximal iff $R/M$ is a field.
In our case it's easy to see that:
$$F[x]/(x)\cong F$$
So the result is pretty immediate.

If you'd like the proof of "PID implies all (non-zero) prime ideals are maximal." It's pretty straightforward:
Proof:  Let $\mathfrak{p}=(p)$ be a non-zero prime ideal of a commutative ring, $R$ with $1$. then if $\mathfrak{p}\subseteq M\subseteq R$, then if $M=(x)$ we have that $x|p$ hence is either a unit or $p$ itself by definition of a prime.

Addendum (where you went wrong):  You do not necessarily have a division algorithm in an arbitrary polynomial ring, $R[x]$, since $R$ not a field means that the coefficients are not all units (i.e. the ring is not Euclidean). Take $R=\Bbb Z$, then you do not have the desired factorization with only integer polynomials for something like $3x$ and $2x$, since the difference cannot be made to have lower degree.
This generalizes to any non-field since you can find some non-unit somewhere to pull the same thing on.
