Week | Information |
---|---|
Assignments due in one week unless otherwise stated. I may add some things during the week, so double check the schedule each week! Please keep copies of all work you submit until you receive your final grade at the end of the semester. | |
Unit #14 |
Here are three working models of a JavaScript/XHTML quiz: quiztotry1 testquiztotry1 quiztotryall1 This week I am giving you a project that will also be a major part of the final (graded as a project and as part of the final). I would like you to modify one of the sample quizzes so it is a quiz for this class which means questions about this class and it should be written in PHP. You need to take in information about the user so you can set up a record in a table for them with the points they got and their grade. You then need to send the instructor and the student an email giving them their grade. The student has to login in with their userid and if they have already taken the quiz they should be told that they cannot take it again. For extra credit you can take the questions randomly from a database so everyone will get a different quiz. For extra credit you can also figure out how to time the quiz and only give a certain amount of time to take it. We will look at session information (see examples). I want you to look at information about sessions: Session Notes - start Session Notes Assignments: Homework: Do something with sessions where you pass information from one page to another and end the session and then try to pass. Start working on the project described above. |
Unit #13 |
We will continue with email this unit. Please check back to see where we are. Email database examples We are going to spend some time working with functions: Function examples Implode etc String functions Format Assignments: I want you to take the programs that I went over in the collection above, and try it yourself. You should write a program to create a table, write a program to gather information, write the program to put the information on the database table and thank the person who provided the information. You should finally write a program to do a mass mailing to your table with multiple people in the table. Decoding challenge: I want you to decode a word and return the decoded result. You need to use explode for this assignment. Take in the code dtgcm and find the location of each in the alphabet (I want you to explode the alphabet into an array). When you find the letter, back up by 2 and retrieve that letter to decipher the code. That means the result will be break because backing up 2 letters from d gets b and backing up two letters from t gets r etc. We ended up doing this in class, I want everyone to pass in the correction that will make this work if you enter a or b (a should get y and b should get z and that will not happen with the current code. Decoding problem |
Unit #12 |
This week we are going to start looking at email from PHP. Email examples When you make your email, please remove my addresses and only send me things you are submitting for a grade! Assignments: Send me one or more emails that include the features we went over: images, tables, text etc. Check back! |
Unit #11 |
Please finish up looking at images, some research on the web etc and the image assignment is posted. This unit we are going to start to look at images and go through my collection of image examples. We will start to look at email as well. Check back! Assignments: Quiz on databases and images Please be sure to experiment with arrays and databases and storing the address in the array and retrieving it etc. |
Unit #10 |
Please continue looking at the connect examples I posted and check back. This unit we will start to look
at maintenance from within a PHP script. I have put out examples of creating and dropping a table and
adding, changing and deleting records from the table. There is a Smartboard and an accompanying brief audio. Examples are under examples, but the changes I made are included in a folder within this zip. Zipped examples Assignments: Your assignment is to create a table using php script. The table should have 5 fields with an least one numeric field. You then need to populate the table with at least 5 records. Next, I want you to write code to update your database table. I want you to let the user choose whether they want to add, change or delete (this means presenting all choices and acting on their decision). I then you want to take in the needed data and make the add, change or delete happen. I want yours to be far better than my update, in other words you should be able to update all but the key field. If your update is basic like mine, the maximum grade is a B. |
Unit #9 |
Please remember the audio versions of the lecture and the accompanying Smartboard. If something is confusing,
give them a try. This unit we will talk a little about arrays and get back to making a connection to the database. Numbering systems (for reference) Examples using rainbow colors More array examples Note: I came across a problem inserting an array value in the string we wanted to put out with echo or print. A little research shows the solution - you need to enclose the value coming from the array in curly braces. echo("$ct1 + $ct2 = {$mathArray[$ct1][$ct2]}<br>");Connect introduction zipped examples connectfirstS10.doc Here are some handouts that contain the code for some of the examples: Connect examples Connect examples cont More connect examples We will look at the examples in this zipped collection: Second set of connect examples Examples Spring 2011 Assignments: The assignment this unit is to experiment with arrays and experiment with connecting: Array assignment: Write a program that experiments with foreach, isset, unset, associative arrays. Connect assignment: Write a series of programs that have different SELECT statements that meet the following criteria. #1: Write an SQL that selects data using the condition A and either condition B or condition C. #2: Write an SQL that uses grouping and the where to exclude records from the group and a having to exclude groups. #3: Write an SQL that uses a subquery. |
Unit #8 |
We will start the unit looking at arrays and functions and some more at connections. Please reference information in the text. Assignments: Array assignment I want you to write a program similiar to the one I wrote which can be run from: Math Array The statements Multiply by 0, Multiply by 1 are stored in a one dimension array and displayed. You need to extract the message from the array and display it before you show each group. You are going to display the math facts and the answers. The answers need to be stored in a two dimensional array. Set up a two level table to print out the math facts and get the answer from the two dimensional array. The two multipliers are the indexes that allow you to extract the answer. I used a nested while loop to do this. I would also like you to write a program of your own design that uses arrays. |
Unit #7 | This is the half way point in unit assignments! We covered a lot of SQL and normalization concepts pretty fast, so if you have questions lets go over them. Please read chapter #4 which gets into loops. We will be looking at loops this week. We will then move on to looking at MySQL and PHP (an loops are involved here). Connect introduction zipped examples connectfirstS10.doc Please read chapter #4 which gets into loops. We will be looking at loops this week. Over break please try to become comfortable with MySQL and the basics of connect. We will do more with connection the week after break. I also want to get to arrays! Assignments: SQL play computer assignment Write a program or programs to demonstrate three kinds of loop structures. In addition, I want one nested loop (a loop within a loop) and one three level nested loop (a loop within a loop within a loop). I want you to think up a reasonably complex project to demonstrate in rather then loops for the sake of loops. |
Unit #6 |
This unit, we will finish with the basics of MySQL (some things from last units notes) and our very brief overview of a
relational database. You should also look at the additional information
about relational databases and normalization at this site and on resources on the web and spend
time on that this unit. Read this example: Payroll Database Example Assignments: Do the database above - the payroll database example. Create the structure and put in your own data. Remember no embedded spaces in field names and stick to _ as a special character. Queries for payroll database example Design and develop a database that has at least three tables with one or more of them in a one to many relationship. A many to many relationship would also be great. Lay out the tables, the keys and the relationships. I suggest you do something work related so you can relate to its purpose and use. Implement the database with your data and then query the database in a variety of way. |
Unit #5 | We will continue looking at MySQL this week. Notes: Keys, indexes etc. Subqueries Multiple tables Functions Assignments: MySQL assignment: Second SQL assignment Again, for those who took Oracle, please notice the similarities and differences. |
Unit #4 | This week we are going to start looking at MySQL. I want to get the fundamentals of bot PHP and MySQL out of the way! Your book covers this I think in chapter #9, so... We are starting to look at MySQL. First we are going to look at it through putty and then we will incorporate it into PHP. You will be accessing MySQL on the cisweb server. Information about MySQL is available at their web site. MySQL site Information about using it at BCC is on this handout. Using MySQL on the cisweb server Note: You will need your cisweb username and password. If you have not gotten it yet, contact me. You should also get a copy of PuTTY to use with MySQL if you plan to work from home. PuTTY is available in the labs. Two sites that can be used to download PuTTY are: PuTTY PuTTY Here is an example sheet for use when you are creating databases and tables in putty: Using putty to create a database and table Here is another example sheet for use when you are maintaining and doing queries similiar to the ones I have assigned. Using SQL with MySQL You should be looking up tutorials on SQL. Two that I think are good are: SQL Tutorial (based on MySQL) A Gentle Introduction to SQL This is especially helpful for someone who has had Oracle because it shows comparisons between the two versions. You are allowed to have two databases (each can have multiple tables), under your cisweb. I have sent the names of the databases to your BCC accounts. Beginning MySQL notes Data types More SQL Assignments: SQL assignment Note that in the sample, I took an example I had used in Oracle. You need to check out how to do the date in MySQL. |
Unit #3 | Start looking at the Boston Tea Party game and if statements this week including additional structures. You should download the
decisions and decisions plus examples. Also spend time on some of the basic structure issues that are necessary to understand. You should read chapter #3 in the PHP/MySQL Programming text book. Please read along in the text book at the rate of about a chapter a week. I really think of the textbook largely as a reference. Please look at "Go West Across America with Lewis and Clark" which is where I got the idea for the Boston Tea Party game. Lewis and Clark adventure Assignments: I would like you to write an educational game for kids about some event or series of facts. It should be something along the lines of what I did for the Boston Tea Party. In class work (will be worked on in class, has to be done by all on line students and students who were not there as well): This is a debugging quiz - you need to get the scripts so they work! tofix.zip As always, check back! |
Unit #2 | I am sending you your user names and passwords soon I hope. I will also included your database names which we will get to in
a while. Please test your username and password and let me know if it works alright. You might also try a simple PHP program. If you did
not get the user name and password, let me know. Read chapter #2 in the text. Remember, there is no need for a local installation. We will be working off cisweb. Please look at the beginning PHP examples and the beginning PHP PowerPoints. The examples are under Beginning PHP examples. They are zipped. The presentations are under PHP fundamentals and are called Beginning combined Spring 2011. You should also read chapter #1 and start reading chapter #2 in the PHP MySQL Programming text book. Note that you are doing PHP and MySQL on our server so you do not have to attempt to set up. We will see where we get, I probably will post something else. Assignments: Continuation of assignment from week #1, please upload your HTML page(s) to your website when you get the user name and password. First PHP assignment Put this up on the web. Send me the code and the address. Memo assignment. Make up 5 names and use the 7 days of the week. Put this on the web as well. |
Unit #1 | There are usually 15 units during the fall and spring so there will be 15 units during the summer as well. I will put units up
every few days at the beginning. You can pace them in a way that works for you, but I want at least one unit passed in each
week and all of the units done by the end of the semester.
Read chapter #1 in PHP/MySQL Programming. We will start off the semester
with HTML/XHTML. If you have already had CIS122/44 or have previous experience, this will
be a review. If you have taken CIS120/17, you have already been introduced to HTML. For others
I suggest that you read chapter #1 carefully and use resources at
the page for CIS122/44 or other resources on the web to accquaint yourself with HTML. The students in this class have a variety of backgrounds, so for some HTML is review and for others it is relatively new. Handout on using WinSCP3 Note that WinSCP3 is available as open source software and you can download it for home use. When logging in at school, you should not enter your password and you should not save. If you do not enter the password you are prompted for it in a session, but it is not saved. This provides you with some security for your site. You should be getting a username/password for the BCC site at the end of this week. We will be working exclusively off the BCC site. You do not need to install PHP or MySQL, they are on the server. Assignments: If you are new to HTML, I want you to build a web page and upload it to the server (that cannot be done until you get your username and password). The page should include at least list, tables, CSS and forms. If you are experienced with HTML, I want you to develop a page that challenges you and uses elements that you stretch your knowledge - this is the time to explore more CSS or forms - experiment! Due in two weeks. Hopefully I will have your server login information soon - if not we will extend the due date. As always, check back! |