After to post this question: Help with a proof in Hartshorne's book I realized that I have another doubt in this proof:

What I know is
$\varphi_p(s_p)=t_p\implies (\varphi_{V_p}(s(P))_p=t_p$
I don't understand why $(\varphi_{V_p}(s(P))_p=(t_{|V_P})_p$
NOTATION:
Instead of $\varphi(V_P)$, to simplify notation I write $\varphi_{V_P}$
Sorry to post the same proof again
Thanks a lot.
Consider the morphisms
It follows from the definition of a stalk that $\sigma_{X/P}=\sigma_{V_P/P}\circ\rho_{X/V_P}$ because $V_P$ and $X$ are both open neighborhoods of $P$. Look up the definition of a direct limit to confirm this, if you like.
In other words, the above statement means $t_P=(t|_{V_P})_P$. Now given what you know, this yields what you want to understand.
Edit I would write it down as follows: We may replace $V_P$ by $V_P\cap U$, then $V_P$ is an open subset contained in both $V_P$ and $U$. Hence, we have $t_P=(t|_{V_P})_P$. Thus, $\varphi_P(s_P)=t_P$ implies $(\varphi_{V_P}(s(P)))_P=t_P=(t|_{V_P})_P$.