Month: July 2008

Parsing JSON Data from PHP Using jQuery

Posted on Updated on

have been studying parsing JSON from PHP using AJAX to display it in the client side and jQuery had been a great help to me. Here is a very simple code in parsing JSON using jQuery that i made.

tablejsondata.php
This file makes the request to a php file and displays the returned data into a table.

<html>
<head>
	<title>Parsing JSON From PHP Using jQuery</title>
	<script src="http://code.jquery.com/jquery-latest.js" type="text/javascript">
	</script>
</head>
<body>
	<a href="#" id="loaduserdata">User Data</a>
	<table id="userdata" border="1">
		<thead>
			<th>First Name</th>
			<th>Last Name</th>
			<th>Email Address</th>
			<th>City</th>
		</thead>
		<tbody></tbody>
	</table>
	<script>
	$(document).ready(function(){
	});
	$("#loaduserdata").click(function(){
		$("#userdata tbody").html("");
		$.getJSON(
			"jsondata.php",
			function(data){
				$.each(data.userdata, function(i,user){
					var tblRow =
						"<tr>"
						+"<td>"+user.first+"</td>"
						+"<td>"+user.last+"</td>"
						+"<td>"+user.email+"</td>"
						+"<td>"+user.city+"</td>"
						+"</tr>"
					$(tblRow).appendTo("#userdata tbody");
				});
			}
		);
	});
	</script>
</body>
</html>

jsondata.php

This is the file that contains the JSON data.

<?php
	$json = '{
		"userdata": [
			{
				"first":"Ciaran",
				"last":"Huber",
				"email":"elementum.purus@utdolordapibus.edu",
				"city":"Mayagüez"
			},
			{
				"first":"Lester",
				"last":"Watkins",
				"email":"orci.sem.eget@quamvelsapien.edu",
				"city":"Laguna Beach"
			},
			{
				"first":"Mannix",
				"last":"Gilmore",
				"email":"sed.sem.egestas@AliquamnislNulla.com",
				"city":"Minot"
			},
			{
				"first":"Nathaniel",
				"last":"Holland",
				"email":"a.odio@Donecnibh.org",
				"city":"San Angelo"
			},
			{
				"first":"Wylie",
				"last":"Drake",
				"email":"lobortis.nisi.nibh@Integer.edu",
				"city":"Roseville"
			},
			{
				"first":"Salvador",
				"last":"Alford",
				"email":"fringilla@adipiscing.edu",
				"city":"Vacaville"
			},
			{
				"first":"Kiara",
				"last":"Barton",
				"email":"fringilla.est.Mauris@utpellentesqueeget.ca",
				"city":"Johnson City"
			},
			{
				"first":"Moses",
				"last":"Miller",
				"email":"per.inceptos@aliquam.edu",
				"city":"Boulder Junction"
			},
			{
				"first":"Hillary",
				"last":"Serrano",
				"email":"elit.pretium.et@scelerisquesedsapien.com",
				"city":"Martinsburg"
			}
		]
	}';
	echo $json;
?>

References and Guides:
http://docs.jquery.com/GetJSON
http://www.json.org/js.html

Download the latest jquery file.

A Sneak Peak On My New Blogger Skin

Posted on Updated on

I have been planning to skin my blogs for a very long time already. There are a bunch of stuffs to do that is why I can’t manage to have a time.

I want a simple and manageable template so that my blog won’t have a chaotic look.

Here is a peek on my blogger template:

There are a lot of tweakings to do but at least I have started the design and layout already. Hopefully at the end of the week I will be able to customize my blogger site.

The next task would be to study how the blogger template works.

Blogger: Inquisitive Mind

[EVENT] Globe Innovation Convention: Globe Labs Launch – August 7, 2008

Posted on Updated on

Globe Innovation Convention: Globe Labs Launch – “Enriching lives through Innovative Communications”

Date: August 7, 2008 (Thursday)
Time: 7:30 AM – 5:00 PM
Venue: Isla Ballroom, Tower Wing, EDSA Shangrila

Globe Labs is a new organization within Globe Telecom whose mission is to help bring in the newest future technology services at the earliest market-relevant time. We explore new and future technologies, and partner with developers to create new internet, wired and wireless applications.

What we have in store for you: Learn, Build, Compete and Succeed

  • Discover the different opportunities with Globe Labs
  • Learn how to use Telco tools and various development platforms to build innovative applications
  • Join the Globe Labs Challenge and compete amongst the best

PHP User Group Philippines, Inc., being one of the institution partners of Globe Labs, is given 200 SLOTS for this upcoming big event and we are inviting you, PHPUGPH members, to attend. T-SHIRTS designed for PHPUGPH would be given away as freebies plus exciting raffle prizes awaits you… ***FIRST 300 individual registrants gets a GIFT*** Wink

Below are some links of articles regarding the event:

From Businessworld (Entreprenews)
http://entreprenews.com.p…in.php?id=062508.gonzalez

From the Inquirer:
http://technology.inquire…gets-3G-mobile-developers

From the Manila Times:
http://www.manilatimes.ne…htimes/20080627tech5.html

From Manila Bulletin:
http://www.mb.com.ph/INFO20080627128372.html

From PCWorld:
http://www.pcworld.com.ph…5&ID=H,485,PWP,PWP-16

From Yugatech:
http://www.yugatech.com/b…pens-globe-labs-division/

From Globe Labs website:
http://www.globelabs.com…./News/Forms/AllItems.aspx

Read more information

Yippee… It’s My Birthday!

Posted on Updated on

Happy birthday to me… Happy Birthday, Happy Birthday… Happy Birthday to me!

Oh my, another year is added to my age. 🙂

I Wear Black

Posted on Updated on

“I Wear Black”

I wear black
‘Cause I weep for tomorrow
The day I first breathe
The day of my first morn

I wear black
‘Cause my heart is full of sorrow
Of pain, of fury
For the world abandoned me

I wear black
‘Cause I’m dejected
‘Cause I’m alone
Left by everyone

I wear black
‘Cause I’m misunderstood
For no one dares
To lend an ear

I wear black
‘Cause I’m happy
To see the last drop of sand
In the hourglass

I wear black
‘Cause I rejoice
The very last moment
Of the day I was born

Written: July 18, 2002

This was a poem I wrote exactly four years ago. Can’t believe it has been that long. 🙂

The First Attempt

Posted on Updated on

It is only 2 days away until my special day.

As of now, I don’t have any clear plan on how i would i celebrate it. Lots of ideas are popping out in my head but i am still undecided.

Although it is on the top of my list, i still don’t want to end up sleeping all day doing nothing.

I was listening to morning rush in rx and they were giving away tickets to Lifehouse concerts for FREE. You just have to give 3 songs from their latest albums. I am a great fanatic of Lifehouse and it would be a great birthday treat for me. I do not have their phone number. I only have a very short moment to look for it.

First caller don’t know any song from the latest album. It was my first chance. I am already googling the answer to my query.

Second caller hang up. Another chance. Still Googling.

My heart beats so fast as the third caller gave her answer. She was only able to give 2 correct song titles. Third chance and I was cramming through the net.

I was looking for their number in the net and in the ironic misfortune of finding it makes me nervous and irritated. I can’t find their number!!!

Aaaahhhhh….

And then the fourth caller called. My fingers were crossed and my mind was wishing she would be wrong and that she would give the wrong titles. In my disappointment, she got it all correct. Congratulations to her.

I almost cried when she already won the ticket. *sniff….

Oh, well. I’ll try again tomorrow. Hopefully, they would still give away some tickets in the Morning Rush show. It would be a great birthday treat. First, it’s Lifehouse’s concert and last, it’s Chico and Delle!!!

Oh my!

Lifehouse in Manila

Posted on Updated on

Lifehouse has a world-wide tour and is coming to the Philippines on July 26. They will be performing at Araneta Colliseum and their ticket is available for 990 at Upper Box B to 4890 at Patron VIP. The whole ticket price can be seen at tickenet.ph.

The band has popularized the songs “Hanging by a Moment”, “Broken” and “You and Me” and their songs has been the soundtracks to popular Hollywood TV series such as Grey’s Anatomy, One Tree Hill, Criminal Minds and The Hills.

They were interviewed today in the morningrush rx and i can’t help myself to laugh at Delamar as she giggled throughout the interview. Well, i do felt that giggly feeling she has. 😛

Lifehouse

Oh, i can’t wait much more for there concert date.

Multiply No Longer Free, Welcome Premium Users

Posted on Updated on

Just read a sad news this morning for fellow multiply users. The “goodbye to upload limits” policy has bid its farewell in the last week of June.

Multiply Premium Account

Multiply has introduced its premium membership account last June 25, 2008 due to the millions of photo and video uploads they get everyday. They will be charging $19.95 per year for your “file storage” use.

Here is the comparison of the two accounts from their own blog:

album-sized photos
& on-site (Flash) video
“Zoomed-in” photos
& original video files
AutoUploaded Content
that hasn’t been shared*
Free users stored forever stored for 30 days stored for 30 days
Premium users stored forever stored forever stored forever

If you have a free account, Multiply will now only be storing your original sized photos and videos for 30 days and remove them afterwards. But don’t worry, the album sized images will still be kept.

The new policy and membership account gathered different views and reactions. Some liked it, some whined and complained and some doesn’t care.

As for me, i had been a multiply user for almost 3 years now and i could say that their site really rocks. I love the unlimited storage space they offer and how manageable my profile can be. The network contacts works perfectly great as well as the Groups feature. And above all else, it’s free.

But that was before. Now, my free account has been ripped off with its storage freedom. My original-sized photos only have 19 days left before they get removed by the system.

I can still live with the resized photos the site would leave me. It is just sad to say goodbye to the good old days of unlimited storage.

After the errorneous system of Friendster and the Premium Account of Multiply, which other networking site will follow?

Further reading : A word on storage and Multiply Premium

Happy 12th Birthday MorningRush

Posted on Updated on

Happy Birthday
Happy Birthday

Happy anniversary to MorningRush. Thank you for accompanying us every morning. More power and God bless Chico and Delle.