Forms are a way of sending data input from users to the server. Various elements HTML are used to collect information through form.
When user submits form information, the names of form controls is sent to the server with the values (name attributes). Programming language is used to process that information in the server and can also store information in database. Depending on the information recieved and process, the server will create and send back a page dependent on the input.
form controls = name=value
< form > requires an action and method < input > requires type=text , name and maxlength refer to pp.153- 168
list-style-type/list-style gives different types of appearances for list marker.
style-type - bullet point style (disc,circle square) style- image - little tiny images (think chocolate pizza assignment type SMALL) style-position - inside/outside list-style = shorthand
width
padding
text-transform
letter-spacing, font-size
border-top, border - bottom
text-align
background- color (contrast is VERY useful especially with table data)
:hover (highlight table row when “hovered” over!)
NOTE: very cool infor on table styling pp 339-348
-vertically align form controls with CSS, styles can make forms more interactive.
Whenever a user interacts with a webpage in a specific way, the browswer registers what event has occured and sets off whichever code is created to react. While DOM (think creating a data table) updated a page in response to an event, a form can trigger an event as well.
Some examples of events:
events triggering JS
specifying the element the script should respond to -element
specify the event to trigger a response -event
specify the code which will run in accordance to event call code
DOM Handlers and DOM level 2 events bind events to an element. Event handlers and listeners cannot have () after the function name.
The event object delivers information about an event and its element.
REMEMBER to change default behavior(tossing information from event)
Event Object can tell you if event occured on screen,page of screen or client with specific properties such as x/y to pin position of where mouse was
Mutation Events and Observers - when elements are added or removed from DOM the structure mutates