I can't answer your question exactly, but here's an alternative possibility that works better for me in Safari or Firefox. Instead of opening multiple tabs on startup, which I find can be slow on my aging Macbook, I use the 'Top Sites' thing which appears when you start Safari, but is also very easy to edit. The default 6 to a page can be increased to 12 or 24 if you need them. You can drag them into any order you want, and make them permanent or delete them. Open a new tab or page, and by default, they're still there.
The other advantage of this is that it doesn't interfere with the useful facility that, if you quit Safari leaving tabs open, those tabs reappear on startup.