With interior: yes. Fix a sequence of squares $Q_1\supset Q_2\supset\dots$ whose union is the entire plane. Then arrange a map $g:\mathbb R\to\mathbb R^2$ such that, for every nontrivial segment $[a,b]\subset\mathbb R$, its image is one of the squares $Q_i$. To do that, construct countably many disjoint Cantor sets, and send every Cantor set $K$ bijectively onto $Q_n$ where $n$ is the maximum number such that $K$ does not have points in $[-n,n]$. Send the complements of these Cantor sets to a fixed point inside $Q_1$. Then define $f(x,y)=g(y)$.

(This is a detailed version of gowers' answer.)

UPDATE

Without interior: no. Take any triangle $T$ and consider its image $Q$ with vertices $ABCD$. There is a side $I$ of $T$ whose image has infinitely many points on (at least) two sides of $Q$. If these are opposite sides, say $AB$ and $CD$, the image of any triangle containing $I$ must stay within the strip bounded by the lines $AB$ and $CD$. And if these are two adjacent sides of $Q$, say $AB$ and $AD$, the image of any triangle containing $I$ stays within the quarter of the plane bounded by the rays $AB$ and $AD$. In both cases, the images of the triangles containing $I$ do not cover the plane, hence the map is not onto.