Journal » Recent Posts
|
|
I accidentally stumbled upon a small inconvenience yet again as a web designer; as you can see my current design uses a flash movie under <div> elements. Normally the flash content will be on top regardless of the stacking order in your code or via z-index. It turns out setting your flash movie's window mode ("wmode") to transparent will fix the issue (only in a perfect world). Sadly this doesn't work on firefox on linux platforms, based on my reading the wmode attribute is still not supported on linux/firefox. I've read somewhere that google was able to pull this off by inserting an <iframe> right under your <div> width the same dimensions and using a little javascript hack. Long story short the iframe must have a display property set to none at first, then set back to block once the page has loaded. I implemented this on my current layout and it seems to work. To test this you can visit browsercam.com, they offer a free trial to take screenshots of websites under different platforms/borwsers. something like this:
|
|
|
I went on a vacation for a few days with Perry, Eric, and Glen to a resort (Sitio Remedios) in Currimao, Ilocos Norte. Perry was invited by the owner, Dr. Cuanang to cook for him over the weekend. Thankfully he was generous enough to let us tag along. The Place is not your typical resort with the usual amenities. It's kind of a cultural get away where all you do is eat good food, relax, and catch up on important things in life. There isn't much to do. There are no televisions, no radio, not even an internet connection. It sounds boring at first, but it suits the theme of the place, a peaceful get away from the hustle and bustle of the city with the distinct Ilocano feel. I enjoyed my stay there and I am looking forward to going back next year... hopefully! Maybe by then they'll have a Wifi connection so I can bring my work with me and stay a bit longer. I am thankful to our generous host, Dr. Cuanang who even hanged out with us several times, and thanks to Perry as well for inviting me. If there's anything I learned on this trip, it's to value the simplicity of life. The people who live within the vicinity of the resort fish almost everyday as their source of livelihood. It's a family affair - you can see everyone pitching in - from the grand mother to the cousins of the respected families. Things are so much simpler there yet most of them seem to be happy and content. I also came to terms with Perry and our differences as father and son. I guess I am content with small talk over a few bottles of beer, knowing that I got my point across to him. |
|
|
Lately I've been handling more and more sites for my clients, that translates to more testing and updating of scripts on my end. To increase productivity and efficiency I often test the stuff on my local machine before I upload them to the actual server. So I decided to make use of virtual hosts to emulate the sites that I am working on. Just to be clear, I'm using Apache 2.2.x (note: I don't use WAMP or the like.) on a Win32 machine. So first up open your httpd.conf and uncomment the line:
Include conf/extra/httpd-vhosts.conf
httpd-vhosts.conf will be where we put our virtual host settings and is located within your apache install directory in /conf/extra. After this we will create a folder where all our virtual hosts will be pointing to e.g. C:\virtualhosts, then we make sure we can access it later via http by adding this to the httpd.conf
Now open your httpd-vhosts.conf so we can set our virtual hosts. There are 2 ways we can access our vitual host namely via it's server name or port, I'll be showing you both but first we will be using the ServerName method. This is done by adding the following lines in your httpd-vhosts.conf: In this example i will be making a virtual host for my PhpMyAdmin installation.
Then open your hosts file in Windows which is usually located at C:\WINDOWS\system32\drivers\etc and add the following line at the bottom
127.0.0.1 phpma.local
Notice that we used the SeverName phpma.local on the hosts file that way we can access it on our browser by simply typing in phpma.local. Note that we cannot use any other ports aside from 80 since we cannot specify ports in the hosts files, if you want to have a specific port for your virtual host so it can be access via your ip:port we just add the following to your httpd-vhosts.conf
After you finish making the necessary alterations to the config files, restart your apache server.Now I can access phpmyadmin by either typing in phpma.local or 127.0.0.1:2082 on my browser. This can be done repeatedly depending on how many virtual hosts you'll be needing. This is especially useful to me since I test out a lot of things. I hope this helps someone, happy coding! |
|
|
The company I work for just celebrated its 2nd year anniversary last week. It seems like it was just a few months ago when the company was first conceptualized in a small room in Marikina with roughly 6 computers and about 5-7 employees (including me). Now the company has grown to around 40 employees (give or take) in a swanky office space in the Ortigas Business district. I am thankful to the founders of the company namely, Mike and Stef, who hired me and kept me as their employee since the inception of their enterprise despite our occasional qualms here and there. I have learned a great deal on how to deal with myself in a "corporate" environment which has brought me both financial and intellectual gains, thanks mainly in part to MS12. This is the longest job I've ever retained in my entire life, and I hope I'd continue to work for them in years to come. "Good jobs" are hard to come by and I consider myself to be very lucky to be able to retain my job. If there's anything I learned since I started working for them is to not take anything for granted. I'll keep working until the day that I no longer enjoy what I do, but until then I plan to work my ass off and learn everything there is to learn. |
|
|
I've learned something new today, and I thought I'd share it with you guys since it tooks me quite sometime to find the correct answer on google. My problem was I needed to select the same field in 1 table with a condition. Notice the table below, the rid column represents the person who referrer id which denotes who referred that person. So I needed to select all the name's along with the names of who referred them in 1 statement; e.g. felipe was referred by pedro. +----+-----+--------+ | id | rid | name | +----+-----+--------+ | 1 | 0 | juan | | 2 | 5 | felipe | | 3 | 1 | carlos | | 4 | 0 | maria | | 5 | 0 | pedro | +----+-----+--------+ To make the long story short I used table aliases to reference the same table in 1 statement and a subselect to get the value i needed like so:
which gives us
+--------+----------+ | name | referrer | +--------+----------+ | felipe | pedro | | carlos | juan | +--------+----------+ It may seem trivial to most people but I hope this helps someone, I've been using PHP for quite some time but I have yet to get a good grip on my SQL, so for those who are like me you are not alone! ^^v |
|
|
After almost 2 cases of beer, 500+ kilometer drive, 7000PHP travel expenses and almost 20 hours spent on the road; my road trip finally ends. I was initially invited by Perry to hang out in Baguio and meet up with some old childhood friends, which ended up in a beer drinking road trip. The gist of the excursion was: we drove to Baguio and drank half a case of beer, slept for 5 hours, waited on Perry, Drank a case of beer, waited on Perry, slept, waited on Perry drank a bit, drove home and drank like half a case of beer again. The entire trip was fun, I got to meet up with some old friends and finally got some time to relax and escape from work; the only drag was waiting on the person who initially invited us to go there in the first place and over spending my budget (Yes I don't earn that much, so I don't have the luxury of splurging). Despite the set backs, I don't regret going to Baguio, it was mainly an escape from work for me and my cousin Jeff. Though the next time around I'll plan our trip better and lower my expectations. We're planning another trip this April, this time to the beach. It's been sometime since we drank by the beach and just chill soaking in the ambiance of the sea. This time around I'm sure it'll be much more fun, just me and the people I wanna hang around with, with a chest full of ice cold beer! ...hopefully the next time around I'll be able to take some pictures. |
|
|
Amidst uncertainty, doubt, and hatred;
Calm my nerves, teach me to think things over. When I'm alone, immature, and jaded; Help me be hopeful, wiser, and stronger. If things go wrong, have a plan just in case. When crossroads come along, show me prudence. When at the bottom, point to the surface. If detractors persist, give me patience. Though mass media may dictate otherwise; I am, and will be who I choose to be. I need not alter myself to suffice the expectations of society. I don't strive to be famous or wealthy; All I want in life is to be happy. |
|
|
There comes a time when you eventually get tired of your day to day routine - then you ponder on drastic changes to spice things up. I, on the other hand, have this dilemma at least once in three months. Lately I've been working for several clients, sometimes more clients than I can handle just to earn a substantial amount. I try to choose projects that appeal to me. Unfortunately these are few and far in between. Living in the city is very demanding in almost all aspects of life: financial, mental, psychological, among other aspects. I ask myself, "is it worth making all these sacrifices to live in the city"? I'm in my mid 20's and I'm already tired of working almost 12 hours a day, five days a week. To think that I'll still be working until my late 40's just to support my standard of living is horrifying. Add to the equation that things only get harder, prices just keep getting higher and the climate just keeps getting worse. If or when I grow old, will I look back at my youth and regret my choices? My peers and I are slowly becoming slaves of currency and trends, sacrificing our time on this earth for worldly desires which are not really necessities. I feel we are just digging our own graves in the way we live our lives - swamped in debt, poor health, slave to our vices, victims of mass media -these are only among the numerous banes within the scourge of society. When you eventually try to get out of your predicament, you find yourself sucked right back in by the very people and things you believe in. Only a handful manages to realize their faults and successfully find their own self, and most of them are ridiculed or are outcasts from society. At my age I am tired and enraged by the fact that I can only do so little to change my situation. If only a paradigm shift was as easy as writing it down on a sheet of paper. Something is better than nothing. I hear so many analogies with the same meaning amongst my peers especially when it regards work. When I think about it, sometimes nothing is better than something, just similar to the popular saying, less is more. |



