Feb/100
Twitter Updates for 2010-02-06
- "The Observation Deck" (Naomi Epel) – a great source of writing prompts! #
Powered by Twitter Tools
Feb/100
Writing Prompt
I was poking through “The Observation Deck” (Naomi Epel) – pick a card at random and look up its description in the book, then use it as a starting point for writing.
I pulled “Choose the right name” – which concludes with an interesting exercise:
Brainstorm a list of interesting names, or pick one from the phonebook. Then sketch a written portrait of the person who might bear such a name. Assign an age, occupation and marital status. Describe hobbies, mode of dress and favourite foods. Think of three other names such a person might bear.
Feb/101
The Phantom Of The Opera
Comparison of versions:
Sarah Brightman and Antonio Banderas
(did you know that ‘Puss in Boots’ from “Shrek” could sing?)
Michael Crawford and Sarah Brightman
Steve Harley and Sarah Brightman
(ok, so who gave them permission to re-write the lyrics?)
Gerard Butler and Emmy Rossum
(one minute he’s killing Persians in “300″ then he’s singing, who ever knew he had the voice?)
Feb/100
“Eve of the War” (from Jeff Wayne’s “War of the Worlds”)
“Wild” performing a cover of “Eve of the War” live
now, “Wild” broke up, and two members went on to form the band “Escala” (briefly called “Scala”)
Escala – Kashmir Featuring Slash (of Guns ‘n’ Roses fame)
I know that track – its been done before by the quartet “Bond”. Which version do you prefer:
Bond – Kashmir
Its a good thing that Escala renamed themselves, as YouTube turned up the “Scala” choir cover version of “Enjoy the Silence” (Depeche Mode)
which begs a comparison with other versions of the song:
Depeche Mode (the original)
Cover versions
Tori Amos
Breaking Benjamin
http://www.youtube.com/watch?v=-kd680Cz8gg
Yana
http://www.youtube.com/watch?v=gvRz0ouXOhw
Van Helsing & Van Giessen
HIM
Lacuna Coil
At the end of the day, my vote rests firmly with Lacuna Coil as being the best cover of this track.
Jan/100
Bryan Adams – “Heaven”
I was listening to a streaming radio station (on Pandora.com) that I’ve trained to play some nostalgic 80’s rock tracks. It played THE PERFECT song for the mood I was in, almost like it was reading my mind.
In a few days it’s the anniversary of my wife and I’s first date – we were married 18 months to the day from our first date – so the date has more significance than Valentines! So, a musical, emotional dedication to 16 years since the first date. (yes, and looking forward to a 15th wedding anniversary in August 2010).
Original
http://www.youtube.com/watch?v=3eT464L1YRA
Unplugged
http://www.youtube.com/watch?v=Z7b37l_B4vI
Cover versions
DJ Sammy featuring Yanou
Do (unplugged)
Leticia and Tito
Jan/100
Twitter Updates for 2010-01-10
- Alright, I'm fed up of waking up and seeing snow outside the window. Someone bring back summer, and do it quickly! #
Powered by Twitter Tools
Dec/090
PHP-on-Tomcat (Part II)
The original goal of being able to run PHP on top of Tomcat was to allow simple development of PHP based applications like Wordpress and/or bbPress. To get these working I needed a database.
The wildly popular mySQL database has a nice installer for OS X. Mine installed to /usr/local. I did the install ages ago and forgot what the “root” database user password was. Ooops! No matter, there are some great resources online talking about how to go about resetting permissions. I opted for the incredibly easy, but utterly insecure method (from inside the terminal) :
- Stop the existing server
- Restart telling it to turn off permissions:
mysqld_safe --skip-grant-tables --user=_mysql & - Jump into the mysql shell application:
mysql -u root mysql - Change the “root” password:
UPDATE mysql.user SET Password=PASSWORD('#########') where user='root'; - Persist privilages:
FLUSH PRIVILEGES;
Next on the list was exposing my mySQL database to the Tomcat hosted PHP code. Step 1 was making sure I have mySQL JDBC drivers installed, Step 2 was creating a JNDI datasource in the context, and step 3 was getting the PHP to use it.
The officially supported mySQL Connector/J was a quick download. The JAR file for it was dropped into the $CATALINA_HOME/lib directly. Good to go. The context file was more of a challenge, under the $CATALINA_HOME/conf/Catalina/localhost I created an XML config file that matched the name of my webapp – php.xml – where I declared the JNDI datasource. It took some tweaking and reading around but finally ended up coming together:
<Context reloadable="true">
<Resource
name="jdbc/mydata"
auth="Container"
type="javax.sql.DataSource"
username="root"
password="#########"
driverClassName="com.mysql.jdbc.Driver"
url="jdbc:mysql://localhost:3306/test"
/>
</Context>
The documentation for Quercus states
Scripts can use the jndi name directly:
<?php // standard PHP //mysql_connect($host, $username, $password, $dbname); // using JNDI lookup mysql_connect("java:comp/env/jdbc/myDatabaseName"); ?>
But that doesnt help me to run Wordpress as I’m not about to go modifying their code. Never fear, there’s another option. The documentation for Quercus also says that you can put an entry into the WEB-INF/web.xml file that forces all database connections to go through the same underlying JNDI datasource:
.
.
.
<!--
Tells Quercus to use the following JDBC database and to ignore the
arguments of mysql_connect().
-->
<init-param>
<param-name>database</param-name>
<param-value>jdbc/test</param-value>
</init-param>
.
.
.
So, a quick update to point at my own datasource and wall was ready to go. I downloaded and unzipped wordpress into the PHP webapp directory, pointed a browser at http://localhost:8080/php/wordpress and found myself stepping through the famous 5 minute install. Less than 5 minutes later I was looking at the main page of a fully-functioning Wordpress install.
Dec/090
Twitter Updates for 2009-12-12
- PHP-on-Tomcat on OS X, using a JNDI/JDBC datasource out to mysql, running wordpress – take that LAMP stack!
#
Powered by Twitter Tools
Dec/092
PHP-on-Tomcat
I am generally a Java programmer (if my day-job is to be believed) and hacking my way through Apache configuration isnt my idea of a fun evening. For some odd reason my trusty old black MacBook hasnt had the best of times when I try to enable “web sharing” and then try executing PHP scripts – all I get is a dump of the source. Time for a creative solution to the problem!
The folks that created the Resin App Server have a 100% Java implementation of PHP 5 released under the Open Source GPL license, known as Quercus. So step 1 was to download the latest release that will run on non-Resin app servers: quercus-4.0.1.war.
This was the point where I also realized that I dont have an up-to-date install of Apache Tomcat on my system either. Step 2 was to go download Tomcat 6.0.20 and install it.
Many applications need to know where Tomcat lives, and that means setting the CATALINA_HOME environment variable to point to the install. In a terminal I edited the global startup file for the terminal: sudo vi /etc/bashrc to add the line:
CATALINA_HOME=/Users/paul/Documents/Devt/3rd-party/apache-tomcat-6.0.20
Step 3 was to $CATALINA_HOME/bin/startup.sh to start tomcat and then point a browser at http://localhost:8080/quercus-4.0.1/ where I saw confirmation that all was well:
Testing for Quercus™…
Congratulations! Quercus™ Open Source 4.0.1 is interpreting PHP pages. Have fun!
I didnt like the URL though, but that’s easily changed. I simply nuked the quercus-4.0.1 directory under $CATALINA_HOME/webapps and renamed the Quercus WAR file “php.war”. I bounced Tomcat and bingo – a “php” directory I could drop files into. As a final test, I created info.php
<?php
phpinfo();
?>
and hit it on the pretty URL: http://localhost:8080/php/info.php. All displayed correctly. I was off and rolling running PHP on top of Apache Tomcat! Stay tuned for Part II – getting Wordpress running on top of PHP running on Tomcat!
Dec/090
Flyleaf – “All around me”
I was listening to a mix over on Pandora, and was introduced to Flyleaf. Wow. Fantastic stuff. I am so glad that I have a 30% off coupon for Borders – I am going to buy a CD this weekend! (who said streaming digital music was killing CD sales?)
All Around MeMy hands are searching for you This fire rising through my being I’m alive, I’m alive I can feel you all around me My hands float up above me The music makes me sway I’m alive, I’m alive I can feel you all around me And so I cry I’m alive, I’m alive, I’m alive I can feel you all around me Take my hand I can feel you all around me |