Layla just got hired as the Web developer for a small business called Axe Grinders, which sells and repairs guitars and amps. The aging rock ‘n’ rollers who own Axe Grinders were taking care of business by phone and mail, but they just don’t have too much time on their hands for this anymore. They decided they need a Web site so they could start processing orders more efficiently, spend their time on guitars, and get the business back in black.
These guys know music inside and out, but their guitars gently weep when it comes to Web sites. They don’t need no education about the Web, so they hired Layla to do the job for them.
Layla’s new bosses are same as her old boss. Part of the reason they hired her was because they thought it would be nice to have a pretty woman around the office. Layla doesn’t want to be paranoid, but she is determined to prove that she’s got brains and she knows how to use them.
On her first day, the owners tell Layla that they’d like their site to have some high-voltage effects. And because they have sold guitars to several celebrity musicians, they want a feature that can list their customers along with the guitar types they bought — users could either select a specific customer or guitar, or they could list ’em all. The owners have seen some other sites do something like this, so they know it is possible, but they wonder if she can make it happen. They tell her it is okay if she can’t handle this task — it’s just another brick in the wall. They could get satisfaction with just a plain HTML site instead, even though it would have to be updated constantly.
As she’s climbing the stairway to her office, Layla realizes that scripting the Customer List feature will require more than the usual predefined JavaScript objects. And she knows that the code for the Customer List feature will include a lot of repetition. She is determined to make these features work as requested. Layla knows she’s got to ramble. Because even though the owners said it would be ok to have a simpler site, she would really like to impress them.
Discussion Points:
Consider this scenario and answer the following questions. •low can Layla use JavaScript custom objects to create the Customer List feature for the Web site? •low do custom objects help Web developers with repetitive programming tasks such as the ones in the Customer List feature? •What other advantages do custom objects offer to Layla in this situation? •What are the first steps Layla should take in creating a custom object for this feature?