Exploring a street of Kyoto with Engage.

Well the title might sound a little strange and confusing. Never the less, as most of us know Kyoto is a city in japan should have said a beautiful one at that and Engage is the project which I work these days. Things are really getting heated both with the project and rest of the stuffs that I’m up to these days causing me to go quite for sometime.

Anyhow, one of the things which impressed a lot at the start of this project was Augmented Reality (AR) where virtuality and reality come together. Normally, a virtual object or an animation is augmented on a real video or an image (content) using a marker where the virtual object always shown on top of the real content. But my interest, ever since I first happen to see this was on using it for computer interaction besides there are many possibilities that exists with AR specially when it is combined with holography which can surely bring to light an unseen dimension to our lives and produce great results.

Getting back to the post, this shows an example panorama which can be explored using a marker. It was intentional here to refrain from augmenting specially, to show the possibility of using marker for interaction and even for wearable computing. Enjoy 🙂


I have adapted an image of a street in Kyoto for the example which is available at, http://wallpaper.free-photograph.net/en/photobase/yp5745.html

And the background music for this video was taken from,
http://ccmixter.org/files/Ihaveriffs/22440 which was released under creative commons license.

Getting your Gmail feeds.

Download Podcast

Few days back while I was checking ma mails, I just clicked on the rss icon that appears on the right corner of the address bar (on firefox) which to me to a page where it was showing few of the most recent mails in the inbox.

Which you can check on,

I actually knew this quite some time back via a post of a fellow blogger. But Then I dint have much of a time to explore on it neither I was too interested on it by then. Anyway this time around I thought it’s time for me to get some insight of it.

The feed shows few of the most recent mails in your inbox together with few lines of the body of them as well. This becomes really handy if you are in a real hurry or even if you want to check your mails in your mobile because compared to getting there using the traditional login, this seems to be really fast.

It can be used to check whether you have received any new mails after you logged in for the last time and so on. But unfortunately, one will hardly be able read the content of the mail in whole unless the mail is so short that it will not exceed two lines or so. And getting any attachments is almost impossible as it stands now.

Just to exploit on it I have developed a simple page which makes life easier if I’m to access my feeds. The URL is given below. But I really don’t suggest you to go ahead and use it. And if you are using it remember, it’s on your own risk.

A customized Login

The page above utilizes https://username:password@mail.google.com/mail/feed/atom mode of accessing Gmail feeds, so there one only requires to give the username and the password and it take care of the rest. Otherwise it could be potentially dangerous to use this method since your password will be revealed (because the address bar will never mask your password) in that case you better stick to the very first URL on this post.

Anyway I think it’s always nice to know few other ways of getting there as it may turn out be useful one day when you are stranded and when you have no other options. Hope you enjoyed it. Cheers.!

Another Site of Lonely Coder Makes it’s way

This time it’s a personal site of an Islamic Preach (Official web site of Shaikh Mubarak Moulavi). I actually got the invitation to undertake this site back in September 2006 but I wouldn’t do, as I was running into a very busy schedule those days with ma academic work. Because then it happens to be the all important first semester of first year of ma Undergraduate studies. hence I requested ma client to gimme some time until I get ma vacation. Thank God he will agree with me and promised wait for me till I become free. He wanted it to be some how get done from me.

After keeping the client for a long while, this short vacation that i get just before for X’mas I thought was the ideal time to start working on it. During ma first visit to collect requirements I would think it’s just a static site with not more than five or six pages with some dynamic content in it. But trust me as I went it for the second time to finalize the set of requirements I realized that the site got bigger and bigger. At this point I could understand it’s more in the likely hood to behave as a community site though it’s meant to be personal site as at the beginning.

Anyway this time around I have chosen a team of three (including maself) to work on this pro the team itself is supposed to work together for the first time. One of them has already worked with me when I did Online Police Entry System (OPES) for our annual Cutting Edge Exhibition. But here the scenario is completely different and the domain is even more vast.

Anyway I went back to ma team and told about the whole scenario and asked them whether they are willing to go ahead with it. For my amazement they were quite prepared to live up to the challenge. So why would I worry buzzed the client and gavimm the confirmation. Two days later we started working on it.

Everything went fine then n there deadlocks came in but we were able able sort them all as a team. For my comfort I got a geek who works with me at ma company who is ever willing to help me out in any crisis. We completed the pro last week and took some time to do a bit of quality assurance. This weekend we are almost done along with some of the very late adjustments that came in from the client. And I thought of doing the documentation they before yesterday with ma expert when it comes to that part of it. And I also made an appointment with the client on Sunday morning

Again when I went in to IIT (Where I do ma Studies, Projects and many more crazy stuffs…!) on Saturday ma other colleague was there already present but not the person whom I rely heavily to get done the documentation. We both waited for for hours tried buzzing him on several occasions and texting him as many a times as would you like it but all in vain there wouldn’t be any response from him. So after having our lunch we thought of giving it up. And went back to our places.

When I came into ma room in the evening after having a wash there waits a surprise call for me. The long awaited colleague of mine is on the line. His voice hears so deteriorated OMG he has fallen in his wash room in the morning, knock his head for God sake one of his cousin has been there with him who will admit him at the hospital. He is been found unconscious for a while and then has recovered later. So he told me the whole scenario and asked me to convey the message to the other friends including the other member of team HAGHZ as well. And now he’s not there in Colombo any more coz he has been taken Kandy and admitted there for further treatment. Since he’s from matale and his parents would like to be with him.

So what can I do now??. I asked him whether do I need to be there along side him but he wouldn’t want it at the first place since his parents are there and more likely he’s gonna get discharged in the morning. So was I was requested go ahead with the job and if that doesn’t happen then again I will be asked to go to Kandy late in the evening the other day(i.e Sunday). So called ma client and and told him the situ that I’m up to and he will be flexible to have a meet up with me without the all important documentation. Anyway I have promised him to submit the DOC later on within the week., Which he would agree hence, I went on to meet him yesterday itself and handid over the site as it was scheduled earlier.

you can check out the site on,


Reading xml with PHP

Two days back I was working on reading xml using php. And let me tell you it was really cool with php. Hence thought of sharing with you.

the source xml programs.xml is fallows,

<?xml version=”1.0″ ?>

<program name=”cart”>

<program name=”survey”>


the php script to populate data from the xml file (programs.xml),



foreach($php_programs->program as $program_key => $program_val)

echo”the root element
is named <b>$program_key</b><br/>”;

foreach($program_val->children() as $child_of_program_key=>


if($child_of_program_key == “price”)

foreach($program_val->attributes() as $att=>$val)
foreach($program_val->price as $the_price)

echo “This <b>$program_key</b>
element has an ettribute named <b>$att</b> and is named

echo “This <b>$program_key</b>
element has a child element named <b>$child_of_program_key</b>
and the value is : <b>$the_price</b>.<br/><br/>”;



And the output looks as follows,

the root element is named program
This program element has an ettribute named name and is named cart.
This program element has a child element named price and the value is : 250.

the root element is named program
This program element has an ettribute named name and is named survey.
This program element has a child element named price and the value is : 500.

Feedback using PHP

Yesterday I discovered how to send e-mails using php. I didn’t think sending e-mails is such an easy thing. But thanks to php mail function it’s easier than one could ever imagine the code is as follows,


$to_addr = ‘you@yourdomain.com’;

if (isset($_REQUEST[‘submit’]))
$mail_body = ‘Name: ‘.$_REQUEST[‘name’];
$mail_body .= “\nEmail: “.$_REQUEST[’email’];
$mail_body .= “\nMessage: “.$_REQUEST[‘message’];
mail($to_addr,’Form Feedback’,$mail_body);
print “Thank you for the feedback.”;


<form method=”POST” action=”$_SERVER[PHP_SELF]”>
<tr><td>Name:</td><td><input type=”text” name=”name”></td></tr>
<tr><td>Email:</td><td><input type=”text” name=”email”></td></tr>
<tr><td>Message:</td><td><textarea name=”message”></textarea></td></tr>
<tr><td colspan=”2″><input name=”submit” type=”submit”></td></tr>




Nowerdays everybody is used to have a feedback form in their site regardless of the capacity of the site. Hope this piece of code will be useful to you. I think one could play around with this(php mail function) and come up with even more interesting applications of this, than a mere Feedback.

Let us break the barrier in sending e-mails.

Create your own Widget in WordPress

During one of ma projects this week at Archmage I had to come up with a site to post articles dynamically and they needed to be reviewed and edited then and there where it is required. Since we have already passed the deadline (due to this n this n that…) and already into extended time I was thinking for an alternative solution And found WordPress will be more than handier tool for our particular task. Since everyone else at the office were also sharing the same idea at this point, we decided to work on it using Worpress.

But then again I had to run into another problem with wordpress, since this is just a part of the vast system that we are developing, it required some of it’s other components to be included within the page. Well again I’m into a crunch situation, this time around I came to a conclusion, in order to overcome this senario, I’m gonna devolop ma own widget in wordpress but still I was wondering wether it will be a possibility, but thanks to my friend Niro (A pro in PHP) who insisted me that it should a possibility, I could come up with the solution.

In your wordpress control panel select Edit Theme button which is located under the Presentation tab yours. Then you will get all the php files and stylesheets of your currently selected theme.

Now you can click on sidebar.php and start developing your own widget.

Below I give you a piece of code which will create a very simple widget for you, the code looks as follows,

<!–start of widget//–>
<h2><?php _e(‘My Widget Title’); ?></h2>
<?php _e(“My Widget Content”); ?>
<!–End of widget//–>

Above code will create a menu with title “My Widget Title” & a list item “My Widget Content” in each & every page of your WordPress blog.

The idea behind this was very simple still i believe one can do wonders with this in WordPress.

Hit Counter using PHP

Below I give the code for a hit counter in php. Last week I had to come up with a hit counter for a project of mine and I thought of sharing it with you.

It uses a seperate file named ‘counter.dat’ to keep track of the number of visits to your particualr page which you have included this tiny peice of code. Don’t worry about the counter.dat because it will automatically create it for you. Once you get this code you can save it as a seperate php file and then when and where you want it on a page of yours, you just insert an include statement in your particular page and reuse it, the statement is something like this,


code snippet of ‘yourcounter.php’ is as follows,

$exist_file = fopen(“counter.dat”, “r”);
$new_count = fgets($exist_file, 255);


print(“$new_count people have visited this page”);
$exist_count = fopen(“counter.dat”, “w”);
fputs($exist_count, $new_count);




$new_file = fopen(“counter.dat”, “w”);
fputs($new_file, “1”);
print(“1 person have visited this page”);