An open cage is safe, but there is really no way to know if your new pigs will try to climb out until you get them home. Most pigs are not climbers though. A lid is very easy to make if you find you need one. The cage you're describing, if it's made of cube grids with a coroplast base like is promoted on this site, is equivalent to a 2X3 cage. If you are getting 2 pigs, which would be a good idea, you want to look at something 2X4 or 28X56 inches or larger.
I'm sure your intentions are wonderful, but since I don't know you or your daughter, I want to mention one more thing. Animals as gifts are generally discouraged for children as they typically get bored with things rather quickly. Make sure you are prepared to keep up with the feeding, cleaning and other care of the pigs if this should happen. Also, the lifespan of a well cared for guinea pig can be 5-8 years, and sometimes longer. It's a big commitment to take on.