IP356F13A JavaScript – Session Three Notes

Consider this picture.

Learning Cycle

Can you see how this applies to what you are doing before our sessions and while we are together?

Please reply with a comment about our third session on JavaScript.

Highlights / Metacognition

  • What did you think was the most valuable thing that happened for you tonight?
  • What did you learn from that?
  • What will you do with that knowledge?

Questions?

  • Now that we’ve had our third session, what do you want to know?
  • What could we have done better?

If you spot a question from someone else and you can answer it – please do.

Advertisements

7 thoughts on “IP356F13A JavaScript – Session Three Notes

  1. […] Optional but sincerely appreciated – you can reply to the questions in IP356F13A JavaScript – Session Three Notes […]

  2. I liked learning how to construct functions. It was very valuable for me to be able to put the code in jsbin and work together as a class to manipulate it. I find that I can understand it a lot better when I can see the immediate outcome of the code.

    I’m completely new to Javascript, so this is very foreign to me. After this course is over, I don’t know if I will be able to write javascript, but I think now I will be able to read it and understand what is going on.

    I’d like to learn about making forms, and just a brief idea of what happens when someone fills out a form- where does the info go? Is that even done by javascript?

    Hands-on activity really works for me, and I’d like to see more of it! Great class!

    • JimUBC says:

      Hi Shantala,

      Thanks for posting this. It’s really useful feedback for me. It’s good to know that using jsbin is working for you and to have your insights as to why that approach works for you.

      A very brief thought about forms (we can talk about this in class too):
      Typically when someone fills in a form and clicks the a button to submit the data, this sends the data within the form to the web server. This is usually in the form of a request for another page (submit the data and request an acknowledgement). The data is processed at the web server.

      JavaScript (client side JavaScript) is often used to test the validity of the data in the form before the page is sent to the web server. JavaScript can also be used in forms to help a user submit reasonable data by providing user interface cues like dynamically generated drop-down lists. We can talk about these ideas in class on Wednesday.

    • Garda Logawa says:

      Hi Shantala, as Jim mentioned, in forms, JavaScript is mostly used to validate user’s input (ex: check if a field is blank, check if email field has “@”).

      In today’s practice, forms are commonly found inside an HTML page that contains:

      1. HTML providing the page’s content and structure.
      2. CSS managing the appearance of the page.
      3. JavaScript to validate the user’s input / reset form (everything client related).
      4. PHP codes to process input variables (server side), which may include:
      5. SQL codes to relate the variables to a database (server side)..

      For example: http://www.giigle.com/search.php?question=whale. the page “search.php” probably contains a form that has an input field to a variable called “question”, then a user input “whale” then submitted the form.

      I hope that helps to give you the big picture.

  3. Garda Logawa says:

    There are several things that I feel most valuable last week. Passing parameters to functions, creating a dynamic div with innerHTML, and iteration. The explanation about variables and function scope was very easy to be understood. Also, as Shantala mentioned, Hands-on activity is really great.

    I started programming since the very early days with GWBasic and it’s really great to see the change in how we communicate with the computer. I remember the early days when we were wondering if one day there will be a dynamic programming language which does not need to be compiled and can run in almost any platforms.

    Looking forward to today’s class and hoping to learn and try more features of JavaScript.

    More than that, although a bit outside of the JavaScript topic, I’d like to share that I have been having difficulties for months with 3G/GPRS data transfer between embedded systems and cloud servers. FTP didn’t work because my system doesn’t allow opening more than 1 connection, and sending sql commands isn’t viable because of super small memory limit. Last week’s class made me realize that I’ve been thinking too complicated and I can actually send the data through http port just like HTML forms.

  4. […] IP356F13A JavaScript – Session Three Notes (jimubc.wordpress.com) […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s