http://netsperience.org/planet en I Was Mentored in Drupal by "dumbluck" http://netsperience.org/content/blog/i-was-mentored-drupal-dumbluck <p><span style="font-size:14px;">The <a href="http://drupal.org">Drupal community web site</a> has a profile field to list "<span style="font-family: Tahoma, Verdana, sans-serif; font-weight: bold; line-height: 17.9999942779541px; background-color: rgb(254, 254, 254);">My mentors"</span></span></p><div><span style="font-size:14px;">For example, on <a href="https://www.drupal.org/u/decibel.places">my profile</a> I say I was mentored by:</span></div><ul><li><div><span style="font-size:12px;"><strong><a href="https://www.drupal.org/u/robbiethegeek">robbiethegeek</a></strong>&nbsp;- how to appreciate Drupal awesomeness and its limitations</span></div></li><li><div><span style="font-size:12px;"><strong><a href="https://www.drupal.org/user/110386">Alex UA</a></strong>&nbsp;- how to run a business providing Drupal services</span></div></li><li><div><span style="font-size:12px;"><strong><a href="https://www.drupal.org/u/forestmars">forestmars</a></strong>&nbsp;- how to be involved in the Drupal community</span></div></li><li><div><span style="font-size:12px;"><strong><a href="https://www.drupal.org/user/77539">smerrill</a></strong>&nbsp;- how to be an engineer with platform tools like Jenkins, Vagrant, Redis</span></div></li><li><div><span style="font-size:12px;"><strong><a href="https://www.drupal.org/u/snugug">snugug</a></strong>&nbsp;- how to make web sites responsive</span></div></li><li><div><span style="font-size:12px;"><strong><a href="https://www.drupal.org/u/ericduran">ericduran</a></strong>&nbsp;- how to experiment with new doodads like HTML5, Android</span></div></li><li><div><span style="font-size:12px;"><strong><a href="https://www.drupal.org/u/zroger">zroger</a></strong>&nbsp;- how to use Drupal hooks and APIs in code</span></div></li></ul><p><span style="font-size:14px;">I started thinking about my dumb luck picking Drupal as a tool about 9 years ago. I was looking for a Content Management System that made sense.</span></p><p><span style="font-size:14px;">I was awfully interested in a project called <a href="http://www.viewscripts.com/13244/PAWS_-_PHP_AUTOMATIC_WEB_SITE.html">PAWS</a>&nbsp;(PHP Automatic Web Site) -- and it's a good thing I didn't ride that horse, which was long ago put out to pasture.</span></p><p><span style="font-size:14px;">A client asked me to convert his static PHP site so that he could manage the content in the include files without editing code. I built my first Drupal 4.x site, with the crazy hack of creating a node for every include, and then printing the includes/nodes inside a main node (<a href="http://dgo.to/panels">Panels</a>, sort of, which did not exist in Drupal then). I also customized the front end of the TinyMCE wysiwyg editor to add buttons to apply his brand's pink and blue colors. The client smoked a lot of pot, drifted away, came back a year or two later for more work -- without a database. Oh well, not the first - or last - time the db was lost by a client.</span></p><p><span style="font-size:14px;">That experience convinced me that a lot could be done with Drupal that I had not been able to do without a lot of custom coding just to build the base web application. Other projects with early versions of WordPress and Mambo (predecessor to Joomla) left me unimpressed with their extensibility. I have often said since then that "WordPress is like the <em>smaller sibling of Drupal</em>, but Joomla is the <em>evil cousin</em>."</span></p><p><span style="font-size:14px;">Then Earl Miles conjured up his <a href="https://www.drupal.org/user/26979">merlinofchaos</a> wizardry for Sony Music, creating <a href="https://www.drupal.org/project/views">Views</a> and <a href="https://www.drupal.org/project/panels">Panels</a> and <a href="https://www.drupal.org/project/ctools">Ctools</a>, and that was around the time that a lot of developers took notice of Drupal. I was profoundly convinced that Drupal had outgrown being a <em>CMS </em>enabling writers to (more or less) easily edit content without (much) coding<em>,</em> and had become a <em>Content Management <strong>Framework</strong></em> that could perform elegant and dynamic manipulations of the content in its database.</span></p><p><span style="font-size: 14px;">So I had to add <a href="https://www.drupal.org/profile/profile_my_mentors/dumbluck">dumbluck</a> to my mentors - not just for my early experiment hacking the node system, but for each solution that I was able to implement afterwards, because my choice of Drupal provided me with an extensible framework allowing complex algorithms for presentation of content, and the Drupal project improves with every contributor's enhancements.</span></p><h3 style="text-align: center;">I think I'm dumb, maybe just happy</h3><p style="text-align: center;"><iframe allowfullscreen="" frameborder="0" height="281.25" src="http://www.youtube.com/embed/navSGQiJPyI?rel=0&amp;start=21&amp;end=156&amp;autoplay=0" width="500"></iframe></p><p><span style="font-size:12px;">I noticed in preparing this post that some Drupal user profiles are accessible by username, eg. <a href="https://www.drupal.org/u/decibel.places">https://www.drupal.org/u/decibel.places</a> and&nbsp;<a href="https://www.drupal.org/u/robbiethegeek">https://www.drupal.org/u/robbiethegeek</a>, while others, like merlinofchaos and smerrill, are only accessible by their UIDs&nbsp;<a href="https://www.drupal.org/user/26979">https://www.drupal.org/user/26979</a> and&nbsp;<a href="https://www.drupal.org/user/77539">https://www.drupal.org/user/77539</a> respectively.</span></p> http://netsperience.org/content/blog/i-was-mentored-drupal-dumbluck#comments content management framework Ctools Drupal Drupal Planet dumbluck Earl Miles merlinofchaos Panels Views Sun, 29 Jun 2014 02:31:00 +0000 decibel.places 2738 at http://netsperience.org Site Launch: FINclusion Lab Beta http://netsperience.org/content/blog/site-launch-finclusion-lab-beta <h3>We have launched <a href="http://finclusionlab.org">FINclusion Lab Beta</a></h3><h4><span style="font-size:12px;">a new <a href="https://drupal.org/project/drupal">Drupal 7</a> site by&nbsp;<a href="http://themix.org">MIX</a> (Microfinance Information Exchange)</span></h4><p style="text-align: justify; "><span style="font-size:14px;">FINclusion Lab provides visual analytic tools to interpret the "<em>proliferation of data in the field of financial inclusion</em>" by aggregating data in <a href="http://www.tableausoftware.com/">Tableau</a> dashboards and <a href="https://www.mapbox.com/">Mapbox</a> maps. </span></p><p style="text-align: justify; "><span style="font-size:14px;">The platform "<em>provides financial service providers, policy makers, regulators, and other development professionals the opportunity to identify problems and devise solutions for increasing financial inclusion in their countries through interactive data tools and visualizations.</em>"</span></p><p><span style="font-size:14px;"><em>The FINclusion Lab team has worked over the past two years to gather data on supply and demand for financial services at the sub-national level for a growing number of countries in Africa, Asia, and Latin America.</em></span></p><p style="text-align: justify; "><a href="http://finclusionlab.org"><img alt="FINclusion Lab Beta" rel="lightbox" src="http://netsperience.org/sites/default/files/images/FinclusionLab_Transforming-Financial-Inclusion-Data-Into-Insight-500x814.png" style="width: 500px; height: 814px; border-width: 1px; border-style: solid;"></a></p><p><span style="font-size:14px;">We are using the Drupal <a href="https://drupal.org/project/tableau">Tableau module</a>, sponsored by MIX, to display <a href="http://www.tableausoftware.com/">Tableau</a>&nbsp;data visualization dashboards via Drupal Views.</span></p><p><span style="font-size:14px;">Other MIX sites with free and premium data about microfinance:</span></p><p><span style="font-size:14px;"><a href="http://mixmarket.org/">MIX Market</a> and <a href="http://reports.mixmarket.org/">MIX Market Reports</a></span></p><p><span style="font-size:12px;"><em>coming soon</em>: translations in French, Spanish and Russian using the <a href="https://drupal.org/project/i18n">Drupal i18n &nbsp;module&nbsp;</a>for localization.</span></p> beta data visualization Drupal 7 Drupal Planet financial inclusion microfinance Microfinance Information Exchange MIX Tableau web site Fri, 09 May 2014 19:30:56 +0000 decibel.places 2737 at http://netsperience.org Connect Drupal to Multiple Remote Databases via SSH Tunnel http://netsperience.org/content/blog/connect-drupal-multiple-remote-databases-ssh-tunnel <p><span style="font-size:14px;">I'm working on a Drupal application that stores data in separate mysql databases, and syncs some of the data to CouchDB with node.js scripts. </span></p><p><span style="font-size:14px;">The extra mysql dbs are 16+ GB and it's not practical nor necessary to keep them locally since I only want to <em>read</em> the latest data in local development.</span></p><p><span style="font-size:14px;">Wouldn't it be cool if my local development Drupal sites can read from the remote database servers?</span></p><p><span style="font-size:14px;">In some cases you can just use the connection you find in the remote site's settings.php:</span></p><p><span style="font-size:14px;">'otherdb' =&gt; 'mysqli://username:password@hostname/dbname'</span></p><p><em><span style="font-size:14px;">(note: it's a Drupal 6 site so that's why you don't see an array - I will give a Drupal 7 example below)</span></em></p><p><span style="font-size:14px;">However, there's often a twist: I must create a<a href="http://en.wikipedia.org/wiki/Tunneling_protocol#Secure_shell_tunneling"> SSH tunnel</a> to connect to this particular db server.</span></p><p><span style="font-size:14px;">First, you need to <span style="color: rgb(51, 51, 51); font-family: 'Lucida Sans Unicode', 'Lucida Grande', Verdana, Arial, Helvetica, sans-serif; line-height: 17.399999618530273px;">have configured and installed <a href="http://en.wikipedia.org/wiki/Ssh-keygen">SSH keys</a>&nbsp;</span>on your local and remote machines.</span></p><p><span style="font-size:14px;">Then fire up your terminal and create the SSH tunnel to forward the remote mysql port to a local port. This technique is&nbsp;</span><span style="font-size: 14px;">based on information clearly presented by <a href="http://www.revsys.com/writings/quicktips/ssh-tunnel.html">RevSys</a> (quick example) and <a href="http://www.noah.org/wiki/SSH_tunnel">noah.org</a> (more details).</span></p><div><strong><span style="font-family:courier new,courier,monospace;"><span style="font-size:14px;">ssh -L&nbsp;</span></span></strong><strong><span style="font-family: 'courier new', courier, monospace;"><span style="font-size: 14px;">[local port]</span></span></strong><strong><span style="font-family:courier new,courier,monospace;"><span style="font-size:14px;">:[db host]:[remote port]&nbsp;</span></span></strong><strong><span style="font-family:courier new,courier,monospace;"><span style="font-size:14px;">[ssh-username]@[remote host] -N</span></span></strong></div><div>&nbsp;</div><div><span style="font-size:14px;">NOTES: </span></div><ol><li><span style="font-size:14px;">-N tells ssh that you don't want to run a remote command; you only want to forward ports.</span></li><li><span style="font-size:14px;">use a different port for your tunnel&nbsp;</span><strong><span style="font-family: 'courier new', courier, monospace;"><span style="font-size: 14px;">[local port]&nbsp;</span></span></strong><span style="font-size: 14px;">than the one you normally use for mysql; for example, if you connect to mysql locally on the default port 3306, use 3307 (or any other unused port) for your tunnel. You should use the correct&nbsp;</span><strong><span style="font-family: 'courier new', courier, monospace;"><span style="font-size: 14px;">[remote port]</span></span></strong><span style="font-size: 14px;">&nbsp;which is typically 3306, and you can see if it is different by looking at settings.php in the remote site.</span></li><li><strong><span style="font-size: 14px;">Keep this connection alive as long as you need to connect to the remote database.</span></strong></li></ol><div>&nbsp;</div><div><div><strong><span style="font-family: 'courier new', courier, monospace;"><span style="font-size: 14px;">ssh -L 3307:[db host]:3306&nbsp;</span></span></strong><strong><span style="font-family: 'courier new', courier, monospace;"><span style="font-size: 14px;">[ssh-username]@[remote host] -N</span></span></strong></div></div><div>&nbsp;</div><div><span style="font-size:14px;">Then you can test your connection (in a different terminal instance):</span></div><div>&nbsp;</div><div><strong><span style="font-family:courier new,courier,monospace;"><span style="font-size:14px;">mysql -u[dbuser] -p -P 3307 -h 127.0.0.1</span></span></strong></div><div>&nbsp;</div><div><span style="font-size:14px;">Here is the connection in settings.php for Drupal 6:</span></div><div>&nbsp;</div><div><strong><span style="font-size: 14px;">'otherdb' =&gt; 'mysqli://username:password@127.0.0.1:3307/dbname'</span></strong></div><div>&nbsp;</div><div><span style="font-size: 14px;">What's cool is that you can mix <em>local</em> and <em>remote</em> databases. For example, I want to use a local copy of the Drupal database, which is smaller and easier to sync, and read the data from the second (and third, in my case) remote dbs.</span></div><div>&nbsp;</div><div><strong><span style="font-size:14px;">$db_url = array(</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'default' =&gt; 'mysqli://local-dbuser:password@localhost/local-dbname',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp;&nbsp;'otherdb' =&gt; 'mysqli://username:password@127.0.0.1:3307/dbname',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'otherdb2' =&gt; 'mysqli://username:password@127.0.0.1:3307/dbname2'</span></strong></div><div><strong><span style="font-size:14px;">);</span></strong></div><div>&nbsp;</div><div><span style="font-size:14px;">You can also connect Drupal to the default remote database, but it makes sense to use a local instance for development.</span></div><div>&nbsp;</div><div><em><span style="font-size:14px;">And in Drupal 7:</span></em></div><div>&nbsp;</div><div><strong><span style="font-size:14px;">$databases['default']['default'] = array(</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'driver' =&gt; 'mysql',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'database' =&gt; '</span></strong><strong><span style="font-size: 14px;">local-dbname</span></strong><strong><span style="font-size:14px;">',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'username' =&gt; '</span></strong><strong><span style="font-size: 14px;">local-dbuser</span></strong><strong><span style="font-size:14px;">',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'password' =&gt; 'password',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'host' =&gt; 'localhost',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'prefix' =&gt; '',</span></strong></div><div><strong><span style="font-size:14px;">);</span></strong></div><div><strong><span style="font-size:14px;">$databases['otherdb']['default'] = array(</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'driver' =&gt; 'mysql',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'database' =&gt; 'dbname',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'username' =&gt; '</span></strong><strong><span style="font-size: 14px;">username</span></strong><strong><span style="font-size:14px;">',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'password' =&gt; 'password',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'host' =&gt; '127.0.0.1',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'port' =&gt; '3307',</span></strong></div><div><strong><span style="font-size:14px;">&nbsp; 'prefix' =&gt; '',</span></strong></div><div><strong><span style="font-size:14px;">);</span></strong></div><div>&nbsp;</div><div><hr><p><strong><span style="font-size:16px;">WARNING:&nbsp;</span></strong></p></div><div><u><span style="font-size:16px;">If the db user for the remote db has all privileges, your application may alter the remote database.</span></u></div><div>&nbsp;</div><div><em><span style="font-size:16px;">Therefore, you should create a "read-only" user for the remote database which will prevent you from altering it.</span></em></div><div>&nbsp;</div><div><em><span style="font-size:16px;">THINK</span></em></div><div>&nbsp;</div> Drupal Drupal Planet local development mysql ssh tips Mon, 31 Mar 2014 05:42:07 +0000 decibel.places 2735 at http://netsperience.org Drupal 7 Migrate V2 and Addressfield: SOLVED! http://netsperience.org/content/blog/drupal-7-migrate-v2-and-addressfield-solved <p><span style="font-size:14px;">I had to migrate site members from a legacy site with an Oracle db to a relaunch on Drupal 7. Instead of connecting directly to Oracle, I was provided with an Excel dump which I converted to csv. Also the old site does not require members to be authenticated, so I did not have to deal with old passwords.</span></p><p><span style="font-size: 14px;">There are a lot of stale posts in Google results about migrating Addressfield that do not work on the latest Migrate V2 for Drupal 7. For one thing <a href="https://drupal.org/node/1133448">arguments in the field mapping are deprecated.</a></span></p><p><span style="font-size:14px;">Using the <a href="https://drupal.org/project/migrate">Migrate module</a> I was able to create migration classes for the users, and some other information; but I got stuck at importing the address data into the Drupal <a href="https://drupal.org/project/addressfield">Addressfield</a> table, because it uses subfields and requires building an array in Migrate.</span></p><p><span style="font-size: 14px;">I used&nbsp;</span><a href="https://drupal.org/node/1133448" style="font-size: 14px;">colon notation for subfield mapping</a><span style="font-size: 14px;">, but it was not working.</span></p><p><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 0, 187);">&lt;?php<br style="box-sizing: border-box;">&nbsp;&nbsp;&nbsp; $this</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 119, 0);">-&gt;</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 0, 187);">addFieldMapping</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 119, 0);">(</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(221, 0, 0);">'body'</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 119, 0);">, </span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(221, 0, 0);">'body'</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 119, 0);">);<br style="box-sizing: border-box;">&nbsp;&nbsp;&nbsp; </span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 0, 187);">$this</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 119, 0);">-&gt;</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 0, 187);">addFieldMapping</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 119, 0);">(</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(221, 0, 0);">'body:summary'</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 119, 0);">, </span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(221, 0, 0);">'excerpt'</span><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 119, 0);">);</span><br style="box-sizing: border-box;"><span style="box-sizing: border-box; margin: 0px; padding: 0px; border: 0px; font-family: 'Bitstream Vera Sans Mono', Monaco, 'Lucida Console', monospace; line-height: 17.984375px; vertical-align: baseline; white-space: pre-wrap; background-color: rgb(246, 246, 242); color: rgb(0, 0, 187);">?&gt;</span></p><p><span style="font-size: 14px;">Migrate kept throwing an error:&nbsp;</span><em style="font-size: 14px;">Call to a member function import() on a non-object</em></p><p><span style="font-size:14px;">But when I put <a href="http://api.drupalize.me/api/drupal/function/drush_print_r/7">drush_print_r</a> on the line throwing the error, I could see the <a href="http://www.php.net/manual/en/language.types.object.php">stdClass object</a>&nbsp;arrays were there and populated with the correct data.</span></p><p><span style="font-size:14px;">I decided to abandon the Addressfield migrate class and use <a href="https://api.drupal.org/api/drupal/includes%21database%21database.inc/function/db_insert/7">db_insert</a> in an existing class (<em>class SchoolMigration</em>) where I was already running db queries.</span></p><p><span style="font-size: 14px;">It worked, and although I was worried a direct db_insert would not roll back, since I registered the inserts in the process() function for&nbsp;</span><em><span style="font-size: 14px;">class SchoolMigration</span></em><span style="font-size: 14px;">, they also rolled back.</span></p><p><p><a href="http://netsperience.org/content/blog/drupal-7-migrate-v2-and-addressfield-solved" target="_blank">read more</a></p> http://netsperience.org/content/blog/drupal-7-migrate-v2-and-addressfield-solved#comments Addressfield Drupal Drupal 7 Drupal Planet Migrate Wed, 29 Jan 2014 19:57:49 +0000 decibel.places 2733 at http://netsperience.org Building a Video Playlist for JW Player 6 with Drupal 7 Views http://netsperience.org/content/blog/building-video-playlist-jw-player-6-drupal-7-views <p><span style="font-size:14px;">I took over a Drupal 7 project building a web application for college students to upload original videos about their school, and for schools to manage, group, and share the videos.</span></p><p><span style="font-size:14px;">It's a startup privately funded by the principal, and we are literally working on a shoestring. My previous experience with media in Drupal led the principal to contact me via <a href="http://www.linkedin.com/in/rgoya/">LinkedIn</a>.</span></p><p><span style="font-size:14px;">When it came time to build a video playlist in <a href="http://drupal.org/project/views">Drupal Views</a> for <a href="http://www.jwplayer.com/">JW Player</a>&nbsp;version="6.7.4071"&nbsp;(formerly known as Longtail Video), I found very little useful documentation. In fact, someone suggested that<em> those who know how are not interested in sharing their knowlege</em>. -- but not me&nbsp;<img alt="smiley" height="20" rel="lightbox" src="http://netsperience.org/sites/all/libraries/ckeditor/plugins/smiley/images/regular_smile.gif" title="smiley" width="20"></span></p><p><span style="font-size:14px;">There are a <a href="http://youtu.be/ut1yX-Go2Mc">couple of videos on YouTube</a> by&nbsp;<a href="https://drupal.org/user/24286">Bryan Ollendyke</a> for Drupal 6. But a lot has changed in Drupal since then.</span></p><h3>The Goal:</h3><p><span style="font-size:14px;">Back to the playlist: Site admins can mark a video featured by ticking a checkbox on the custom video content type. Now I want to display those <em>featured</em> videos as a playlist.</span></p><p>&nbsp;</p><p><span style="font-size:14px;">JW Player provides clear documentation about how to <a href="http://www.longtailvideo.com/support/jw-player/28839/embedding-the-player">embed the player</a>, and how to construct and load the <a href="http://www.longtailvideo.com/support/jw-player/28842/working-with-playlists/">playlist</a>&nbsp;via a <a href="http://www.longtailvideo.com/support/jw-player/28843/loading-rss-feeds">RSS feed</a>.</span></p><p><strong><span style="font-size:14px;">The structure of the RSS file:</span></strong></p> <pre style="margin-top: 10px; margin-bottom: 20px; padding: 10px; border: 0px; outline: 0px; font-size: 11px; vertical-align: baseline; background-color: rgb(2, 35, 54); line-height: 1.5em; font-family: 'Lucida Console', Monaco, 'Courier New', Courier, monospace; border-top-left-radius: 5px; border-top-right-radius: 5px; border-bottom-right-radius: 5px; border-bottom-left-radius: 5px; color: rgb(114, 203, 255); white-space: pre-wrap; word-wrap: break-word;">&lt;rss version="2.0" xmlns:jwplayer="http://rss.jwpcdn.com/"&gt; &lt;channel&gt; &lt;item&gt; &lt;title&gt;Sintel Trailer&lt;/title&gt; &lt;description&gt;Sintel is a fantasy CGI from the Blender Open Movie Project.&lt;/description&gt; &lt;jwplayer:image&gt;/assets/sintel.jpg&lt;/jwplayer:image&gt; &lt;jwplayer:source file="/assets/sintel.mp4" /&gt; &lt;/item&gt; &lt;/channel&gt; &lt;/rss&gt;</pre> <p><span style="font-size:14px;">There are various threads on drupal.org discussing video playlists for JW Player. None of them were particularly useful for me.</span></p><p><p><a href="http://netsperience.org/content/blog/building-video-playlist-jw-player-6-drupal-7-views" target="_blank">read more</a></p> http://netsperience.org/content/blog/building-video-playlist-jw-player-6-drupal-7-views#comments Drupal Drupal Planet how to JW Player mobile playlist RSS video Views xml Thu, 02 Jan 2014 01:31:27 +0000 decibel.places 2732 at http://netsperience.org Accessing Pantheon via Google Public DNS on Ubuntu in VirtualBox for Local Drupal Development http://netsperience.org/content/blog/accessing-pantheon-google-public-dns-ubuntu-virtualbox-local-drupal-development <p><span style="font-size:14px;">I am working on a Drupal project for the Columbia University Office of Alumni Affairs and Development, and I was unable to connect to the <a href="https://www.getpantheon.com/">Pantheon</a> servers from the Ubuntu command line from home.</span></p><p><span style="font-size:14px;">I have <a href="http://www.ubuntu.com/">Ubuntu Linux</a> installed in an <a href="https://www.virtualbox.org/">Oracle VirtualBox</a>, because the laptop provided by Columbia is pretty locked down and I don't have admin rights, but they installed VirtualBox so I could add an Ubuntu machine and configure it as needed.</span></p><p><span style="font-size:14px;">It worked fine while I was on site, but now that I am working remotely I could not connect.</span></p><p><span style="font-size:14px;">Pantheon support suggested that my ISP is unable to connect to their IPs in DNS, and I might be able to connect using <a href="https://developers.google.com/speed/public-dns/">Google Public DNS</a>:</span></p><p style="margin-left: 40px;"><em><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">There are two steps in debugging the problem you are experiencing.</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">1. Check to see if you are getting an I.P. address returned when you run the following command, replacing “&lt;xxx&gt;” with your site’s UUID:</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">dig appserver.dev.&lt;xxx&gt;.drush.in</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">(ex.:dig appserver.dev.38fde024-2874-4cce-b02a-072686c4ded9.drush.in)</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">If there is no I.P. in the output then the ISP on the network you are currently on is failing to recognize the hostname of the database.</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">2. For some users that may fail so the next step is to test this command with name server, in this case Google’s 8.8.8.8 I.P address:</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">dig @8.8.8.8 appserver.dev.&lt;xxx&gt;.drush.in</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">(ex:dig @8.8.8.8 appserver.dev.38fde024-2874-4cce-b02a-072686c4ded9.drush.in)</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><span style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;">If that returns an I.P. address, this means that using Google’s DNS you were able to resolve the hostname. To resolve the issue you can set your DNS to use Google’s service and you should be able to connect:</span><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><br style="color: rgb(0, 0, 0); font-family: monospace; font-size: 13px;"><a href="https://developers.google.com/speed/public-dns/" id="yui_3_13_0_1_1384708566566_3835" style="margin: 0px; padding: 0px; color: rgb(25, 106, 212); outline: none; font-family: monospace; font-size: 13px;" target="_blank">https://developers.google.com/speed/public-dns/</a></em></p><p><span style="font-size:14px;">It works fine, but the directions for a VirtualBox instance are a little different than what <a href="https://developers.google.com/speed/public-dns/docs/using">Google has posted in the instuctions for Ubuntu</a>:</span></p><div><span style="font-size:14px;">Ubuntu in the VirtualBox is using its eth0 wired connection to the host OS to piggyback on the Windows wireless network adapter.</span></div><div>&nbsp;</div><div><span style="font-size:14px;">I had to configure the Ubuntu wired connection (there is no wireless connection defined). The rest of the guide is applicable, and I changed Method: "Automatic (DHCP)" to "Automatic (DHCP) addresses only"</span></div><div>&nbsp;</div><div><a href="https://developers.google.com/speed/public-dns/"><img alt="configuring Google public dns for Ubuntu in VirtualBox" rel="lightbox" src="http://netsperience.org/sites/default/files/images/google_dns_ubuntu_virtualbox.png" style="width: 500px; height: 517px;" title="configuring Google public dns for Ubuntu in VirtualBox"></a></div> http://netsperience.org/content/blog/accessing-pantheon-google-public-dns-ubuntu-virtualbox-local-drupal-development#comments Columbia University dns Drupal Planet google public dns pantheon Ubuntu virtualbox Sun, 17 Nov 2013 18:53:07 +0000 decibel.places 2731 at http://netsperience.org Coney Island Mermaid Parade is June 22 - and it has a Drupal site! http://netsperience.org/content/blog/coney-island-mermaid-parade-june-22-and-it-has-drupal-site <h3>The 2013 Coney Island Mermaid Parade is on Saturday June 22</h3><p><a href="http://www.coneyisland.com/programs/mermaid-parade"><img alt="" rel="lightbox" src="http://www.netsperience.org/sites/default/files/images/mermaidparade-pose.jpg" style="width: 500px; height: 386px; border-width: 0px; border-style: solid;" title="click to visit the parade (Drupal) web site"></a></p><p><span style="font-size:14px;">This year's King Neptune&nbsp;<a href="http://judahfriedlander.com/" target="_blank">Judah Friedlander</a>&nbsp; Queen Mermaid&nbsp;<a href="http://www.caroleradziwill.com/" target="_blank">Carole Radziwill!</a></span></p><p><span style="font-size:14px;">Parade Web site:&nbsp;<a href="http://www.coneyisland.com/programs/mermaid-parade">http://www.coneyisland.com/programs/mermaid-parade</a></span></p><p><span style="font-size:16px;">And it's a <a href="http://drupal.org"><em><strong>Drupal</strong></em></a> web site!!!!&nbsp;</span><img alt="cool" height="20" rel="lightbox" src="http://netsperience.org/sites/all/libraries/ckeditor/plugins/smiley/images/shades_smile.gif" title="cool" width="20"></p><p><a href="http://www.coneyisland.com/programs/mermaid-parade"><img alt="mermaid parade poster 2013" rel="lightbox" src="http://www.netsperience.org/sites/default/files/images/mermaidparade2013kozik.jpg" style="width: 500px; height: 772px;"></a></p><p><span style="font-size:14px;">My photo gallery from the 2009 parade:&nbsp;<a href="http://netsperience.org/category/image-galleries/coney-island-mermaid-parade">http://netsperience.org/category/image-galleries/coney-island-mermaid-parade</a></span></p><p><a href="http://netsperience.org/category/image-galleries/coney-island-mermaid-parade"><img alt="" rel="lightbox" src="http://netsperience.org/sites/default/files/Coney_Island_Mermaid_Parade_2009_-_Beach/IMG_0592.JPG" style="width: 480px; height: 640px; border-width: 0px; border-style: solid;" title="see my photo gallery from the 2009 parade"></a></p> Drupal mermaid parade Fri, 21 Jun 2013 18:14:58 +0000 decibel.places 2728 at http://netsperience.org Cinco de Mayo, Dries Buytaert in a sombrero etc. http://netsperience.org/content/blog/cinco-de-mayo-dries-buytaert-a-sombrero-etc <h3><span style="font-size: small;">As a 1/4 Mexican, I feel gifted with a birthday on </span><a href="http://en.wikipedia.org/wiki/Cinco_de_Mayo" style="font-size: 12px;"><span style="font-size: small;">Cinco de Mayo</span></a></h3><p><span style="font-size: small;">(for you gringos, that's May 5th)</span></p><p><span style="font-size: small;">Even better to share a photo of <a href="http://drupal.org">Drupal</a> creator and curator <a href="http://buytaert.net">Dries Buytaert</a> in a sombrero (while a student at <a href="http://en.wikipedia.org/wiki/University_of_Ghent">Ghent University</a>, where Drupal originated)</span></p><p><img alt="Dries Buytaert in a sombrero" rel="lightbox" src="http://www.netsperience.org/sites/default/files/images/DriesSombero.png" style="border-width: 0px; border-style: solid; width: 500px; height: 400px;"></p><p><span style="font-size: small;">photo via </span><span style="font-size: small;"><a href="http://groups.drupal.org/user/13263">Forest Mars</a></span></p><h2><span style="font-size:14px;">Try my vegetarian recipes:</span></h2><h3><span style="font-size:14px;"><a href="http://netsperience.org/content/happy-lunar-new-year-with-burritos"><span style="font-family: Arial, Verdana, 'Trebuchet MS'; line-height: 17px; color: rgb(255, 0, 0);">Bean burritos</span><span style="color: rgb(51, 51, 102); font-family: Arial, Verdana, 'Trebuchet MS'; line-height: 17px;">&nbsp;y&nbsp;</span><span style="font-family: Arial, Verdana, 'Trebuchet MS'; line-height: 17px; color: rgb(255, 102, 0);">arroz con frijoles</span></a></span></h3><h3 style="margin-top: 0px; margin-bottom: 0.5em; color: rgb(0, 0, 0); font-size: 18px; font-family: Arial, Verdana, 'Trebuchet MS';"><span style="font-size:14px;"><a href="http://netsperience.org/content/blog/pro-bowl-guacamole" style="text-decoration: none; color: rgb(0, 102, 153);" title="Pro Bowl Guacamole"><span style="color: rgb(0, 128, 0);">Pro Bowl Guacamole</span></a></span></h3><h3><span style="font-size:10px;">This remains the 10th most popular post on my blog, up from 8709 views a year ago to 15,037 now</span></h3><!--<p><em><strong>Unfortunately I will not be at the 5/5 Drupal meetup hosted by Zivtech, my friends are throwing a surprise party and I am obliged in advance to be there</strong></em></p><p><span style="color: rgb(128, 0, 128);"><span style="font-size: medium;"><em>some birthday greetings</em></span></span></p><p><a href="https://www.xing.com/profile/Decibel_Places"><img alt="Happy Birthday DECIBEL from Xing" rel="lightbox" src="http://www.netsperience.org/sites/default/files/images/Xing-HB-DECIBEL.jpg" height="224" width="256" border="0"></a></p><p><img alt="feliz aniversario from Mom" rel="lightbox" src="http://www.netsperience.org/sites/default/files/images/feliz-aniversario.jpg" height="247" width="500"></p>--> http://netsperience.org/content/blog/cinco-de-mayo-dries-buytaert-a-sombrero-etc#comments birthday Cinco de Mayo Dries Buytaert Drupal Drupal Planet sombrero Fri, 03 May 2013 19:18:05 +0000 decibel.places 1306 at http://netsperience.org SOPA Pirates Drupal Module for Internet Freedom Day http://netsperience.org/content/blog/test-sopa-pirates-drupal-module <h4>In honor of <a href="http://www.internetfreedomday.net/">Internet Freedom Day</a>&nbsp;I'm Bumping This Post || RIP Aaron Swartz</h4><p>Help spread the word by joining this Thunderclap: <a href="https://www.thunderclap.it/projects/1039-internet-freedom-day" title="https://www.thunderclap.it/projects/1039-internet-freedom-day">https://www.thunderclap.it/projects/1039-internet-freedom-day</a></p><h3>What Is SOPA? Get me spyglass, I'll warrant ye!</h3><div>&nbsp;</div><div><em>(original text Pirated from <a href="http://gizmodo.com/5877000/what-is-sopa">Gizmodo.com</a>)</em><br><br><span style="font-size:14px;">If you hadn't heard of SOPA before, you probably have by now: Some of the internet's most influential sites—Reddit and Wikipedia among them—are going dark to protest the much-maligned anti-piracy bill. But other than being a very bad thing, what is SOPA? And what will it mean for you if it passes?<br>SOPA is an anti-piracy bill working its way through Congress...<br><br>House Judiciary Committee Chair and Texas Republican Lamar Smith, along with 12 co-sponsors, introduced the Stop Online Piracy Act on October 26th of last year. Debate on H.R. 3261, as it's formally known, has consisted of one hearing on November 16th and a "mark-up period" on December 15th, which was designed to make the bill more agreeable to both parties. Its counterpart in the Senate is the Protect IP Act (S. 968). Also known by its cuter-but-still-deadly name: PIPA. There will likely be a vote on PIPA next Wednesday; SOPA discussions had been placed on hold but will resume in February of this year.<br>...that would grant content creators extraordinary power over the internet...<br><br>The beating heart of SOPA is the ability of intellectual property owners (read: movie studios and record labels) to effectively pull the plug on foreign sites against whom they have a copyright claim. If Warner Bros., for example, says that a site in Italy is torrenting a copy of The Dark Knight, the studio could demand that Google remove that site from its search results, that PayPal no longer accept payments to or from that site, that ad services pull all ads and finances from it, and—most dangerously—that the site's ISP prevent people from even going there.<br>...which would go almost comedically unchecked...<br><br>Perhaps the most galling thing about SOPA in its original construction is that it let IP owners take these actions without a single court appearance or judicial sign-off. All it required was a single letter claiming a "good faith belief" that the target site has infringed on its content. Once Google or PayPal or whoever received the quarantine notice, they would have five days to either abide or to challenge the claim in court. Rights holders still have the power to request that kind of blockade, but in the most recent version of the bill the five day window has softened, and companies now would need the court's permission.</span></div> http://netsperience.org/content/blog/test-sopa-pirates-drupal-module#comments 99% Drupal Planet Internet Freedom Day Modules PIPA pirate SOPA translate Fri, 18 Jan 2013 13:42:45 +0000 decibel.places 2670 at http://netsperience.org Twitter API Changes Again, Patch for Drupal 6.x Twitter Module http://netsperience.org/content/blog/twitter-api-changes-again-patch-drupal-6x-twitter-module <p><span style="font-size:14px;">When I was<em> unable to post to Twitter from my blog tonight</em>, I found a <a href="http://drupal.org/node/1809648">very new thread on drupal.org</a> discussing the issue: <strong>the Twitter API changed again!</strong></span></p><p><span style="font-size:14px;">I am only using the Twitter module on Drupal 6 sites right n<span id="cke_bm_309S" style="display: none;">&nbsp;</span><span id="cke_bm_308S" style="display: none;">&nbsp;</span><span id="cke_bm_307S" style="display: none;">&nbsp;</span>ow, I took two of the fixes and combined them in a patch for the 6.x-3.0-beta9 version. Then <a href="http://drupal.org/user/72333">MinhH</a> submitted new code that only requires a change in one place. </span></p><p><span style="font-size:14px;"><a href="http://drupal.org/node/1809648#comment-6601576">here's my latest patch</a> for the 6.x-3.0-beta9 version</span></p><p><span style="font-size:14px;">since the Twitter API is constantly changing, and the module is not very stable, <em>always read the thread carefully to make sure you are applying the latest patch</em>! Others have cleaned up the code I added from MinhH, and created a patch for the 6.x-3.x-dev branch which makes sense (however I suspect that </span><span style="font-size:14px;">6.x-3.0-beta9 may be ahead of the -dev branch, and it's not a branch provided in the project's Github).</span><span style="font-size:14px;"> Anyway, Open Source <u>rocks</u>, <em>Murray</em>!</span></p><p><span style="font-size:14px;">and because my Twitter RSS feed URL was also broken, I found this post</span></p><p><span style="font-size:14px;"><a href="https://dev.twitter.com/discussions/844" rel="nofollow" title="https://dev.twitter.com/discussions/844">https://dev.twitter.com/discussions/844</a></span></p><p><span style="font-size:14px;">which provides an update to the URL format</span>:</p><p><a href="https://api.twitter.com/1/statuses/user_timeline.rss?screen_name=decibelplaces"><span style="font-size:14px;">https://api.twitter.com/1/statuses/user_timeline.rss?screen_name=decibelplaces</span></a></p> http://netsperience.org/content/blog/twitter-api-changes-again-patch-drupal-6x-twitter-module#comments API Drupal Github module open source patch Twitter Sun, 14 Oct 2012 06:03:15 +0000 decibel.places 2720 at http://netsperience.org