Welcome!

I hope you find what you're looking for. If you have any questions or anything at all, please email me at: sooj_doesnt_know@hotmail.com

Sunday, 19 September 2010

PHP Blog Week 10



This week, I actually had a minor break through. Well, I actually studied and learned how to join tables. And I remember Kirk saying that Join is awesome, and it totally is. Also I have simplified my tables. I should really say I went through the normalization process :)


Below is my ERD. It should have been submitted to moodle earlier but when I went through the noramilization I had to change a few things around and remove a few tables to simplify! it turns out I went through the process more than needed.




So my query to search for a certain pizza with a certain topping looks like this:


SELECT item_name, toppings,

TYPE FROM items

NATURAL JOIN pizza_topping

WHERE MATCH(toppings) AGAINST ("mushroom");


I still havent figured out how to pull the size and price with the pizzas but I'm gonna post on here what I have been trying and it keeps getting an error. I should be able to figure it out by today. I shall be studying the books more deeply. It really did help. I am no longer so confused and lost!


SELECT item_name, toppings, price, size

FROM items

NATURAL JOIN pizza_topping,

pizza_size_price JOIN

price, size ON price_id = price.id, size.size_id

WHERE items.id = items_id;


I'm not sure whats wrong with that but the error i get back is: #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ON price_id = price.id, size.size_id WHERE items.id = items_id LIMIT 0, 30' at line 5


If I fix this, I will post another one to show what I did differently. Also I did the CSS and now it looks very similar to how I wanted it on the proposal.


I cleaned up my index page and really simplified everything. I put the navigation and all the rest of the html tags along with all the includes in the header.php file. so my index page looks like:




In the header.php file, since the title of each page needs to change dynamically, this is what my title looks like. at the moment when i first visit the index page, it says $page is not set and I'm not really sure why because $page is set to home by default.. I will look into that soon.




this is just a little preview of what it looks like right now. :P I still need to fix the CSS a little to look a bit better.





Until then, Ciao!


Sunday, 5 September 2010

Blog No. 4



To be honest, I didnt do much this week. I had the flash banner due, and the HCI assignment due next week, I was pre-occupied. But I did some more work on the database design and here's what I have so far...

So i redesigned the databases after a tutorial with Kirk, and I think this is a lot better. below is what i have made so far. more tables to be made shortly!




This is just an example of what the toppings table looks like.. it contains all the pizza toppings! total of 45 of them. I was impressed to find out how many different choices of toppings you can have!



it's really really not much. but at least I'm doing something! See you next week guys.


Sunday, 29 August 2010

Blog No. 3




Earlier this week, we learned about relationships in class. (not the ones you think! sadly. if only schools taught us about them.) And on thursday we learned about MySQL, how to create tables, insert data and find them.. So that's what I implemented with my project..




so that's the relationship of my databases.. I need to read more about it and correct anything that's wrong because i'm not completely sure about it. But i'm sure after my tutorial on tuesday, i'll be all set.


So the next thing i did was make some tables on a database called, "Menu". I have only made the three tables so far..




and entered some data... I only entered the names so far.. will update that very soon.




Additionally, I implemented the google map!




Well that's all for this week. See you guys next week!


Friday, 20 August 2010

PHP class progress blog!




Hi guys, so from now on, i'll be using this blog to blog about my progress in PHP class website project.


Menu Data!


$pizza1 = array('name'=>'Base Special', 'toppings'=>array('tomato', 'mozzarella', 'ham', 'capsicum', 'salami'), 'price'=>'£12.99', 'thumb'=>'01.jpg');



$pizza2 = array('name'=>'The Lot', 'toppings'=>array('tomato', 'mozzarella', 'ham', 'capsicum', 'salami', 'mushroom', 'pineapple', 'onion', 'garlic'), 'price'=>'£13.99', 'thumb'=>'02.jpg');



$pizza3 = array('name'=>'Capriciosa', 'toppings'=>array('tomato', 'mozzarella', 'ham', 'mushroom', 'olives', 'anchovies'), 'price'=>'£11.99', 'thumb'=>'03.jpg');



$Originals = array($pizza1, $pizza2, $pizza3);




So that is how i'm going to represent data at the moment. When we get into MySQL, i'll have it differently.. But the main point was to have a pizza in an array and have an array inside an array for the toppings so when the user wishes to search for a certain topping, it'd be possible.


The data will obviously have a lot more than just 3 pizzas. Also seeing how our index page should look like, I have created a folder called Settings in the include folder and created a file called page_settings.php and included the shortcuts there.


define('IMAGES_FLDR', 'images/');
define('PAGES', 'pages/');
define('FUNCTIONS', 'includes/functions/');
define('PAGE_COMPONENTS', 'pages/components/');

Well that is all for now. I am looking forward to learning more and more.


19 August 2010


Wednesday, 4 August 2010

Absence



I realise I have been absent :P but I have been on holidays and I was very busy trying to look all important. haha.


So uni has begun again and today I have been working on one of my assignments that are due next week. I am so clueless as to what I want to do.


Here is what I need to finish by next thursday.
  • Logo Design Using Flash
  • Dynamic Website Proposal in Detail.

Now, what I don't have a clue in, is what kind of logo I should make... Keeping it in mind that I want to do the whole Flash class in the same theme, Underwater.


Anyway.. Enough about me.. Will update soon again! xx


Sunday, 4 July 2010

Mac Microsoft Messenger Issues.

Recently, my messenger just started acting really weird. I logged in, and everyone i had on my contact list were asking me to add them again, even though i had everyone on the list, and everyone was blocked. all my contacts were blocked. there was no way to unblock them.

just in case you guys are suffering from the same thing, here is the solution.

Go to User/(your username)/Library/Preferences/Microsoft


and delete a file called Microsoft Messenger User Cache.plist


it's safe to do so, don't worry :) what this will do is that msn won't remember your history.. so your emoticons, chat history.. poof. well thats what it did to mine anyway!


So far.

Trimester two has officially begun.


PHP and MySQL seems freaking hard.. flash on the other hand seems real fun. i've already got the design for my flash website and its going to be my portfolio :) i designed it so its fun and creative!!! hint: underwater.


as soon as i have finished them, i'll put them on a server and show you :) it'll be super.


until then, Ciao!

Saying Images

Saying Images
Images with words.