<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Regan Y .com</title>
	<atom:link href="http://www.regany.com/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.regany.com</link>
	<description></description>
	<lastBuildDate>Sat, 25 Feb 2012 03:45:46 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>HTML5TO hack-a-thon</title>
		<link>http://www.regany.com/?p=371</link>
		<comments>http://www.regany.com/?p=371#comments</comments>
		<pubDate>Sat, 25 Feb 2012 03:45:46 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[HTML5]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=371</guid>
		<description><![CDATA[Tomorrow is the HTML5TO Hack-a-thon!
Lucky me, I get to spend the Saturday after a rather annoying/stressful (but thankfully short) work week trapped in a hotel for 12 hours hacking HTML5! What have I done? As long as I get there in time for some breakfast, I&#8217;ll consider it a success. Wait, that&#8217;s a really low [...]]]></description>
			<content:encoded><![CDATA[<p>Tomorrow is the HTML5TO Hack-a-thon!</p>
<p>Lucky me, I get to spend the Saturday after a rather annoying/stressful (but thankfully short) work week trapped in a hotel for 12 hours hacking HTML5! What have I done? As long as I get there in time for some breakfast, I&#8217;ll consider it a success. Wait, that&#8217;s a really low bar&#8230;</p>
<p><a href="/pf/html5to/html5test.html">My &#8220;entry&#8221; to get into the hack-a-thon can now be seen here as a portfolio piece, yay</a>!</p>
<p>Note the attempt at responsive design (resize your <strong>modern </strong>browser) oooh! <img src='http://www.regany.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=371</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>I know kung fu&#8230;</title>
		<link>http://www.regany.com/?p=367</link>
		<comments>http://www.regany.com/?p=367#comments</comments>
		<pubDate>Tue, 14 Feb 2012 22:05:02 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Awesome]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=367</guid>
		<description><![CDATA[Well not really. I mean I did train for a few months to try it out, but that&#8217;s not related to this post.
For the past 2 weeks, I&#8217;ve been mind-melding/brain-dumped-on receiving knowledge transfer from the inimitable Sacha Chua. Now I kind of feel like Neo from The Matrix after he&#8217;s had his brain loaded with [...]]]></description>
			<content:encoded><![CDATA[<p>Well not really. I mean I did train for a few months to try it out, but that&#8217;s not related to this post.</p>
<p>For the past 2 weeks, I&#8217;ve been <span style="text-decoration: line-through;">mind-melding/brain-dumped-on</span> receiving knowledge transfer from the inimitable <a href="http://livinganawesomelife.com" target="_blank">Sacha Chua</a>. Now I kind of feel like Neo from <em>The Matrix</em> after he&#8217;s had his brain loaded with all sorts of martial art forms. It&#8217;s been a whirlwind of project info, tools, and efficiency techniques. Today has been a reminder of everything I love about CS&#8230;</p>
<p>What we&#8217;re playing with:</p>
<ul>
<li>Drupal</li>
<li>Redmine</li>
<li>VMWare</li>
<li>Ubuntu, Samba</li>
<li>AutoHotkey</li>
</ul>
<p>Oh the possibilities for automation while writing CSS :O Example:<br />
Saves my file, switches over to Chrome and reloads the page all with one key press! <img src='http://www.regany.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<pre class="brush: plain;">
F6::CheckCSS()
CheckCSS(){
	Send ^s
	Sleep, 3000
	WinActivate ahk_class Chrome_WidgetWin_0
	Send ^r
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=367</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Getting the LESS compiler to run on Windows</title>
		<link>http://www.regany.com/?p=360</link>
		<comments>http://www.regany.com/?p=360#comments</comments>
		<pubDate>Wed, 23 Nov 2011 01:24:16 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[LESS]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=360</guid>
		<description><![CDATA[Continuing my foray into CSS extension tools, I decided to look into LESS, since there was a StackOverflow post that claimed more people used LESS than SASS. That probably means that most people just include the less.js in their HTML pages and off they go. But woe betide you, if you decide you should run [...]]]></description>
			<content:encoded><![CDATA[<p>Continuing my foray into CSS extension tools, I decided to look into LESS, since there was a StackOverflow post that claimed more people used LESS than SASS. That probably means that most people just include the less.js in their HTML pages and off they go. But woe betide you, if you decide you should run the compiler on your local machine to generate regular CSS! <a href="http://lesscss.org">lesscss.org</a> describes how to run it on a server, but I couldn&#8217;t figure out how to get the lessc executable easily, so I had to install node and npm to get the executable.</p>
<p>It was a lot more difficult to get a compiler going in Windows, and I&#8217;m not sure if my roundabout way of doing it is ideal.</p>
<p>The following needs to be installed:</p>
<ul>
<li><a href="http://git-scm.com/download" target="_blank">Git</a> (I just used the mysysGit that was somewhere in the plugins directory of Aptana3, which requires git to be included when installed)</li>
<li><a href="http://nodejs.org/#download" target="_blank">Node</a></li>
<li>npm</li>
</ul>
<ol>
<li>After the first two are installed, make sure to add the bin directories to the PATH environment variable of your system.</li>
<li>Make sure you run the following git commands in the directory where you want npm to be installed (inside the node directory). <a href="http://www.hacksparrow.com/install-node-js-and-npm-on-windows.html">Reference</a>
<pre class="brush: plain;">
git config --system http.sslcainfo /bin/curl-ca-bundle.crt
git clone --recursive git://github.com/isaacs/npm.git
cd npm
node cli.js install npm -gf
</pre>
</li>
<li>$ npm install less</li>
<li>Find lessc.exe and you can now compile .less files into regular .css via command line as described on <a href="http://lesscss.org">lesscss.org</a><br />
$ <code>lessc styles.less</code><br />
This works:</p>
<pre>C:\node\node_modules\less\bin&gt;node lessc test.less</pre>
</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=360</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Installing Ruby, Rails, Sass on Windows</title>
		<link>http://www.regany.com/?p=355</link>
		<comments>http://www.regany.com/?p=355#comments</comments>
		<pubDate>Fri, 04 Nov 2011 02:00:33 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[sass]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=355</guid>
		<description><![CDATA[After reading the SASS CSS homepage, and then the following:

Getting started with SASS
Rolling with Ruby on Rails

I simply could not understand how to install SASS. Surely there was more to it than:

installing Ruby with the Windows installer
running the commands posted on the above sites (eg. &#8220;gem install sass&#8221;)

Like, wasn&#8217;t there a step missing in there [...]]]></description>
			<content:encoded><![CDATA[<p>After reading the SASS CSS homepage, and then the following:</p>
<ul>
<li><a href="http://blog.accessibledesign.net/2010/09/getting-started-with-sass-and-haml-in-windows-a-front-end-developers-guide/" target="_blank">Getting started with SASS</a></li>
<li><a href="http://oreilly.com/ruby/archive/rails.html" target="_blank">Rolling with Ruby on Rails</a></li>
</ul>
<p>I simply could <strong>not </strong>understand how to install SASS. Surely there was more to it than:</p>
<ol>
<li>installing <a href="http://rubyinstaller.org/" target="_blank">Ruby with the Windows installer</a></li>
<li>running the commands posted on the above sites (eg. &#8220;gem install sass&#8221;)</li>
</ol>
<p>Like, wasn&#8217;t there a step missing in there somewhere about <em>downloading</em> SASS/Rails/HAML before running those commands??</p>
<p><strong>Apparently not.</strong></p>
<p><strong></strong><img class="alignnone" src="/images/ruby_install_sass.jpg" alt="" width="501" height="311" /></p>
<p>I was so floored. There&#8217;s some magic happening there. I&#8217;ve not been so impressed with a language intepreter/compiler install since WampServer&#8230;</p>
<p>:O</p>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=355</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>AndroidTO Pro Stream notes</title>
		<link>http://www.regany.com/?p=348</link>
		<comments>http://www.regany.com/?p=348#comments</comments>
		<pubDate>Wed, 26 Oct 2011 20:47:27 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[androidTO]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=348</guid>
		<description><![CDATA[Android and Monetization: Allen Lau, Wattpad
iTunes app store = 66% paid apps
Anroid market = 66% free apps, far more difficult to make money through monetizing on Android due to billing issues (more cumbersome than one-click iTunes purchase). 
Better to provide free app in marketplace, and charge for premium features, through in-app sales, rather than having [...]]]></description>
			<content:encoded><![CDATA[<p lang="en"><span style="font-size: small;"><strong>Android and Monetization: Allen Lau, Wattpad</strong></span></p>
<p lang="en"><span style="font-size: small;">iTunes app store = 66% paid apps</span></p>
<p lang="en"><span style="font-size: small;">Anroid market = 66% free apps, far more difficult to make money through monetizing on Android due to billing issues (more cumbersome than one-click iTunes purchase). </span></p>
<p lang="en"><span style="font-size: small;">Better to provide free app in marketplace, and charge for premium features, through in-app sales, rather than having both free and non-free app which will split ranking across multiple apps in marketplace. </span></p>
<p lang="en"><span style="font-size: small;">strategy is to get users hooked first with free app, then make them &#8220;pay for their addiction&#8221;</span></p>
<p lang="en"><strong><br />
</strong></p>
<p lang="en"><strong>Tackling the Challenge of App Discovery: Gary Yentin</strong></p>
<p lang="en"><span style="font-size: small;">319,000+ apps in Android marketplace</span></p>
<p lang="en"><span style="font-size: small;">450,000+ apps in iPhone app store</span></p>
<ul>
<li>Bloggers are your friends</li>
<li>Try UK market</li>
<li>Xmas season starts Nov. 1st. Get the marketing out there early</li>
<li>Target user group with mobile advertising (time of day/week)</li>
<li>app store description is usually the first p.o.c. and very important.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=348</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>AndroidTO Dev Stream notes: afternoon</title>
		<link>http://www.regany.com/?p=350</link>
		<comments>http://www.regany.com/?p=350#comments</comments>
		<pubDate>Wed, 26 Oct 2011 20:46:11 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[androidTO]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=350</guid>
		<description><![CDATA[Incorporate Catalyst in Android Apps: Vishal Arora, Rogers
Leveraging Roger&#8217;s Wireless cloud services. eg. Enable one-click purchasing.
Client &#8211; Rogers Network &#8211; Server
CTN = Customer Telephon Number
Catalyst: Location, Billing, SMS APIs; making capabilities available to your apps
Free to dev.  but Pay-per-use of transaction model
www.RogersCatalyst.com
Location API Find the Location of ANY Rogers Phone Number (Roger&#8217;s takes care [...]]]></description>
			<content:encoded><![CDATA[<p lang="en"><span style="font-size: small;"><strong>Incorporate Catalyst in Android Apps: Vishal Arora, Rogers</strong></span></p>
<p lang="en"><span style="font-size: small;">Leveraging Roger&#8217;s Wireless cloud services. eg. Enable one-click purchasing.</span></p>
<p lang="en"><span style="font-size: small;">Client &#8211; Rogers Network &#8211; Server<br />
CTN = Customer Telephon Number<br />
Catalyst: Location, Billing, SMS APIs; making capabilities available to your apps</span></p>
<p lang="en"><span style="font-size: small;">Free to dev.  but Pay-per-use of transaction model</span></p>
<p><a href="http://www.rogerscatalyst.com/"><span style="color: #0000ff;"><span style="font-size: small;"><span style="text-decoration: underline;">www.RogersCatalyst.com</span></span></span></a></p>
<p lang="en"><span style="font-size: small;">Location API Find the Location of ANY Rogers Phone Number (Roger&#8217;s takes care of Customer&#8217;s Privacy) Can use instead of GPS location. More feature rich than just Google location API.</span></p>
<p lang="en">
<p lang="en"><span style="font-size: small;"><strong>Android and the Azure Cloud: Atley Hunter, Microsoft</strong></span></p>
<p lang="en"><span style="font-size: small;">Why Phone + Cloud?<br />
Cross device.<br />
Platform as a service. Dont have to worry about scalability, O/S patching.<br />
Hosting payment: Utility billing = scales to usage. </span></p>
<p lang="en"><span style="font-size: small;">Identity<br />
custom, 3rd party one-login<br />
Storage<br />
SQL Azure, relational DB managed as a service<br />
Windows Azure Tables, non-relational, massive scale-out<br />
Windows Azure Blobs</span></p>
<p lang="en"><span style="font-size: small;">Services<br />
Web Role &#8211; IIS<br />
WorkerRole &#8211; background process</span></p>
<p><span style="font-size: small;">Windows Azure Toolkit for Android </span><a href="http://bit.ly/qG5twZ"><span style="color: #0000ff;"><span style="font-size: small;"><span style="text-decoration: underline;">http://bit.ly/qG5twZ</span></span></span></a></p>
<p lang="en">
<p lang="en">
<p lang="en"><span style="font-size: small;"><br />
</span></p>
<p lang="en"><span style="font-size: small;"><strong>Android Tips and Tricks: Joe Lallouz, Hashable </strong></span></p>
<p lang="en"><span style="font-size: small;">Hashable: Lightweight CRM, save &amp; remember people who you meet. </span></p>
<p lang="en"><span style="font-size: small;">Naming conventions. No nested directories in res folder <img src='http://www.regany.com/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /><br />
make resources easier to find. eg. icon_&lt;image name&gt;</span></p>
<p lang="en"><span style="font-size: small;">Design for:<br />
Screen Densities &amp; multiple sizes<br />
Orientation switching<br />
Touch Input</p>
<p>Dashboard style navigation</span></p>
<p lang="en"><span style="font-size: small;">Action Bar Design Pattern<br />
back button (people don&#8217;t know to press the softkey on the phone?)<br />
refresh buttons<br />
overflow button (people don&#8217;t know to press the softkey on the phone?)</span></p>
<p lang="en"><span style="font-size: small;">ViewPager<br />
swiping</span></p>
<p lang="en"><span style="font-size: small;">Honeycomb forward -&gt; ViewPropertyAnimator<br />
animation. think jQuery animtations</span></p>
<p lang="en"><span style="font-size: small;">Intents<br />
Register intent filters in the manifest!<br />
To open your app natively to bring people into your app more often.</span></p>
<p lang="en"><span style="font-size: small;">ContentProviders<br />
Sharing data outside your application<br />
Create maintainable api for other apps<br />
Use managed cursor loaders</span></p>
<p lang="en"><span style="font-size: small;">Fragments<br />
Reporting with Flurry, Acra<br />
automatic error reporting</span></p>
<p lang="en"><span style="font-size: small;">Use SDK Tools: logcat, layoutopt, hierarchyviewer, Monkey, Strict Mode</span></p>
<p lang="en"><span style="font-size: small;">Design for offline<br />
Leave the UI thread alone<br />
Beta test on the market<br />
Register company package &#8211; put it up on marketplace to hold the name</span></p>
<p lang="en"><span style="font-size: small;">* Always assume your task can be interrupted<br />
* Battery life</span></p>
<p lang="en"><span style="font-size: small;">Watch the Google I/O videos</span></p>
<p lang="en"><span style="font-size: small;">Drag down to refresh = Custom components, google it on github</span></p>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=350</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>AndroidTO Dev Stream notes: morning</title>
		<link>http://www.regany.com/?p=343</link>
		<comments>http://www.regany.com/?p=343#comments</comments>
		<pubDate>Wed, 26 Oct 2011 20:33:58 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[androidTO]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=343</guid>
		<description><![CDATA[Mobile versus Native: Chris Saunders, Shopify
+ Offline storage
Cache Manifest:
state files needed to cache to be available when no internet connection.
Can trick the browser into downloading new version of manifest version
&#60;html manifest=&#8221;"&#62; attribute
Use JS to detect when manifest has changed
Twitter web app sticky menu bar done through javascript.
+ 37 signals web app
Example:
Tools
Batman.js MVC framework (written in [...]]]></description>
			<content:encoded><![CDATA[<p lang="en"><span style="font-size: small;"><strong>Mobile versus Native: Chris Saunders, Shopify</strong></span></p>
<p lang="en"><span style="font-size: small;">+ Offline storage<br />
Cache Manifest:<br />
state files needed to cache to be available when no internet connection.<br />
Can trick the browser into downloading new version of manifest version<br />
&lt;html manifest=&#8221;"&gt; attribute<br />
Use JS to detect when manifest has changed</span></p>
<p lang="en"><span style="font-size: small;">Twitter web app sticky menu bar done through javascript.</span></p>
<p lang="en"><span style="font-size: small;">+ 37 signals web app</span></p>
<p lang="en"><span style="font-size: small;">Example:<br />
Tools<br />
Batman.js MVC framework (written in CoffeeScript compiles into JS&#8230;)<br />
+ rendering HTML adds additional attributes to DOM<br />
Skeleton CSS: 960 grid, responsive design for multiple resolutions<br />
View = HTML<br />
</span></p>
<p lang="en">
<p lang="en"><span style="font-size: small;"><strong>Flex Framework Development: Matthew Fabb, StickerYou</strong></span></p>
<p lang="en"><span style="font-size: small;">(PhoneGap acq.) can now compile SWFs to run on all mobile platforms.</span></p>
<p lang="en"><span style="font-size: small;">Apple iOS can run AIR applications.<br />
Android both Flash &amp; AIR; Chrome OS &amp; Google TV support Flash only.<br />
Future: BBX supports both, Windows Phone ?</span></p>
<p lang="en"><span style="font-size: small;">Air 3 -&gt; Air Native Extensions (ANE) = Native code can be combined with an AIR app<br />
AIR app to access any API<br />
=&gt; ANE file is compiled separate then compiled into AIR app</span></p>
<p lang="en"><span style="font-size: small;"> ANE can be bundled into hardware</span></p>
<p lang="en"><span style="font-size: small;">Flash Builder 4.6 will have built in ANE support</span></p>
<p lang="en"><span style="font-size: small;">Captive Runtime = AIR runtime can be packaged inside of an AIR app. Android doesn&#8217;t have to download runtime separately. </span></p>
<p lang="en"><span style="font-size: small;">Building for Air 3.01 will be integrated in FB 4.6.</span></p>
<p lang="en"><span style="font-size: small;">Future of AIR<br />
Photoshop Touch built in AIR<br />
Flex (= open source framework for creating Flash applications)<br />
CSS: can have dpi/OS specific styling/skinning<br />
FB: design view for multiple devices<br />
:debug on device through USB</span></p>
<p lang="en"><span style="font-size: small;"><strong>NFC: Tapping Into The Future: Matthew Patience / Greg Carron (MobiCartel)<br />
@pixeladdikt @MatthewPatience</strong></span></p>
<p lang="en"><span style="font-size: small;">NFC = Near Field Communication; proximity communication with the chip in your phone<br />
tap/swipe NFC sticker</span></p>
<p lang="en"><span style="font-size: small;">Current examples: Visa payWave, MasterCard paypass</span></p>
<p lang="en"><span style="font-size: small;">Android 4.0 &#8211; APIs for NFC slowly integrated over time through the Android versions. First in 2.3<br />
Android Beam application that does NDEF push.</span></p>
<p lang="en"><span style="font-size: small;">NXP = hardware manufacturer for chips. used to be in feature phones (Japan)</span></p>
<p lang="en"><span style="font-size: small;">Expected by 2015(?) 40% of all handsets will have NFC. Phone Manufacturers are pushing it out.</span></p>
<p lang="en"><span style="font-size: small;">ISIS: loyalty programs, coupons</span></p>
<p lang="en"><span style="font-size: small;">Google Wallet = App, put your CC&#8217;s in your device and choose your payment method<br />
Google Offers = push discounts to your phone and use with Google Wallet</span></p>
<p lang="en"><span style="font-size: small;">PayPal = touch phones to transfer money</span></p>
<p><span style="font-size: small;">Other Examples:<br />
Grocery stores, text to speech<br />
Transit systems<br />
Medical history</span></p>
<p lang="en"><span style="font-size: small;">Not only for mobile payments:<br />
access control<br />
accessory pairing = connecting two devices quickly/easily (eg. instead of bluetooth)<br />
media sharing, smart posters<br />
ordering systems, menus in restaurants</span></p>
<p lang="en"><span style="font-size: small;">Adobe Air3 ANE plugins for NFC development</span></p>
<p lang="en"><span style="font-size: small;">Open Accessory Developer Kit IOIO using Arduino</span></p>
<p lang="en"><span style="font-size: small;">Q&amp;A:<br />
NFC standards are still being forged<br />
How much content can you have in a tag? kbs, can write xml to it<br />
Can buy tags online/customize them. NXP Tag Writer can erase/write to each tag.<br />
Tags can have specific URI to open a specific app.</span></p>
<p lang="en">
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=343</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Screen Scraping Wiki Hell</title>
		<link>http://www.regany.com/?p=340</link>
		<comments>http://www.regany.com/?p=340#comments</comments>
		<pubDate>Wed, 19 Oct 2011 19:24:09 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=340</guid>
		<description><![CDATA[This month, I&#8217;m porting wiki content from one wiki system (Confluence) to another wiki system (Lotus Connections). I started building a screen scraper in PHP by cobbling a bunch of code together. Why PHP? Because it was already on my system and there isn&#8217;t time to learn how to do it in anything else.
References:

JavaScript can [...]]]></description>
			<content:encoded><![CDATA[<p>This month, I&#8217;m porting wiki content from one wiki system (Confluence) to another wiki system (Lotus Connections). I started building a screen scraper in PHP by cobbling a bunch of code together. Why PHP? Because it was already on my system and there isn&#8217;t time to learn how to do it in anything else.</p>
<p>References:</p>
<ul>
<li><a href="http://ask.metafilter.com/23180/Client-side-screen-scraping-help" target="_blank">JavaScript can be used with a proxy</a></li>
<li><a href="http://www.sourcerally.net/regin/19-PHP-Screen-scraber-in-32-seconds">PHP screen scraper in 32 seconds</a></li>
</ul>
<p>There&#8217;s a specific Xpath that I need to extract out of the old system. It&#8217;s not like I need the whole page. At the moment it loads a URL and extracts the first instance of a class name and saves it to file.</p>
<pre class="brush: php;">
&lt;?php
$url = ''; //URL to scrape goes here
$filename = substr(strrchr($url, &quot;/&quot;), 1).'.html'; //last directory as filename

$doc = new DOMDocument;
@ $doc-&gt;loadHTMLFile($url);
//if you don't wanna see warning put an @ infront of the line above

$tagName = ''; // tag name that contains section to extract
$attrName = 'class';
$attrValue = ''; // class name of section to extract

$html = scrape($doc, $tagName, $attrName, $attrValue);

// write the extracted HTML to file
if (!$handle = fopen($filename, 'w')) {
	 echo &quot;Cannot open file ($filename)&quot;;
	 exit;
}
// Write $somecontent to our opened file.
if (fwrite($handle, $html) === FALSE) {
	echo &quot;Cannot write to file ($filename)&quot;;
	exit;
}
echo &quot;Success, wrote ($html) to file ($filename)&quot;;
fclose($handle);

// http://www.php.net/manual/en/domdocument.getelementsbytagname.php#100228
function scrape($dom, $tagName, $attrName, $attrValue){
    $html = '';
    $domxpath = new DOMXPath($dom);
    $newDom = new DOMDocument;
    $newDom-&gt;formatOutput = true;

    $filtered = $domxpath-&gt;query(&quot;//$tagName&quot; . '[@' . $attrName . &quot;='$attrValue']&quot;);
    // $filtered =  $domxpath-&gt;query('//div[@class=&quot;className&quot;]');
    // '//' when you don't know 'absolute' path

    // since above returns DomNodeList Object
    // use following routine to convert it to string(html);
        $myItem = $filtered-&gt;item(0); // only first one
        $node = $newDom-&gt;importNode( $myItem, true );    // import node
        $newDom-&gt;appendChild($node);                    // append node

    $html = $newDom-&gt;saveHTML();
    return $html;
}

?&gt;
</pre>
<p>Ideally I&#8217;d update it to include the following:</p>
<ul>
<li>Read in file/list of URLs instead of having it hard-coded</li>
<li>Find and replace all styles used on the old wiki to use the new styles/layout for the new system.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=340</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>CSS3 text effect: long shadow?</title>
		<link>http://www.regany.com/?p=334</link>
		<comments>http://www.regany.com/?p=334#comments</comments>
		<pubDate>Sun, 02 Oct 2011 22:24:47 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[css3]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=334</guid>
		<description><![CDATA[I was fiddling with pure CSS3 transforms today, and found some really good articles that made me remember why I hung out in the Math Club in university:  The CSS3 matrix() Transform for the Mathematically Challenged
Anyway, my goal was to try and create a text effect that looks like a long perspective shadow or reflection. Apparently [...]]]></description>
			<content:encoded><![CDATA[<p>I was fiddling with pure CSS3 transforms today, and found some really good articles that made me remember why I hung out in the Math Club in university:  <a href="http://www.useragentman.com/blog/2011/01/07/css3-matrix-transform-for-the-mathematically-challenged/" target="_blank">The CSS3 <code>matrix()</code> Transform for the Mathematically Challenged</a></p>
<p>Anyway, my goal was to try and create a text effect that looks like a long perspective shadow or reflection. Apparently reflection is easy, but the perspective is not. <a href="http://www.webkit.org/blog/386/3d-transforms/">Webkit&#8217;s description of the perspective/origin property</a> finally clicked in my head. The <a href="http://www.webkit.org/blog-files/3d-transforms/perspective-by-example.html">example&#8217;s </a>not bad either, but for some reason it was still hard to get what I wanted.</p>
<p>I got as far as this:<br />
<iframe style="width: 100%; height: 300px" src="http://jsfiddle.net/CRbJ2/1/embedded/result,css,html"></iframe></p>
<p>Not as long as I hoped since I guess I&#8217;m just rotating about the X-axis and anything that is not 0 or 180 degrees is not even going to be full height. ScaleY(-1) will probably work better and then skewing for height&#8230; hmm&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=334</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hey, cool, it&#8217;s alive.</title>
		<link>http://www.regany.com/?p=330</link>
		<comments>http://www.regany.com/?p=330#comments</comments>
		<pubDate>Thu, 22 Sep 2011 16:13:30 +0000</pubDate>
		<dc:creator>Regan</dc:creator>
				<category><![CDATA[Portfolio]]></category>

		<guid isPermaLink="false">http://www.regany.com/?p=330</guid>
		<description><![CDATA[The site skinning for The Government of The Bahamas portal I did earlier this year is live.
Read the lessons learned.
]]></description>
			<content:encoded><![CDATA[<p>The site skinning for <a href="http://www.bahamas.gov.bs/">The Government of The Bahamas</a> portal I did earlier this year is live.</p>
<p><span style="font-weight: normal;">Read the <a href="http://www.regany.com/?p=283">lessons learned</a>.</span></p>
]]></content:encoded>
			<wfw:commentRss>http://www.regany.com/?feed=rss2&amp;p=330</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

