Copyrighted Material
Total Page:16
File Type:pdf, Size:1020Kb
21_785970 bindex.qxp 1/20/06 12:28 PM Page 337 Index >= (greater-than-or-equal-to) operator, • Symbols • function of, 54 + (addition) operator, function of, 52 ++ (increment) operator, function of, 52 += (addition sign, equal sign) operator, += (joining strings) operator, function of, 53 function of, 52 &= (ampersand, equal sign) operator, << (left shift) operator, function of, 53 function of, 53 < (less-than) operator, function of, 54 *= (asterisk, equal sign) operator, <<= (less-than sign, less-than sign, equal function of, 53 sign) operator, function of, 54 */ (asterisk, slash), writing PHP script >? (less-than sign, question mark), comments and, 301 enclosing PHP script in, 298 /= (backslash, equal sign) operator, <= (less-than-or-equal-to) operator, function of, 53 function of, 54 & (bitwise AND) operator, function of, 52 && (logical AND) operator, function ~ (bitwise NOT) operator, function of, 53 of, 52 | (bitwise OR) operator, function of, 52 ! (logical NOT) operator, function of, 52 ^ (bitwise XOR) operator, function of, 52 | | (logical OR) operator, function of, 52 ^= (caret, equal sign) operator, * (multiplication) operator, function function of, 53 of, 52 , (comma) operator, function of, 55 \n (newline character), in PHP , (comma), passing multiple arguments script, 319 to JavaScript functions, 47–48 != (not-equal-to) operator, function of, 54 ?: (conditional) operator, function of, 55 () (parentheses), passing single argu- -- (decrement) operator, function of, 52 ment to JavaScript function and, / (division) operator, function of, 52 44–45 $ (dollar sign), indicating PHP script %= (percent sign, equal sign) operator, variables, 301–302 function of, 53 // (double slash) marker, adding “” (quotation marks) comments to JavaScript with, 28–29 passing JavaScript functions and, 157 = (equal sign) operator, function of, 53 using in JavaScript, 36–37 == (equality) operator, function of, 54 ; (semicolon) > (greater-than) operator,COPYRIGHTED function of, 54 ending MATERIAL JavaScript lines with, 28 >>= (greater-than sign, greater-than sign, ending PHP script lines with, 28 equal sign) operator, function of, 54 # (sharp sign), assigning styles and, 274 >>>= (greater-than sign, greater-than >> (sign-propagating right shift) sign, greater-than sign, equal sign) operator, function of, 53 operator, function of, 54 /* (slash, asterisk), writing PHP script <? (greater-than sign, question mark), comments and, 301 enclosing PHP script in, 298 === (strict equality) operator, function of, 54 21_785970 bindex.qxp 1/20/06 12:28 PM Page 338 338 Ajax For Dummies + (string addition) operator, function Ajax Gold library of, 52 describing getDataReturnText - (subtraction) operator, function of, 52 function, 158–159 -= (subtraction sign, equal sign) describing getDataReturnXml operator, function of, 53 function, 162–163 |= (vertical line, equal sign) operator, describing postDataReturnText function of, 54 function, 166–170 >>> (zero-fill right shift) operator, describing postDataReturnXML function of, 53 function, 170 overview, 157 verifying loading and availability of, • A • 161–162 abort method Ajax Matters Web site, 332–333 Firefox and Navigator, 82 Ajax Patterns Web site, 332 Internet Explorer, 81 Ajax Tags Library, handling JavaServer Safari, 83 Pages with, 229–231 absolute positioning, of Web page AJAXLib framework, using, 174–176 elements, 292–295 alert box, overview, 69–71 absolute URLs, versus relative, 90–91 ampersand, equal sign (&=) operator, action attribute, setting in PHP function of, 53 script, 310 anonymous functions actions, responding to, 33 creating, 55 Adaptive Path Web site, 331–332 handling asynchronous downloads and, addem function 86, 111 creating JavaScript for use in browsers Apache Tomcat (Java-based server), 225 with Xajax and, 218–220 Apple Safari in Sajax, 215–217 alternate ways of retrieving XMLHttp in Xajax, 218–220 Request object in, 92–93 addition (+) operator, function of, 52 Web sites for XMLHttpRequest addition sign, equal sign (+=) operator, objects references, 333 function of, 53 XMLHttpRequest object methods “Ajax: A New Approach to Web for, 83 Applications” (Garrett), 11, 331–332 XMLHttpRequest object properties Ajax blogs, 333 for, 82–83 Ajax discussion group, 334–335 applications, autocomplete, 13–14 Ajax Gold Framework arguments overview, 157–158 passing multiple to JavaScript function, posting data to and retrieving text from 47–48 server with POST method, 166–170 passing single to JavaScript functions, posting data to and retrieving XML 44–45 from server with POST method, arithmetic operators, functions of, 52 170–173 arrays using GET method to retrieve text, overview, 66–67 158–162 retrieving data from text fields in PHP using GET method to retrieve XML, script and, 311–312 162–165 storing extracted XML data, 103 21_785970 bindex.qxp 1/20/06 12:28 PM Page 339 Index 339 turning text into, 282–283 bitwise AND (&) operator, function of, 52 while loop and, 67–69 bitwise NOT (~) operator, function of, 53 working with multiple XMLHttp bitwise operators, functions of, 52–53 Request objects and, 146–147 bitwise OR (|) operator, function of, 52 ASP.NET, 234 bitwise XOR (^) operator, function of, 52 assignment operators, functions of, block elements, overview, 45 53–54 blogs, Ajax, 333 asterisk, equal sign (*=) operator, bookmarks, Ajax disabling browser, function of, 53 325–326 asterisk, slash (*/), writing PHP script bottom property comments and, 301 absolute positioning function of, 293 asyncFlag parameter, for open relative positioning function of, 295 method, 84 boxes asynchronous downloads, handling, alert, 69–71 85–88 populating list with Direct Web Atlas Client Script Framework, 234 Remoting, 227 attributes property, function of, 244 positioning for, 292 autocomplete using PHP script with check, 312–314 capabilities, 13–14 browser events with JPSpan framework, 224 calling JavaScript functions and, 40–44 with Ruby on Rails framework, 233 common JavaScript in Ajax using Ajax Tags Library, 230 applications, 34 Autocomplete JSP tag, 230 working with, 35–36 browsers. See also specific browsers accessing from JavaScript, 26–27 • B • Ajax disabling back button in, 325–326 back button, Ajax disabling browser, Ajax disabling bookmarks in, 325–326 325–326 avoiding cache in, 329 Backbase framework, 234 avoiding sluggish, 328 background-attachment property, awareness of various, 327 function of, 289 calling different Web domains and, background-color property, 130–131 function of, 289 creating Ajax JavaScript for use in with background-image property, Xajax, 218–220 function of, 289 data validation in, 132 background-position property, determining if code will work with, 79 function of, 289 determining type with conditions, backgrounds, setting with cascading 62–64 style sheets, 289–292 downloading images with Ajax and backslash, equal sign (/=) operator, Dynamic HTML, 154–156 function of, 53 handling drag-and-drop events, 183 backup plans, for working offline, 328 handling mouse events, 185 bgcolor property, setting, 35–36 handling older with HTMLHttpRequest binary data objects, downloading with framework, 199–200 Ajax and Dynamic HTML, 156 identifying JavaScript errors and, 30–32 21_785970 bindex.qxp 1/20/06 12:28 PM Page 340 340 Ajax For Dummies browsers. See also specific browsers setting colors and backgrounds with, (continued) 289–292 JavaScript working with various, 32–33 styling text with, 287–288 listening for mouse move events, 187 channel property, Firefox and retrieving text with Ajax, 21–22 Navigator, 82 sending text to with PHP script, 299 chatting sending XML to with PHP script, Ajax-based, 14–15 299–300 with Direct Web Remoting, 227 setting up for debugging, 140–142 check boxes, using with PHP script, buttons. See also HTML controls 312–314 displaying messages by clicking, 69–71 checkUsername function, data reading text fields by clicking, 71–72 validation and, 133 retrieving data from server and childNodes property, function of, 244 displaying by clicking, 76–78 clearCache () function, in libXml Request framework library, 177 color property, function of, 289 • C • colors caching browsers understanding, 36 avoiding, 329 setting with cascading style sheets, controlling with libXmlRequest 289–292 framework library, 177 comma (,) operator, function of, 55 Http framework handling, 211–212 comma (,), passing multiple arguments Interactive Website Framework to JavaScript functions, 47–48 preventing, 198 comments callback functions adding to JavaScript, 28–29 defined, 157 in PHP script, 301 in libXmlRequest framework companion Web site, downloading library, 177 examples from, 22–23 posting data to and retrieving text from comparison operators, functions of, 54 server with, 166–167 conditional (?:) operator, function of, 55 retrieving text from URLs, 162 conditions working with Sajax and, 217 determining browser type in JavaScript Callout JSP tag, 230 with, 62–64 caret, equal sign (^=) operator, testing in JavaScript, 59 function of, 53 using JavaScript if statement and, cascading style sheets (CSS) 59–60 absolute positioning, 292–295 using PHP script else statement and, Ajax programmers’ fondness of, 269 307 coloring shopping cart and items with using PHP script if statement and, styles, 184–185 306–307 making Web page changes stand out, Couvreur, Julien (XMLHttpRequest 285–286 debugger developer), 140 overview, 270–271 CSS (cascading style sheets) relative positioning, 295–296 absolute positioning, 292–295 Ajax programmers’ fondness of, 269 21_785970 bindex.qxp 1/20/06 12:28 PM Page 341 Index