A video of this class is (or will be) posted at: http://echo360.uml.edu/heines201516/guiprogramming1.html
Simply add an href attribute to the underlying HTML
<li><a href="CourseDescriptionPanel.html">Information</a></li>
The Website
The HTML to set up the tabs widget interface
The modified CSS file to style the website as I wished
What are they and why are they important?
ls -l *.cppls -l assn?.cppRegEx Components
/.*(\d{3}).*(\d{3}).*(\d{4}).*/replace function
var strFormattedPhoneNumber = strPhoneNumber.replace( /.*(\d{3}).*(\d{3}).*(\d{4}).*/, "($1) $2-$3" ) ;RegEx Example
Normal characters
Character classes
[aeiou][a-z] or [0-9][a-zA-Z0-9]true if it finds any one of the characters in a character class in the search string
5[1-5]\d\d\d\d\d\d\d\d\d\d\d\d\d\d(see below)
5[1-5]\d{14}
Pattern Metacharacters
Metacharacter Interpretation Example .Matches any single character except newline ".ba" matches barbara and yabba [cccccc]Matches any single character listed in this set "[Vv]ariable[12]" matches variable1 and Variable2 [^cccccc]Matches any single character not listed in this set "value[^01]" matches valuex and value2 but not value1 or value0 [c-c]Matches any single character within the range in this set "age[5-8]" matches age5, age6, age7 and age8 $Matches the end of a string (or line if the "m modifier is used) "txt$" matches test.txt but not test.txtfile ^Matches the beginning of a string (or line if the "m modifier is used) "^ja" matches javascript and java but not Wow, Java’s cool! *Matches 0 or more of the preceding regular expression "value[0-9]*" matches value1, value10 and value +Matches 1 or more of the preceding regular expression "value[0-9]+" matches value1 and value999, but not value ?Matches 0 or 1 of the preceding regular expression (i.e., optional) "html?" matches html and htm {quantity}Matches exactly quantity of the preceding regular expression "value[0-9]{3}" matches value001, value010 and value123, but not value1 {min,max}Matches at least min but no more than max of the preceding regular expression "value[0-9]{3,5}" matches value001, log0011 and log12345, but not log35 |Matches either the expression on the left or the right of the | "Mr\.|Mrs\.|Ms\." matches Mr. or Mrs. or Ms.
Escape
SequenceInterpretation \'Single quotation mark \"Double quotation mark $The $ sign \aAlarm (a small bell sound) \bBackspace \eEscape \EEnd \L, \Q, or \U \fForm feed \lLowercase next character \LLowercase all following characters until \E \nNew line \QBackslash all following non-alphanumeric characters until \E \rCarriage return \tTab \uUppercase next character \UUppercase all following characters until \E \\Single backslash
- RegEx escape sequences
Escape
SequenceInterpretation \AMatch the beginning of a string (same as ^ if /m is not used) \BMatch a non-word boundary \bMatch a word boundary (between \w and \W) \cxMatch control character x (for example, \cC matches Ctrl/C) \dMatch a digit character [0-9] \DMatch a non-digit character [^0-9] \nnnAn octal ASCII value \sMatch a white space character [ \t\n\r\f] \SMatch a non-white space character [^ \t\n\r\f] \wMatch a “word” (alphanumeric) character [a-zA-Z_0-9] \WMatch a non-word character [^a-zA-Z_0-9] \xnnA hexadecimal ASCII value \ZMatch the end of a string or before a new line (same as $ if /m is not used) \zMatch the end of a string
\ ^ . $ | ( ) [ ] * + ? { } ,Syntax
var re = /ab+c/ ;Note that there are no quotes!
RegExs can be used with
exec and test methods of RegExpmatch, replace, search, and split methods of StringString variablesnumber rule allows decimalsdigits rule does not allow negative numbersinteger rule
Implementing Scrabble with drag-and-drop
You are welcome to help each other with graphics. For example, here is part of a row containing blank squares and double word score squares:
Please Note