2.4. Diagramming the Break Neck appNow that you know how customers will use the Break Neck app, let's take a look at what actually has to happen behind the scenes. Customer's Phone NumberOnce the customer enters their phone number, a JavaScript function is called.The JavaScript sends the customer's phone number to the server, and asks for that customer's address. JavaScript Customer's AddressThe server looks up the customer's address and returns it to the browser, without any HTML. Customer's Order While the server is looking up the customer's address, the customer types in his pizza order.When the customer clicks "Order Pizza", his order and information are sent to the Break Neck server.The browser calls a JavaScript function, which then updates the web page with the customer's address.The server places the order and creates a delivery request..The delivery request has the customer's order and correct address on it. Man, Break Neck pizza rocks. There's nothing like a breakfast of cold pizza, a whipped latte from Starbuzz, and the Webville Times to read. |