I'm not certain that the events in Sunnydale and in Africa were supposed to be happening simultaneously or if it was just presented that way for dramatic effect, but even if the latter were the case, I just can't see Spike's trip as the spontaneous thing that we were supposed to be seeing. He knew where to go, who to see when he got there, and, just as importantly, how to get there and get back in the shortest amount of time. Possibly that "shortest amount of time" actually did involve some sort of magical transference or teleportation. If so, considering the First Evil's interest in, and apparent plans for, Spike, it's a fairly safe bet that it had something, either directly or indirectly, through some minion, to do with the process, especially when you consider Spike's mental condition directly after receiving his soul. I can't see any way that Spike, in that condition, could have possibly accomplished the return round trip from Africa to Sunnydale under his own power with no assistance.
So, short answer: I think that the First Evil, working through some agent or agents, got Spike to Africa and back again, as well as giving him the initial information about being able to regain his soul in the first place, and did so almost certainly some time BEFORE the events in "Seeing Red" took place. The attempted rape simply served as the catalyst to initiate his quest.
And, if that theory is correct, it brings up a second question: Why was the First Evil so interested in ensouled vampires, first Angel and then Spike, in the first place? (But that's a totally rhetorical question, and has nothing whatsoever to do with this thread)