Help with /execute in

I need help with making a function that teleports a player to the Nether/End and creates a platform below them on a set Y level, but for whatever reason it only works when in said dimension; when run in the Overworld there is no platform generated
Continue to help post