This is taken from Rotman's Algebraic Topology:
In the red box in the image above, how are $\bar f \Phi_e$ and $\tilde G(\Phi_e \times 1)$ defined in terms of domain and codomain?
By definition, $\Phi_e : (D^n, S^{n-1}) \rightarrow (e \cup X^{n-1}, X^{n-1})$ and $\tilde f : X \rightarrow E$. So it doesn't seem like the two functions can be composed.

$\Phi_e$ is just the characteristic map of $e$. It goes to $X^{(n)}$ (more specifically, $e \cup X^{(n-1)}$ as he writes, but this is a subset of $X^{(n)}$ and then there is no issue with composing).
You have two functions $\alpha:A \to B$, $\beta:B' \to C$ and $B \subset B'$. The composition $\beta \circ \alpha$ is valid.