If $X$ is a Peano spaces with more than one point, and $Y$ is any Peano space, there exists a continuous map $f$ from $X$ onto $Y$.
Also, if $a,b$ are distinct points in $X$ and $c,d$ are distinct points in $Y$, the map $f$ can be constructed so that $f(a) = c, f(b) = d$.
My Attempt: I tried to solve the 1st part by use the Hahn-Mazurkiewicz Theorem to construct a function $f$ as-
Let $\phi_X:I\to X$ and $\phi_Y:I\to Y$ be the continuous onto functions which exist by the Hahn-Mazurkiewicz Theorem. Then, let $f:X\to Y$ be defined by the relation - $\phi_Y = f\circ \phi_X$.
However, I was not able to either justify that $f$ was continuous, or was even a well-defined function.
Any help is appreciated!
Since a Peano space is metrizable, it is perfectly normal. Wikipedia - Normal Space. Thus there is an $a-b$ separating continuous map $\sigma: X \rightarrow [0,1]$ such that $\sigma(a) = 0$ and $\sigma(b) = 1$. Because $X$ is connected, the map $\sigma$ must be surjective, so $\sigma(X) = [0,1]$.
Since $Y$ is the continuous image of a path-connected space (per Hahn-Mazurkiewicz), it is path connected. So there is a path $\lambda: [0,1] \rightarrow Y$ such that $\lambda(0) = c$ and $\lambda(1) = d$.
The composition $f = \lambda\circ\sigma:X\rightarrow Y$ is the map you want.
EDIT: Fixed the order of composition.
EDIT 2: To make $f$ surjective, we must do a bit more work. Since $X$ is normal and connected, we again get a surjective, continuous $\sigma : X \rightarrow [0,3]$ such that $\sigma(a) = 0$ and $\sigma(b) = 3$. (This is called a Urysohn map I think).
By Hahn-Mazurkiewicz, there is a continuous surjection $\lambda_{HM}: [1,2]\rightarrow Y$. Let $s=\lambda_{HM}(1)$ and $t=\lambda_{HM}(2)$. Since $Y$ is path connected, there are paths $\lambda_{cs}:[0,1]\rightarrow Y$ and $\lambda_{td}:[2,3]\rightarrow Y$ such that:
$\lambda_{cs}(0) = c$, $\lambda_{cs}(1) = s$, $\lambda_{td}(2) = t$ and $\lambda_{td}(3) = d$.
Thus, by the glueing lemma, we can paste the three $\lambda$ maps together to get one continuous map $\lambda:[0,3]\rightarrow Y$ that agrees with $\lambda_{cs}$ on $[0,1]$, $\lambda_{HM}$ on $[1,2]$ and $\lambda_{td}$ on $[2,3]$. This map is surjective since $\lambda([2,3]) = Y$, $\lambda(0) = c$ and $\lambda(3) = d$.
Now $f=\lambda\circ\sigma: X\rightarrow [0,3] \rightarrow Y$ is the map you want.