Whilst exploring the internet, I’ve found a variety of different official scripts for Elvish. From my understanding of it, Rellanic is a generic one (not tied to a setting), and Espruar is Forgotten Realms. However, the 5e version of Espruar (PHB) is different from past versions. Is there an explanation for this?
The 5e Espruar alphabet is from past editions - it's 3e that's different!
As KRyan's answer notes, the elven alphabet in the 5e PHB is not and is not meant to be Espruar. However, the Thorass and Espruar alphabets given in the 5e Sword Coast Adventurer's Guide do differ significantly from the versions presented in the 3e Forgotten Realms Campaign Setting - they are actually using the same characters from the original versions of those alphabets as presented on page 8 of the 1e Forgotten Realms Campaign Setting box set handbook, Cyclopedia of the Realms:
Thorass and Espruar were dramatically redesigned in the 3e FRCS with no in-universe or, so far as I can tell, out-of-universe explanation given. From googling around to investigate, reception seemed a bit mixed; some people think the redesigned script was much better, others preferred the original version.
It is not clear why 5e has returned to the original version of Thorass and Espruar in SCAG, and whether that choice was deliberate or not (both versions of Espruar come up pretty readily if you google for it, so whoever was responsible for those images might have just picked one at random!) If it was deliberate, I would hazard a guess that it is because 5e made a big deal about returning to D&D's roots and trying to restore appeal to old 1e and 2e players, and the decision to use the classic FR alphabets plays into that.
Whatever the out of universe explanation is, I cannot find any evidence that a change in script has been noted in-universe, so one assumes that these changes must be considered retcons. If you're dead-set on a canonical explanation, I'd just chalk it down as another bizarre consequence of all the magical shenanigans that accompany every edition change.
Nothing in Player’s Handbook claims that the script depicted on page 123 with the caption “Elvish Script: Sample Alphabet” is Espruar—or any other named script. It’s just an example of what an elvish script might look like, hence “Sample Alphabet.” Also, officially, Forgotten Realms is not the default setting for D&D 5e (despite the myriad ways in which it kinda is).
So any similarities to or differences from Espruar in past editions is purely coincidental—it’s not supposed to be Espruar. Really, it looks much closer to Rellanic, which is what generic, non-FR 4e used for the elven script, though as far as I know 5e doesn’t identify the script by any name.