singingfish's Journal http://use.perl.org/~singingfish/journal/ singingfish's use Perl Journal en-us use Perl; is Copyright 1998-2006, Chris Nandor. Stories, comments, journals, and other submissions posted on use Perl; are Copyright their respective owners. 2012-01-25T02:31:45+00:00 pudge pudge@perl.org Technology hourly 1 1970-01-01T00:00+00:00 singingfish's Journal http://use.perl.org/images/topics/useperl.gif http://use.perl.org/~singingfish/journal/ Marketing rumbling in the perl community. http://use.perl.org/~singingfish/journal/39363?from=rss To all you people making rumblings about marketing effort in the Perl community (I know who you are). I have a <a href="http://www.perlfoundation.org/kieren_diment_the_perl_survey">Perl Foundation grant outstanding</a> that I intend to complete by the end of this year. <p> Anyway, I'm keeping an eye on the discussion, archiving it, and will be responsive to feedback. At some point in the not too distant future (probably late August, maybe sooner) I will rustle up a focus group on IRC so that I can attempt to work where to go with some of the more subjective bits of the survey I end up running.</p> singingfish 2009-07-28T11:04:31+00:00 perlfoundation Perl Survey Progress http://use.perl.org/~singingfish/journal/39283?from=rss <p> I haven't committed much to the <a href="http://github.com/singingfish/perl-survey-2009/tree/master">github repository</a> for this project since my last update, because a lot of what I've been doing is fairly exploratory stuff. Essentially I've been through the <a href="http://github.com/singingfish/perl-survey-2009/blob/3449fac299e2224e2ca7d78dd4f510aba5da7433/PerlSurvey2007A4.pdf">original report</a> with a view to replicating the findings of the original survey, and trying to segment out some more interesting analyses. </p><p> Unfortunately this has proven to be a pain. I could sit down and mung the data some more, but I don't think that would be a good use of my time. It's much better to thoroughly ensure that the next set of collected data is clean and easy to use from the word go. </p><p>Don't get me wrong, there's a lot of useful stuff here, but there's a lot of detailed unpicking of the data structure to do to ensure consistency for cross-tabulation and other analysis. Unfortunately I don't think the benefits of doing this would exceed the costs, particularly because the 2007 dataset is getting a bit old now. However, I can still use the 2007 data to ensure a properly structured 2009 survey that's structured in a way that is easily sliced and diced. </p><p> So my next steps are as follows: </p><ul> <li>Organise DNS and hosting for survey.perl.org</li><li>Consolidate and publish my notes on what I found out playing with the data and presentation of the original survey report</li></ul><p> When this is done I can start drafting new questions, and rigging up the basics of the web application for collecting the data. Provisionally we'll try to get this happening for late autumn in the Northern Hemisphere, when everyone is back home from the beach.</p> singingfish 2009-07-13T11:20:42+00:00 journal Return to the Perl Survey http://use.perl.org/~singingfish/journal/39187?from=rss <p>Back in January, I started doing work on the Perl Foundation grant <a href="http://www.perlfoundation.org/kieren_diment_the_perl_survey">for the perl survey</a>. I'd gathered all the data together, and done a fairly sizable job of cleaning it up, when along came a new job and a horrendous set of deadlines for the now imminent <a href="http://www.apress.com/book/view/1430223650">Catalyst book</a>. Meanwhile I was waiting for Skud to give me the original <a href="http://github.com/singingfish/perl-survey-2009/blob/3449fac299e2224e2ca7d78dd4f510aba5da7433/PerlSurvey2007A4.pdf">Perl Survey 2007 report</a> which had fallen off the net. </p><p>So for now, I'm going to go through the survey report fairly slowly, <a href="http://github.com/singingfish/perl-survey-2009/blob/3449fac299e2224e2ca7d78dd4f510aba5da7433/R/01-gender.R">replicating</a> the previously presented analysis in <a href="http://www.r-project.org/">R</a> code and <a href="http://github.com/singingfish/perl-survey-2009/blob/3449fac299e2224e2ca7d78dd4f510aba5da7433/R/02-age.R">writing notes</a> about what extra things can be done with the extant data. Once this is done, I'll look at things that can be dropped from the old survey, and think about enhancing the next iteration of the survey with more questions.</p> singingfish 2009-06-29T12:51:25+00:00 journal Perl Survey 2009 http://use.perl.org/~singingfish/journal/38244?from=rss I've finally started working on the Perl Survey grant. The first thing I've done is taken <a href="http://search.cpan.org/dist/Data-PerlSurvey2007/PerlSurvey2007.pm">Data::PerlSurvey2007</a> and merged it with the work that I did in late November 2007. Generally the best practice with survey data is to make the data file as two dimensional as possible. So to achieve this, I'm converting the nested data structures in the PerlSurvey2007 module into <a href="http://en.wikipedia.org/wiki/Dummy_variable">dummy variables</a>. This, and another couple of tweaks should get me to the position where I can do a comprehensive review of the existing analysis. For those of you who want to sing along at home, I'm hosting it on Github, and you can browse or grab it from <a href="http://github.com/singingfish/perl-survey-2009/tree/master">here</a>. singingfish 2009-01-08T23:17:16+00:00 newsnews Catalyst::Controller::reCAPTCHA http://use.perl.org/~singingfish/journal/34534?from=rss Just a quick note to let you all know that I made a <a href="http://catalystframework.org/">Catalyst</a> extension to interact with the <a href="http://recaptcha.net/">reCAPTCHA</a> service. <p>It's <a href="http://search.cpan.org/author/ZARQUON/Catalyst-Controller-reCAPTCHA-0.2/lib/Catalyst/Controller/reCAPTCHA.pm">Catalyst::Controller::reCAPTCHA</a> on cpan and comes with documentation and a simple example application. If anyone wants to add patches for <a href="http://search.cpan.org/author/ANDYA/Captcha-reCAPTCHA-v0.7/lib/Captcha/reCAPTCHA/Mailhide.pm">Captcha::reCAPTCHA::Mailhide</a> api, feel free<nobr> <wbr></nobr>:-) </p><p>By the way, watch out for testing this on your dev box - I got myself banned from reCaptcha for several hours by posting continually failing recaptchas.</p> singingfish 2007-09-24T22:22:05+00:00 journal WIAB hits version 0.02 http://use.perl.org/~singingfish/journal/34472?from=rss WIAB - Website in a box, my simple <a href="http://catalystframework.org/">Catalyst</a> CMS has hit version 0.02. The main change here is that we're using some <a href="http://jquery.com/">Jquery</a> code to make editing pages easier. The plugin in question is <a href="http://www.jaysalvat.com/jquery/jtageditor/">JTagEditor</a>. You can download the new version from <a href="http://code.google.com/p/websiteinabox/">here</a>. singingfish 2007-09-17T04:40:46+00:00 modules Catalyst Javascript Testbed http://use.perl.org/~singingfish/journal/33398?from=rss Quick way to get a javascript testbed going:<br><br>$ catalyst.pl MyApp<br>$ cd MyApp<br><br># put this in MyApp::Controller::Root<br><br>sub default : Path {<br> &nbsp; &nbsp; &nbsp; &nbsp; my ( $self, $c, $arg ) = @_;<br><br> &nbsp; &nbsp; &nbsp; &nbsp; unless ($arg =~<nobr> <wbr></nobr>/boo|hoo|snoo/) {<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $c-&gt;res-&gt;status('404');<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $c-&gt;res-&gt;body('404 not found');<br> &nbsp; &nbsp; &nbsp; &nbsp; }<br> &nbsp; &nbsp; &nbsp; &nbsp; else {<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $c-&gt;config-&gt;{$arg}++;<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $c-&gt;res-&gt;header('Content-Type', 'text/plain');<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $c-&gt;res-&gt;body($c-&gt;config-&gt;{$arg});<br> &nbsp; &nbsp; &nbsp; &nbsp; }<br>}<br><br>sub index : Private {<br> &nbsp; &nbsp; &nbsp; &nbsp; my ($self, $c) = @_;<br> &nbsp; &nbsp; &nbsp; &nbsp; $c-&gt;res-&gt;redirect($c-&gt;uri_for('/static/index.htm'));<br>}<br><br># download your js libraries of choice (jquery here) to root/static/js (create dir as nescessary)<br># And in<nobr> <wbr></nobr>/static/index.htm &lt;-- NOTE the lack of 'l' at the end - there is a reason for this!<br><br>&lt;html&gt;&lt;head&gt;&lt;/head&gt;&lt;body&gt;<br>&lt;script src="/static/js/jquery-1.1.2.pack.js"&gt;&lt;/script&gt;<br>&lt;script type="text/javascript"&gt;<br> &nbsp; &nbsp; jq = jQuery.noConflict();<nobr> <wbr></nobr>// your stuff here<nobr> <wbr></nobr>:-)<br>&lt;script&gt;<br># your html here pre-written or inserted with js debugger<br>&lt;/body&gt;&lt;/html&gt;<br><br>Woosh, off we go... singingfish 2007-06-01T11:36:00+00:00 journal WIAB templates http://use.perl.org/~singingfish/journal/33210?from=rss I'm uncrufting <a href="http://code.google.com/p/websiteinabox/">WIAB's</a> templates based on the <a href="http://alistapart.com/d/multicolumnlayouts/3ColLiquidWithContent.html">list apart three column layout</a>. I've removed a column and glued on a simple css layer for the breadcrumbs to present a tab like interface. Once I've styled the left menu, and the footer, I can think about providing drop down menus. Then I make the colour scheme sane and we have a new release! singingfish 2007-05-07T12:56:25+00:00 journal Javascript n00b part 1 http://use.perl.org/~singingfish/journal/33085?from=rss <p>Unfortunately, javascript is a pain, but <a href="http://dojotoolkit.org/"> getting</a> <a href="http://extjs.com/">better</a>. Unfortunately there seem to be a few good books out there, and none of them in my local library. Time to create my own resource for learning javascript! WTFM indeed. So following the advice of <a href="http://chainsawblues.vox.com/">people who know</a>, I downloaded the <a href="http://devedge-temp.mozilla.org/library/manuals/2000/javascript/1.5/guide/CoreGuideJS15.zip">Core Javascript Guide</a>. To give myself an interactive environment for learning Javascript I downloaded <a href="http://www.getfirebug.com/">Firebug</a> and off we go. </p><p>First up is the chapter on variables. Open up the Firebug inspector (a green tick in the lower rhs of my browser here) and declare a string in the interaction line (right at the bottom of the window with three blue angle brackets (&gt;&gt;&gt;) like so:</p><p> <code> a = "Hi"; </code> </p><p>Then: <code> window.alert(a); </code> </p><p>There we go, scalar variable naming and browser interactivity all in one go. Next up the rest of the chapter.</p><p> <small>BTW while this isn't directly relevant to <a href="http://catalyst.perl.org/">Catalyst</a>, people do pop up on IRC asking for the "best javascript book" and the approach above seems a reasonable substitute.</small> </p><p> <b>Update:</b> I found the little gray V at the far right hand side of the firebug eval area in firebug. Turns out you can eval blocks of code too<nobr> <wbr></nobr>:)<nobr> <wbr></nobr>:</p><p> <code> a = 'foo'; b= 'bar'; if (a == 'foo' &amp;&amp; b != 'bar') { window.alert(a)} else { window.alert(b) } </code> </p><p> <b>Update: </b> (again). A <a href="http://perlitist.com/">little birdie</a> tells me that I should declare my variables with <code>var a = 'Hi'</code>. Something to do with scoping issues. I guess once I understand how to do data structures in javascript I'll be working out scope and how to do something "use strict" like.</p> singingfish 2007-04-24T04:49:34+00:00 journal WIAB Updates http://use.perl.org/~singingfish/journal/32816?from=rss I've been poking <a href="http://code.google.com/p/websiteinabox/">Website in a box</a> a little since it's public release. I added reasonable documentation for deployment administration and editing. I also updated the TODO realising I forgot to do that before. Here it is in aproximate order at subversion revision 103: <ol> <li>Clean templates add styled to forms and release non js stable version</li><li>Wysywig dojo editor</li><li>Par deployment</li><li>Orderable menus (javascript only)</li><li>Internal links and image addresses via textile/dojo plugin</li><li>Make images slightly easier to deal with.</li><li>Provide image upload area (with auto-resize?)</li><li>Sensible cacheing (pref a static file cache so pages only need to be generated once).</li><li>Remove remaining warnings (also ongoing)</li></ol><p>Along the way to getting <a href="http://dojotoolkit.org/">Dojo</a> into WIAB, I found an "interesting" interaction bug between Template::Plugin::CGI and the built in Catalyst test server... Must report that problem. Something to do with CGI expecting stuff from STDIN at inappropriate times. </p><p>Naturally if I have any volunteers for any of the above jobs<nobr> <wbr></nobr>... </p> singingfish 2007-03-28T07:33:54+00:00 journal Website in a Box http://use.perl.org/~singingfish/journal/32757?from=rss <p>Website in a box is a <a href="http://catalystframework.org/">Catalyst</a> based content management system for individuals and small groups. It's got <a href="http://code.google.com/p/websiteinabox/">Google Code</a> project space and a reasonably comprehensive test suite. It does some "Search Engine Optimisation" for you and has been built to be easy to hack on. </p><p>It's also a nice application to look at if you want to learn Catalyst.</p> singingfish 2007-03-20T23:33:06+00:00 useperl