<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/2.0.4" -->
<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/"
	>

<channel>
	<title>Fighting Monsters</title>
	<link>http://bigmojo.net/monsters</link>
	<description>Monsters need fightin.</description>
	<pubDate>Wed, 14 May 2008 14:18:21 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.0.4</generator>
	<language>en</language>
			<item>
		<title>Using .net to parse a csv with quote delimination</title>
		<link>http://bigmojo.net/monsters/?p=56</link>
		<comments>http://bigmojo.net/monsters/?p=56#comments</comments>
		<pubDate>Fri, 09 May 2008 14:00:36 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Uncategorized</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=56</guid>
		<description><![CDATA[  So I have a csv file, and it has quote delimination, eg:
one,two,"with , comma",four
There are a million examples of baroque regex strings to parse these, but I couldn&#8217;t seem to get any of them to work. So I wrote a small bit of code to parse each line. 
Essentially pass each line into this [...] ]]></description>
			<content:encoded><![CDATA[<p> So I have a csv file, and it has quote delimination, eg:<br />
<code>one,two,"with , comma",four</code></p>
<p>There are a million examples of baroque regex strings to parse these, but I couldn&#8217;t seem to get any of them to work. So I wrote a small bit of code to parse each line. </p>
<p>Essentially pass each line into this code as a string, and it returns an array of values. Sorry for the bad spacing, wordpress y&#8217;all.</p>
<blockquote><p>class Program<br />
    {<br />
        public enum parseState<br />
        {<br />
            word,<br />
            comma,<br />
            quote<br />
        }</p>
<p>        public Program(){<br />
        }</p>
<p>        public ArrayList parse(string text)<br />
        {</p>
<p>            ArrayList vals = new ArrayList();<br />
            int i =0;<br />
            while (i < text.Length)<br />
            {<br />
                vals.Add(GetWord(text,ref  i));<br />
            }<br />
            //special handling if the last char is empty<br />
            if (text[text.Length -1].ToString() == ",")<br />
            {<br />
                //append an empty val<br />
                vals.Add(String.Empty);<br />
            }</p>
<p>            return vals;</p>
<p>        }</p>
<p>        private string GetWord(string text, ref int position)<br />
        {<br />
            parseState state = parseState.word;<br />
            string word = string.Empty;<br />
            while (position < text.Length)<br />
            {<br />
                string letter = text[position].ToString();<br />
                position++;<br />
                switch (letter)<br />
                {<br />
                    case ",":<br />
                        if (state == parseState.word)<br />
                        {<br />
                            //were done;</p>
<p>                            return word;<br />
                        }<br />
                        else if (state == parseState.quote)<br />
                        {<br />
                            //were in a quoted section add it<br />
                            word += letter;<br />
                        }<br />
                        else if (state == parseState.comma)<br />
                        {<br />
                            //empty string, fair enough, return it<br />
                            //were done;<br />
                            return word;<br />
                        }<br />
                        break;<br />
                    case "\"":<br />
                        if (state == parseState.word || state == parseState.comma)<br />
                        {<br />
                            //beginning of quoted section<br />
                            state = parseState.quote;<br />
                        }<br />
                        else if (state == parseState.quote)<br />
                        {<br />
                            //end of a quoted section<br />
                            //were done<br />
                            return word;<br />
                        }<br />
                        break;<br />
                    default:<br />
                        if (state == parseState.word)<br />
                        {<br />
                            //normal<br />
                            word += letter;<br />
                        }<br />
                        else if (state == parseState.quote)<br />
                        {<br />
                           //were in a quoted word<br />
                            word += letter;<br />
                        }<br />
                        else if (state == parseState.comma)<br />
                        {<br />
                            //start of a word, fine.<br />
                            word += letter;<br />
                            state = parseState.word;<br />
                        }<br />
                        break;</p>
<p>                }</p>
<p>            }<br />
            return word;<br />
        }<br />
    }</p></blockquote>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=56</wfw:commentRSS>
		</item>
		<item>
		<title>Your First Facebook Application</title>
		<link>http://bigmojo.net/monsters/?p=55</link>
		<comments>http://bigmojo.net/monsters/?p=55#comments</comments>
		<pubDate>Tue, 22 Apr 2008 14:04:20 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Uncategorized</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=55</guid>
		<description><![CDATA[  Reposted from an article I wrote for Codesta.com article here

Writing a Facebook Application
With the rise of social network applications such as Facebook over the last 3 - 5 years, it&#8217;s become very attractive to be present in that space.&#160; Facebook applications are most often games that allow users to play against each other, or [...] ]]></description>
			<content:encoded><![CDATA[<p> Reposted from an article I wrote for <a href="http://codesta.com">Codesta.com</a> article <a href="http://blog.codesta.com/codesta_weblog/2008/01/your-first-face.html">here</a><br />
<hr /></p>
<p><span style="font-size: 1.4em;">Writing a Facebook Application</span></p>
<p>With the rise of social network applications such as Facebook over the last 3 - 5 years, it&#8217;s become very attractive to be present in that space.&nbsp; Facebook applications are most often games that allow users to play against each other, or themselves in the case of solo-games, but there is no technology limit to this. The application could easily be an extension of your own application.</p>
<p>One of the many great things you get from using the Facebook platform, is an<br />
enormous list of potential clients who already have user/login info<br />
for your application! Couple this with the outsourcing of user login/management/authentication to another provider (Facebook), access to the Facebook messaging API, and it&#8217;s easy to see the return on investment.</p>
<p><span style="font-size: 1.4em;">Getting Started</span></p>
<p>Assuming you have a <a href="http://www.facebook.com">Facebook account</a> , you will need to install the <a href="http://developers.facebook.com/">Facebook developer application </a>. Once you have the developer application installed, you should be directed to the <a href="http://www.facebook.com/developers/apps.php ">developer home page</a>, and here you can apply for an application key. When you apply for an application key, it asks for an application name, we&#8217;ll call ours Hello World. Now that you have a Facebook application registered, you can retrieve your API key, and secret key from the <a href="http://www.facebook.com/developers/apps.php">installed applications page</a>.</p>
<p>We will be building a .NET application using the .NET <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=CCD46762-45EC-4FBE-AD91-FC916671E734">Facebook dev kit</a> from Microsoft , but you can use any modern language. There are development libraries available for all of them, and the developers wiki is a great resource&#8230; <a href="http://wiki.developers.facebook.com/index.php/Main_Page">here</a> is the link.</p>
<p>Assuming you will be developing using your local machine, we need to configure a couple values in your Facebook application, which can be done on the application settings you can access from the applications page <a href="http://www.facebook.com/developers/apps.php">here</a>.&nbsp; </p>
<ul>
<li>Set your <strong>Callback URL </strong>to your local instance url (e.g. http://localhost/); if you are using Visual Studio&#8217;s built in server/debugging, then you will need to fix the port that it uses, and enter that as your Callback URL. If you are using a public server, then enter the URL for that server in this box.</li>
<li>Set your <strong>Canvas Page URL </strong>to anything you like, this is the url that Facebook users will use to access your application.</li>
<li>Set the application to iFrame - This allows you to have any content you choose, without being limited by the FBML (Facebook Markup Language) and it&#8217;s slow rendering times.</li>
<li>Set the application type to <strong>Website.</strong></li>
</ul>
<p>There are many more options there that you can play with , but these are the ones you need to get your application running.</p>
<p>After installing the Facebook Dev Kit from Microsoft, you will have the Facebook libraries located in the install location (<strong>C:\Program Files\Facebook Developer Toolkit</strong>). There will now be Facebook components available in Visual Studio, but we will do our example by hand.</p>
<p><span style="font-size: 1.4em;">The Code</span></p>
<p>Create a new web page project, and open Default.aspx to insert the following content:</p>
<p><span style="font-size: 0.8em;"><strong>&lt;%@ Page Language=&quot;C#&quot; AutoEventWireup=&quot;true&quot; CodeBehind=&quot;HelloWorld.aspx.cs&quot; Inherits=&quot;</strong></span><span style="font-size: 0.8em;"><strong>HelloWorld</strong></span><span style="font-size: 0.8em;"><strong>._default&quot; %&gt;<br />&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;&gt;<br />&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; &gt;<br />&lt;head id=&quot;Head1&quot; runat=&quot;server&quot;&gt;<br />&nbsp; &nbsp; &lt;title&gt;FaceBook Hello World&lt;/title&gt;<br />&lt;/head&gt;<br />&lt;body&gt;<br />&nbsp; &nbsp; &lt;form id=&quot;form1&quot; runat=&quot;server&quot;&gt;<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &lt;h1&gt;Ours&lt;/h1&gt;<br />&nbsp; &nbsp; &lt;asp:Repeater ID=&quot;friendList&quot; runat=&quot;server&quot;&gt;<br />&nbsp; &nbsp; &lt;HeaderTemplate&gt;<br />&nbsp; &nbsp; &lt;table&gt;<br />&nbsp; &nbsp; &lt;tr&gt;<br />&nbsp; &nbsp; &lt;td&gt;&lt;b&gt;Name&lt;/b&gt;&lt;/td&gt;&lt;td&gt;&lt;b&gt;Photo&lt;/b&gt;&lt;/td&gt;<br />&nbsp; &nbsp; &lt;/tr&gt;<br />&nbsp; &nbsp; &lt;/HeaderTemplate&gt;<br />&nbsp; &nbsp; &lt;ItemTemplate&gt;&lt;tr&gt;&lt;td&gt;&lt;%#DataBinder.Eval(Container.DataItem,&quot;Name&quot;)%&gt;&lt;/td&gt;<br />&nbsp; &nbsp; &lt;td&gt;&lt;img src=&quot;&lt;%#DataBinder.Eval(Container.DataItem,&quot;PictureUrl&quot;)%&gt;&quot; /&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/ItemTemplate&gt; <br />&nbsp; &nbsp; &lt;FooterTemplate&gt;<br />&nbsp; &nbsp; &lt;/table&gt;<br />&nbsp; &nbsp; &lt;/FooterTemplate&gt;<br />&nbsp; &nbsp; &lt;/asp:Repeater&gt;<br />&nbsp; &nbsp; &lt;/form&gt;<br />&lt;/body&gt;<br />&lt;/html&gt;</strong></span></p>
<p>Now open the code behind file <strong>Default.aspx.cs</strong> , and populate it with this</p>
<p><strong><span style="font-size: 0.8em;">using System;<br />using System.Data;<br />using System.Configuration;<br />using System.Collections;<br />using System.Linq;<br />using System.Web;<br />using System.Web.Security;<br />using System.Web.UI;<br />using System.Web.UI.WebControls;<br />using System.Web.UI.WebControls.WebParts;<br />using System.Web.UI.HtmlControls;<br />using System.Collections.ObjectModel;<br />namespace </span><span style="font-size: 0.8em;">HelloWorld</span><br /><span style="font-size: 0.8em;">{<br />&nbsp; &nbsp; public partial class _default : System.Web.UI.Page<br />&nbsp; &nbsp; {<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; private Facebook.Components.FacebookService _facebookApi = new Facebook.Components.FacebookService();</span></strong></p>
<p><strong><span style="font-size: 0.8em;">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; protected void Page_Load(object sender, EventArgs e)<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; {</span></strong></p>
<p><strong><span style="font-size: 0.8em;">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;// ApplicationKey and Secret are acquired when you sign up for <br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;_facebookApi.ApplicationKey = &quot;[YOUR KEY]&quot;;<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;_facebookApi.Secret = &quot;[YOUR SECRET KEY]&quot;;<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;_facebookApi.IsDesktopApplication = false;</span></strong></p>
<p><strong><span style="font-size: 0.8em;">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;string sessionKey = Session[&quot;Facebook_session_key&quot;] as String;<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;string userId = Session[&quot;Facebook_userId&quot;] as String;</span></strong></p>
<p><strong><span style="font-size: 0.8em;">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;// When the user uses the Facebook login page, the redirect back here will will have the auth_token in the query params</span></strong></p>
<p><strong><span style="font-size: 0.8em;">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;string authToken = Request.QueryString[&quot;auth_token&quot;];</span></strong></p>
<p><strong><span style="font-size: 0.8em;">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;if (!String.IsNullOrEmpty(sessionKey))<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;{<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; _facebookApi.SessionKey = sessionKey;<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;}<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;else if (!String.IsNullOrEmpty(authToken))<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;{<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; _facebookApi.CreateSession(authToken);<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; Session[&quot;Facebook_session_key&quot;] = _facebookApi.SessionKey;<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;}<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;else<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;{<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; Response.Redirect(@&quot;http://www.Facebook.com/login.php?api_key=&quot; + _facebookApi.ApplicationKey + @&quot;&amp;v=1.0&quot;);<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;}</span></strong></p>
<p><strong><span style="font-size: 0.8em;">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;if (!IsPostBack)<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;{<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; // Get our list of friends<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; Collection&lt;Facebook.Entity.User&gt; friends = _facebookApi.GetFriends();</span></strong></p>
<p><strong><span style="font-size: 0.8em;">&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; //bind our repeater<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; friendList.DataSource = friends;<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; friendList.DataBind();<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;}<br />&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; }<br />&nbsp; &nbsp; }<br />}</span></strong></p>
<p>The basics here should be clear. You set your application and secret keys, and then your basically good to go! The Facebook.Components.FacebookService class provides access to the current user, and if they aren&#8217;t logged in you can bounce them to the Facebook login screen.</p>
<p>To go live with your project, simply move the code to a public server, change your callback url in the application settings page within Facebook and select the &#8216;<strong>add application to directory</strong>&#8216; check box on that same page.</p>
<p>Now that you have the user authenticated, and access to their friends list, the sky is the limit. We chose to store user keys in our database for customizations which we simply did using their Facebook ID. </p>
<p><span style="font-size: 1.4em;">In Conclusion</span></p>
<p>In practice I found the Facebook API to be very usable, and there were no unexpected hurdles to work around. We did have an occasional user authentication error, which may have been caused by having mutliple users logged in on the same machine, but this was an edge case. </p>
<p>In all, I wouldn&#8217;t hesitate to recommend the platform as an extension of an existing business giving a low-cost, low-risk entry into the seemingly persistent world of Social Networking Applications. However, I would hesitate before putting serious development into a FBML application, or anything that specifically required Facebook, for the same reasons I wouldn&#8217;t want to own a million dollar application that only ran in Friendster, Tribe.net or any of the other Social Networking sites that had their time in the sun.</p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=55</wfw:commentRSS>
		</item>
		<item>
		<title>The move to ubuntu</title>
		<link>http://bigmojo.net/monsters/?p=50</link>
		<comments>http://bigmojo.net/monsters/?p=50#comments</comments>
		<pubDate>Tue, 26 Feb 2008 16:14:53 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Uncategorized</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=50</guid>
		<description><![CDATA[  I&#8217;d been running Ubuntu in a dual boot environment for about 8 months (using the great Wubi to install it) , and finally decided to take the plunge, and go ubuntu as my main OS.
Installing Ubuntu is dead easy, although each time I&#8217;ve done it, i&#8217;ve had to use the alternate cd which is [...] ]]></description>
			<content:encoded><![CDATA[<p> I&#8217;d been running Ubuntu in a dual boot environment for about 8 months (using the great <a href="http://wubi-installer.org/">Wubi</a> to install it) , and finally decided to take the plunge, and go ubuntu as my main OS.</p>
<p>Installing Ubuntu is dead easy, although each time I&#8217;ve done it, i&#8217;ve had to use the alternate cd which is a text based install, not sure why that is.</p>
<p>Being a windows developer, I needed to maintain an environment for development, and I had decided to use VMWare to do this. After seeing the $200 price tag, i decided it was worth a look around for alternatives, enter <a href="http://www.virtualbox.org/">VirtualBox</a>.</p>
<p>To support the move I got all new hardware as my old AMD 2800XP was showing its age badly, the reason i moved to Ubuntu in the first place. </p>
<p>After a few steps, namely downloading the deb from their site, instead of using the repository, and there are some steps to get usb working on Ubuntu <a href="http://www.virtualbox.org/wiki/USB_on_Ubuntu_7.04">here</a> ( they say they are for 7.04, i did these steps for 7.1 without a problem) It was up and running like a champ!</p>
<p>Installing windows on the virtualBox machine, took about 10 minutes, the fastest by far I have ever seen it install, of course this is thanks to my new hardware, but I was very impressed! </p>
<p>And here we are, running windows on Ubuntu, full colour and all!<br />
<a href="http://bigmojo.net/bill/blogresources/virtualBox.png" target="_new"><img src="http://bigmojo.net/bill/blogresources/virtualBox_th.png" alt="VirtualBox on Ubuntu" /></a></p>
<p>&#8212;update&#8211;</p>
<p>After installing VirtualBox&#8217;s guest additions into my windows environment (same as the virtual pc, or VMware additions) I can arbitrarily resize my virtualbox, including fullscreen. Which, is pretty amazing, check the video.</p>
<p><object width="425" height="350"><br />
<param name="movie" value="http://www.youtube.com/v/Xx2dXCCREu4"> </param> <embed src="http://www.youtube.com/v/Xx2dXCCREu4" type="application/x-shockwave-flash" width="425" height="350"> </embed> </object>
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=50</wfw:commentRSS>
		</item>
		<item>
		<title>Million Dollar Idea</title>
		<link>http://bigmojo.net/monsters/?p=49</link>
		<comments>http://bigmojo.net/monsters/?p=49#comments</comments>
		<pubDate>Tue, 08 Jan 2008 23:18:37 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Uncategorized</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=49</guid>
		<description><![CDATA[  My new database design is unstoppable!




 ]]></description>
			<content:encoded><![CDATA[<p> My new database design is unstoppable!<br />
<center><br />
<img src="/bill/blogresources/stuff.jpg"><br />
</center>
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=49</wfw:commentRSS>
		</item>
		<item>
		<title>Interface Idea for a decision tree</title>
		<link>http://bigmojo.net/monsters/?p=48</link>
		<comments>http://bigmojo.net/monsters/?p=48#comments</comments>
		<pubDate>Thu, 08 Nov 2007 20:59:49 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Uncategorized</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=48</guid>
		<description><![CDATA[  Often we force users to make a series of choices, which is fine, but how do we make it easy for them to keep track of their choices? And how do they know how to change their minds?
A common solution is the cookie trail, which is alright, but its dual purposing from navigation to [...] ]]></description>
			<content:encoded><![CDATA[<p> Often we force users to make a series of choices, which is fine, but how do we make it easy for them to keep track of their choices? And how do they know how to change their minds?</p>
<p>A common solution is the cookie trail, which is alright, but its dual purposing from navigation to choice trail never sat right with me.</p>
<p>Playing with some of the iPhone navigation , I got thinking that this would be a good way to do a choice tree, and this is my not very pretty version of that (IANAD), so imagine it all rounded and grey/blue.</p>
<p>The hooks are all in place where this could be tied to some ajax to load the questions/save the choices, but here we have a rough version of the functionality. </p>
<p>Some flickering is present, i understand this can be corrected in scriptaculous, but that&#8217;s not what I&#8217;m here for.<br /> In both of these, make sure and try to change one of your decisions, by clicking it.</p>
<p><a href="javascript:void(0);" onclick="javascript:window.open('http://bigmojo.net/bill/decisiontreeV2/', 'nav', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=550,height=650,left = 440,top = 212'); return false;">Heres one version, which is good for a web interface I think</a></p>
<p><a href="javascript:void(0);" onclick="javascript:window.open('http://bigmojo.net/bill/decisiontree/', 'nav', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=550,height=650,left = 440,top = 212'); return false;">This version, I think the idea would map to an iphone style interface nicely.</a></p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=48</wfw:commentRSS>
		</item>
		<item>
		<title>Adobe apollo / air</title>
		<link>http://bigmojo.net/monsters/?p=46</link>
		<comments>http://bigmojo.net/monsters/?p=46#comments</comments>
		<pubDate>Fri, 31 Aug 2007 15:44:14 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Uncategorized</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=46</guid>
		<description><![CDATA[  So,
I&#8217;ve seen this one coming for a while, and I&#8217;m in favor. Essentially AIR (adobe integrated runtime) is a standalone browser. So you can run websites like applications on your desktop.
The freedom of developing web tech without worrying about browser compatibility is a grand thing indeed. I knocked out this sample app in about [...] ]]></description>
			<content:encoded><![CDATA[<p> So,</p>
<p>I&#8217;ve seen this one coming for a while, and I&#8217;m in favor. Essentially AIR (adobe integrated runtime) is a standalone browser. So you can run websites like applications on your desktop.</p>
<p>The freedom of developing web tech without worrying about browser compatibility is a grand thing indeed. I knocked out this sample app in about 45 minutes, it&#8217;s enabled by the fact that air lets you do cross domain httprequests. </p>
<p>You&#8217;ll need to install the air platform from <a href="http://labs.adobe.com/technologies/air/">here</a></p>
<p>Heres the <a href="http://bigmojo.net/bill/blogresources/vice.zip">source code</a> for the slideshow</p>
<p>So <a href="http://bigmojo.net/bill/blogresources/vice.air">here </a>you go, its a random slide show of the vicemagazine dos&#8217; and donts&#8217;.</p>
<p><a href="http://bigmojo.net/bill/blogresources/vice.air"><img border=0 src="http://bigmojo.net/bill/blogresources/air.jpg" alt="air" /></a></p>
<p>Enjoy
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=46</wfw:commentRSS>
		</item>
		<item>
		<title>Hardware Programming! The picKit2 from Microchip</title>
		<link>http://bigmojo.net/monsters/?p=45</link>
		<comments>http://bigmojo.net/monsters/?p=45#comments</comments>
		<pubDate>Sat, 14 Apr 2007 02:40:08 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Coding</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=45</guid>
		<description><![CDATA[  So I&#8217;ve wanted to learn some hardware programming for quite a while, and have now taken the first step!
A popular choice of learning resources is the company microchip.com , they have a product called the picKit 2, which is a &#8216;demo board&#8217; . After much reading i understand that this is a circuit designed [...] ]]></description>
			<content:encoded><![CDATA[<p> So I&#8217;ve wanted to learn some hardware programming for quite a while, and have now taken the first step!</p>
<p>A popular choice of learning resources is the company <a href="http://microchip.com">microchip.com</a> , they have a product called the picKit 2, which is a &#8216;demo board&#8217; . After much reading i understand that this is a circuit designed to help you get up and running quickly. </p>
<p>In the case of the pickit2, this means it has a processor on board ( the pic16f917 ) , a bunch of led&#8217;s already wired in , a potentiometer (turny switch) and a button.. as well as a bunch of open outputs for you to do whatever you like with.</p>
<p>This is not something for the faint of heart it would appear, so after stumbling around the documentation and sample code for a while, i bought this book <a href="http://www.amazon.com/PIC-Microcontroller-Personal-Introductory-Course/dp/0750666641/ref=pd_bbs_sr_1/104-7999694-7995111?ie=UTF8&#038;s=books&#038;qid=1176517174&#038;sr=8-1">The Pic Microcontroller, your personal introductory course</a>, a promising name.</p>
<p>The book is very well written, and after the first 2 chapters i felt much more able to approach my board.</p>
<p>The demo board comes with a usb device that attaches it to the computer, i&#8217;ve learned that this is a &#8216;programmer&#8217; , which is in charge of delivering the compiled code to the chip itself, the integration of this is one of the things that makes this a &#8216;demo&#8217; board.</p>
<p>After some more reading, i tried out my first program, borrowing some sample code from one of the existing projects, I had success! </p>
<p>See here my first program running, in all it&#8217;s glorious 7 lights on, 1 light off glory!</p>
<p><img src="http://bigmojo.net/bill/blogresources/pic.jpg" alt="pic!" /></p>
<p>Functionally, every 8 outputs get assigned a file register (memory location), and by assigning an 8 bit binary value to this location, you can set the pins as either on, or off. So to set the first pin on, you use a value of 00000001 , the first and last as 10000001, etc&#8230; The default numbering system in assembly is <a href="http://en.wikipedia.org/wiki/Hexidecimal">hexidecimal</a>, so you represent these as hex, so, 00000001 = 1, 10000001 = 81.</p>
<p>Here is the functional element to my program, which turned all pins on, except for the 2nd pin.<br />
================<br />
<strong></p>
<p>MainLoop<br />
	movlw	0xfd<br />
	movwf	PORTD</p>
<p>	goto	MainLoop<br />
</strong><br />
================</p>
<p>so, as you can see here I am using the hex value fd, and assigning it to the file page that controls my led&#8217;s. fd of course equals 253 in decimal, or 11111101 in binary, so you can see the led that&#8217;s off. The other commands are pretty simple as well<br />
<strong>mov </strong>= mov<br />
<strong>l</strong> = literal<br />
<strong>w</strong> = working register (you only get one of these, everything moves through it)<br />
<strong>f</strong> = file page</p>
<p>so<br />
<strong>movlw	0xfd</strong><br />
means, move a literal into the working register, and then i give the literal <strong>0xfd </strong>, 0x just means its a hex number. I could aslo have used <strong>movlw	b&#8217;11111101 </strong>, or for that matter <strong>movlw d&#8217;253</strong></p>
<p>and then<br />
<strong>movwf PORTD</strong><br />
means, move the working register into the filepage PORTD (my output register). </p>
<p>Really pretty simple at the end of the day, once your environment is running.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=45</wfw:commentRSS>
		</item>
		<item>
		<title>IE Mysteriously not allowing cookies</title>
		<link>http://bigmojo.net/monsters/?p=44</link>
		<comments>http://bigmojo.net/monsters/?p=44#comments</comments>
		<pubDate>Wed, 07 Mar 2007 22:25:58 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Coding</category>
	<category>Tech Stuff</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=44</guid>
		<description><![CDATA[  So,
All of a sudden an application I had written started being buggy in that if you were using IE, you wouldn&#8217;t stay logged in after the initial login.
A bit of investigation showed that the session cookie wasn&#8217;t being set, odd.. it had been working. A quick workaround in IIS was to set the session [...] ]]></description>
			<content:encoded><![CDATA[<p> So,</p>
<p>All of a sudden an application I had written started being buggy in that if you were using IE, you wouldn&#8217;t stay logged in after the initial login.</p>
<p>A bit of investigation showed that the session cookie wasn&#8217;t being set, odd.. it had been working. A quick workaround in IIS was to set the session management to be url based, but this caused horrors to happen to the url (it prepending all links with a session key hash).</p>
<p>The answer at the end of the day, was that ie will reject cookies from domains that have an underscore &#8216;_&#8217; in them, and indeed in this case mine did (some_sub_domain.mydomain.com) . </p>
<p>So changing that fixed the problem, caveat emptor! you may be able to set any crazy subdomain you want, but be careful. It would seem that _ is not valid as far as the official RFC is concerned (can&#8217;t find that myself) , and so some apps care, some don&#8217;t.</p>
<p>Another interesting discovery here was the IIS Session State Management control panel, where you can set it to be cookie, url, autodetect, a session server (that&#8217;s interesting) or custom (guess you&#8217;d roll your own) . This explains part of how to do web app load balancing and such with shared sessions.</p>
<p>Click this image to see the menu in context<br />
<a href="http://bigmojo.net/monsters/wp-content/uploads/2007/03/big_iis.gif" target="_new"><img src="http://bigmojo.net/monsters/wp-content/uploads/2007/03/small_iis.gif" alt="Small iis" /></a>
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=44</wfw:commentRSS>
		</item>
		<item>
		<title>Yahoo Pipes, what an odd beast.</title>
		<link>http://bigmojo.net/monsters/?p=42</link>
		<comments>http://bigmojo.net/monsters/?p=42#comments</comments>
		<pubDate>Fri, 16 Feb 2007 23:00:47 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Tech Stuff</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=42</guid>
		<description><![CDATA[  I&#8217;m an RSS proponent , I think it&#8217;s great. It truly has revolutionized how I use the Internet, while be it a pretty low- key revolution, the ones that stick often are.
I have about 50 rss feeds I use, but most of them are duplications of one another, meta-news is the new news. We [...] ]]></description>
			<content:encoded><![CDATA[<p> I&#8217;m an RSS proponent , I think it&#8217;s great. It truly has revolutionized how I use the Internet, while be it a pretty low- key revolution, the ones that stick often are.</p>
<p>I have about 50 rss feeds I use, but most of them are duplications of one another, meta-news is the new news. We report about someone reporting about someone reporting. </p>
<p>A lot of this is caused I think by a 50/50 mix of politeness and fear. Politeness plays in when we want to give credit to someone, so that were not plagiarizing, which makes us somehow more &#8216;reliable&#8217; ? Fear in that if we don&#8217;t give that credit , we&#8217;ll get a nasty letter from someone with initials after their name. So you get an article on site A, verbatim from site B with a link to site B, and on site B the article is actually just a paraphrasing of an article on site C, with link, etc&#8230;.</p>
<p>The need for RSS mangement is becoming clear (to those who use RSS) and tool for this start to pop up all over the place, enter <a href="http://pipes.yahoo.com">Yahoo Pipes</a></p>
<p>There has been a rush of articles about pipes as of late, so I won&#8217;t belabor the point, other than to give a simple clear example of how one of my pipes that I find usefull.</p>
<p>Pipes allows you to perform logical operations on rss data, by this I mean simple programmatic functions (if,else,foreach, etc&#8230;) , and at first it&#8217;s hard to think of exactly how this is usefull, but with a bit of thought it becomes evident.</p>
<p>I like my gadgets, as much or more than the next guy, but gadget sites are in a strange and twisted love affair with cell phones that I do not share. So , amalgamate my gadget feeds , and remove cell phones!</p>
<p>Here you can see my pipe built up, <a href="http://engadget.com">engadget </a>and <a href="http://gizmodo.com">gizmodo </a>feeds added, then I use the union tool to combine them, and lastly the filter tool to filter out any articles that have the words &#8220;phone&#8221; or &#8220;mobile&#8221; in them. Very simple, but very useful. </p>
<p><img src="http://bigmojo.net/monsters/wp-content/uploads/2007/02/pipes.png" alt="Pipes" /></p>
<p>This also suits me fine for just amalgamating, in all honesty I&#8217;m not bothered which of these sites points me to a neat toy, I&#8217;m intertested in the toy, not who linked to it.</p>
<p>As a point of review, the pipes interface is very advanced DHTML, the connecting lines operate arguably nicer than the ones in Visio, in that they highlight possible points of attachment. As well as that is a debug window at the bottom, allowing you to see the output of any particular node in your pipe. </p>
<p>I think Yahoo has done a really neat thing here.
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=42</wfw:commentRSS>
		</item>
		<item>
		<title>Just Relax - the problem with Permissions.</title>
		<link>http://bigmojo.net/monsters/?p=43</link>
		<comments>http://bigmojo.net/monsters/?p=43#comments</comments>
		<pubDate>Thu, 15 Feb 2007 23:28:58 +0000</pubDate>
		<dc:creator>monsters</dc:creator>
		
	<category>Tech Stuff</category>
		<guid isPermaLink="false">http://bigmojo.net/monsters/?p=43</guid>
		<description><![CDATA[  I&#8217;ve been thinking about writing about this for a while, and a post at 37signals has encouraged me to do so .
Having been involved in designing a number of CMS systems, user content systems, and general business process/management systems, without fail, every one of these has run into huge problems around the issues of [...] ]]></description>
			<content:encoded><![CDATA[<p> I&#8217;ve been thinking about writing about this for a while, and a post at <a href="http://www.37signals.com/svn/posts/272-control-vs-communication">37signals </a>has encouraged me to do so .</p>
<p>Having been involved in designing a number of CMS systems, user content systems, and general business process/management systems, without fail, every one of these has run into huge problems around the issues of permissions. </p>
<p>To illustrate, lets look at a hypothetical situation:</p>
<p>Company A has a content management system , which allows them to update the content on their customer support site.</p>
<p>Now, the basic problem here is simple, allow them to post common questions, and answers to those questions, provide a method for customers to ask new questions, and maybe a small system to display the &#8216;most popular answers&#8217; type of thing.<br />
Here we&#8217;ve described a 2 week project (not including designer time).</p>
<p>Enter &#8216;the problem&#8217; .<br />
Who gets to answer the questions<br />
Who gets to edit the questions<br />
Who gets to edit the introduction/content on the various pages<br />
Who gets to edit that content.</p>
<p>Very , VERY quickly, this turns into a blooming tree of permissions. Permissions on objects, that inherit from permissions on object types, that inherit from areas of focus, differences in contributor vs. editor vs. publisher roles, roles per area of focus, etc&#8230;</p>
<p>What I see happening here, time and time again, is you end up building a permissions system, not a system to manage the support site. And the question I have to ask is </p>
<p><strong><font size=+2>Is this the business your in?</font></strong></p>
<p>Are you in the business of creating permissions based editing systems? I&#8217;m willing to bet the answer is <strong>no</strong>. You&#8217;re in the business of delivering your product, and all you need here is people to help answer the questions. Whether you&#8217;re building this internally, or paying an outside company/contractor, ultimately it is still your company doing the project, your time and money.</p>
<p>Remove all the permissions, except for maybe admin/not-admin , log who creates/edits content, and move on. Allow it to be a 2 week project; not a 2 month project that will never satisfy the increasingly byzantine permissions needs.</p>
<p>There is a clich&#233; in film, which is that if a crane is rented, every shot is a crane shot. In short, just because you CAN create these permissions structures, doesn&#8217;t make them beneficial to your business. </p>
<p>It&#8217;s important to realize that traditional business process, and communication, are still the forces that make business successful, simply talk to people, and have them be responsible for the content they edit/submit, they are the people who run the business! </p>
<p>In the same way that people are responsible for locking the door when they leave, they are responsible for following basic business rules for this kind of exercise. You trust your staff to operate a part of your company, why wouldn&#8217;t you trust them with this? If you don&#8217;t , then perhaps your company has larger problems.</p>
<p>Concentrate on the core deliverables of these ancillary projects, and be very skeptical of anything outside that, the &#8216;bare minimum&#8217; gets a bad wrap. With the definitioin of bare minimum to mean &#8220;the least that can be done to <strong>adequately </strong>satisfy the goals of a project&#8221; , then 9/10 times (especially in areas that are not core), bare minimum is exactly what you should be striving for.</p>
<p>Keep focus on &#8220;what is our business&#8221; , because if what your doing isn&#8217;t your business, then what are you doing?
</p>
]]></content:encoded>
			<wfw:commentRSS>http://bigmojo.net/monsters/?feed=rss2&amp;p=43</wfw:commentRSS>
		</item>
	</channel>
</rss>
