The data delivery in traditional dedicated short range communication (DSRC) based vehicular ad hoc network (VANET) can hardly meet the transmission quality of service (QoS) requirement. Data transmission through mobile gateway can definitely extend the broadcast area and significantly reduce the remote transmission delay. This paper proposes a novel VANET architecture and data delivery method accordingly, which combines the idea of mobile cloud computing. We firstly provide the registration procedure of gateway server (GWS). Then, by jointly considering the historical data and real-time information, a GWS selection method by cloud is proposed to dynamically decide the participating GWSs and their service area. After acquiring the service information from GWS, the gateway consumer (GWC) can choose the optimal GWS from its GWS list by jointly considering communication load, link stability, channel quality, etc, and transmit the data to the selected GWS which will then send the data to cloud. Simulations with different scenarios in OMNeT++ and mathematical analysis demonstrate that the proposed method can achieve lower transmission delay and higher delivery success ratio.