The link at the first of the questions you mentioned probably has a counterexample, but I don't have any books handy, so it's easier to write down the following example than to look it up. Let $I$ be an index set of cardinality strictly greater than $|\mathbb R|$, and let $X=\{0,1\}$ with the discrete topology. I claim that $X^I$ is not separable. To prove it, consider any countable subset, say $\{x_n:n\in\mathbb N\}$ of $X^I$. Each $x_n$ is, by definition of product spaces, a function $I\to X$, and I'll use the notation $x_n(i)$ accordingly. For each $i\in I$, define a function $f_i:\mathbb N\to X$ by $f_i(n)=x_n(i)$. Recall that the number of functions $\mathbb N\to X$ is $|\mathbb R|$. Since $I$ has larger cardinality than that, there must be two (in fact many more but I only need two) elements $i\neq j$ in $I$ with $f_i=f_j$. This means that $x_n(i)=x_n(j)$ for all $n\in\mathbb N$. Now consider the basic open subset $\{y\in X^I:y(i)=0\text{ and }y(j)=1\}$. It is a nonempty open subset of $X^I$ but it contains none of the $x_n$'s; therefore, $\{x_n:n\in\mathbb N\}$ is not dense in $X^I$.