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

<channel>
	<title>GadgetNate</title>
	<atom:link href="http://www.gadgetnate.com/feed" rel="self" type="application/rss+xml" />
	<link>http://www.gadgetnate.com</link>
	<description></description>
	<pubDate>Sun, 10 Aug 2008 02:55:07 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
	<language>en</language>
			<item>
		<title>The cognitive surplus</title>
		<link>http://www.gadgetnate.com/2008/08/09/the-cognitive-surplus</link>
		<comments>http://www.gadgetnate.com/2008/08/09/the-cognitive-surplus#comments</comments>
		<pubDate>Sun, 10 Aug 2008 02:55:07 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/?p=1048</guid>
		<description><![CDATA[My brother-in-law is in town and I showed him the following video that I had seen some months back.  It is a very, very good talk.
 
Here is a transcript of most of the talk:
Gin, Television, and Social Surplus
And the author Clay Shirky has written a book called &#8220;Here Comes Everybody&#8221; which I am [...]]]></description>
			<content:encoded><![CDATA[<p>My brother-in-law is in town and I showed him the following video that I had seen some months back.  It is a very, very good talk.</p>
<p><embed src="http://blip.tv/play/AbTSFIa8DQ" type="application/x-shockwave-flash" width="320" height="242" allowscriptaccess="always" allowfullscreen="true"></embed> </p>
<p>Here is a transcript of most of the talk:<br />
<a href="http://www.shirky.com/herecomeseverybody/2008/04/looking-for-the-mouse.html">Gin, Television, and Social Surplus</a></p>
<p>And the author Clay Shirky has written a book called &#8220;Here Comes Everybody&#8221; which I am reading on my Amazon Kindle.</p>
<p><iframe src="http://rcm.amazon.com/e/cm?t=gadgetnate-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=B000FI73MA&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p><iframe src="http://rcm.amazon.com/e/cm?t=gadgetnate-20&#038;o=1&#038;p=8&#038;l=as1&#038;asins=1594201536&#038;fc1=000000&#038;IS2=1&#038;lt1=_blank&#038;m=amazon&#038;lc1=0000FF&#038;bc1=000000&#038;bg1=FFFFFF&#038;f=ifr" style="width:120px;height:240px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/08/09/the-cognitive-surplus/feed</wfw:commentRss>
		</item>
		<item>
		<title>Script Editor - Basic Version deployed to the server</title>
		<link>http://www.gadgetnate.com/2008/08/04/script-editor-basic-version-deployed-to-the-server</link>
		<comments>http://www.gadgetnate.com/2008/08/04/script-editor-basic-version-deployed-to-the-server#comments</comments>
		<pubDate>Tue, 05 Aug 2008 01:16:57 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/2008/08/04/script-editor-basic-version-deployed-to-the-server</guid>
		<description><![CDATA[I cleaned up the look at little.&#160; Here are some screen shots to give you an idea of what it looks like:
Login Screen:
 
Welcome Screen:
 
New Script Page:
&#160;
 
&#160;
Script List page:
&#160;
 
 Script view page:
 
 You can click the pencil icon to edit a line, click the up and down arrows to move the [...]]]></description>
			<content:encoded><![CDATA[<p>I cleaned up the look at little.&nbsp; Here are some screen shots to give you an idea of what it looks like:</p>
<p>Login Screen:</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image8.png"><img height="244" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb8.png" width="345" border="0"></a> </p>
<p>Welcome Screen:</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image9.png"><img height="264" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb9.png" width="400" border="0"></a> </p>
<p>New Script Page:</p>
<p>&nbsp;</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image10.png"><img height="380" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb10.png" width="640" border="0"></a> </p>
<p>&nbsp;</p>
<p>Script List page:</p>
<p>&nbsp;</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image11.png"><img height="480" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb11.png" width="596" border="0"></a> </p>
<p> Script view page:</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image12.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="484" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb12.png" width="638" border="0"></a> </p>
<p> You can click the pencil icon to edit a line, click the up and down arrows to move the lines, or click the delete button to delete the line (no warning!! on the delete!)</p>
<p>At the bottom, there is a blank line to add a new line:</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image13.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="223" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb13.png" width="644" border="0"></a></p>
<p>The record lines page allows for you to record lines that do not have a recording:</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image14.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="484" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb14.png" width="639" border="0"></a> </p>
<p>&nbsp;</p>
<p> The final page shows the Spanish lines in the correct order:</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image15.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="484" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb15.png" width="629" border="0"></a> </p>
<p>&nbsp;</p>
<p> The page uses SOX to combine the waves and LAME to convert them into MP3.&nbsp; I am not able to get it to work on the server at dreamhost.&nbsp; I downloaded SOX source, compiled, and it runs&#8230;&nbsp; But when I pass in the wav files to combine them, I get an error: &#8220;can&#8217;t open file&#8221;&#8230; &#8221; Could not find data chunk.&#8221;&nbsp; Any ideas?</p>
<p>&nbsp;</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image16.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="58" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb16.png" width="644" border="0"></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/08/04/script-editor-basic-version-deployed-to-the-server/feed</wfw:commentRss>
		</item>
		<item>
		<title>Script Editor - a look</title>
		<link>http://www.gadgetnate.com/2008/08/03/script-editor-a-look</link>
		<comments>http://www.gadgetnate.com/2008/08/03/script-editor-a-look#comments</comments>
		<pubDate>Mon, 04 Aug 2008 04:59:38 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/2008/08/03/script-editor-a-look</guid>
		<description><![CDATA[Here is the look I was thinking about for the HabloHindu script editor (the graphic needs to have the last &#8220;i&#8221; changed to a &#8220;u&#8221;.
 
Today, I added the ability for people to log in, and for the individual lines to be edited.&#160; I have all the pieces figured out.&#160; Now I just need to [...]]]></description>
			<content:encoded><![CDATA[<p>Here is the look I was thinking about for the HabloHindu script editor (the graphic needs to have the last &#8220;i&#8221; changed to a &#8220;u&#8221;.</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image7.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="213" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb7.png" width="487" border="0"></a> </p>
<p>Today, I added the ability for people to log in, and for the individual lines to be edited.&nbsp; I have all the pieces figured out.&nbsp; Now I just need to bring them together, polish it, and test.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/08/03/script-editor-a-look/feed</wfw:commentRss>
		</item>
		<item>
		<title>Script Editor - Combining the audio files</title>
		<link>http://www.gadgetnate.com/2008/08/02/script-editor-combining-the-audio-files</link>
		<comments>http://www.gadgetnate.com/2008/08/02/script-editor-combining-the-audio-files#comments</comments>
		<pubDate>Sat, 02 Aug 2008 13:02:12 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/2008/08/02/script-editor-combining-the-audio-files</guid>
		<description><![CDATA[&#160;
Combining the recordings has taken a little time to figure out.&#160; But now I can merge them, and convert them to MP3.&#160; Here is a screenshot of the page that produces the script in Spanish (just filter the Spanish lines) and puts links to the combined .Wav and .Mp3
&#160;
&#160;
&#8216;
To get this to work, I had [...]]]></description>
			<content:encoded><![CDATA[<p>&nbsp;</p>
<p>Combining the recordings has taken a little time to figure out.&nbsp; But now I can merge them, and convert them to MP3.&nbsp; Here is a screenshot of the page that produces the script in Spanish (just filter the Spanish lines) and puts links to the combined .Wav and .Mp3</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image4.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="221" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb4.png" width="536" border="0"></a>&#8216;</p>
<p>To get this to work, I had to call two command line functions &#8220;sox.exe&#8221; to combine the wavs&nbsp; (<a title="http://sox.sourceforge.net/" href="http://sox.sourceforge.net/">http://sox.sourceforge.net/</a>)&nbsp;&nbsp; together.&nbsp; and &#8220;Lame.exe&#8221; to convert it to an MP3 (<a title="http://lame.sourceforge.net/index.php" href="http://lame.sourceforge.net/index.php">http://lame.sourceforge.net/index.php</a>).</p>
<p>I had some trouble with LAME.&nbsp; It did not like the .Wav in the default format that the Java Sonics ListenUp Java Applet records in, i.e. ADPCM.&nbsp; It kept saying &#8220;unsupported format&#8221;.&nbsp; But it did work with &#8220;u8&#8243;.&nbsp; There is some type of distortion in the background though..</p>
<p>&nbsp;</p>
<p>I should also point out that I found a really neat looking PHP class to work with wav files called wav edit.&nbsp; I could not get it to work with the wavs I recorded though.&nbsp; Here are some screenshots of the sample page and a link to give you and idea of what I&#8217;m talking about.</p>
<p><a title="http://www.pviet.com/wavedit/" href="http://www.pviet.com/wavedit/">http://www.pviet.com/wavedit/</a></p>
<p>Sample page using my recordings:</p>
<p><a title="http://osdir.com/ml/audio.ecasound.general/2005-07/msg00008.html" href="http://osdir.com/ml/audio.ecasound.general/2005-07/msg00008.html"></a>&nbsp;</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image5.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="381" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb5.png" width="410" border="0"></a> </p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>using the recordings provided in the .zip</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image6.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="434" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb6.png" width="439" border="0"></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/08/02/script-editor-combining-the-audio-files/feed</wfw:commentRss>
		</item>
		<item>
		<title>Script Editor - Adding lines and recording audio</title>
		<link>http://www.gadgetnate.com/2008/08/01/script-editor-adding-lines-and-recording-audio</link>
		<comments>http://www.gadgetnate.com/2008/08/01/script-editor-adding-lines-and-recording-audio#comments</comments>
		<pubDate>Sat, 02 Aug 2008 01:15:42 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/2008/08/01/script-editor-adding-lines-and-recording-audio</guid>
		<description><![CDATA[Making some good progress today!!!&#160; I have added the ability to create lines for the script, delete lines, move lines up and down, record audio, and the like.&#160; Here are some screenshots:&#160; 
&#160;
 
The JavaSonic ListenUP applet records things as a .wav.&#160; I will need to join these together.&#160; I found a function to do [...]]]></description>
			<content:encoded><![CDATA[<p>Making some good progress today!!!&nbsp; I have added the ability to create lines for the script, delete lines, move lines up and down, record audio, and the like.&nbsp; Here are some screenshots:&nbsp; </p>
<p>&nbsp;</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image3.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="369" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb3.png" width="427" border="0"></a> </p>
<p>The JavaSonic ListenUP applet records things as a .wav.&nbsp; I will need to join these together.&nbsp; I found a function to do this:</p>
<p>&nbsp;</p>
<p><a title="http://www.splitbrain.org/blog/2006-11/15-joining_wavs_with_php" href="http://www.splitbrain.org/blog/2006-11/15-joining_wavs_with_php">http://www.splitbrain.org/blog/2006-11/15-joining_wavs_with_php</a></p>
<p>&nbsp;</p>
<pre>function joinwavs($wavs){
    $fields = <a href="http://www.php.net/join">join</a>(&#8217;/',<a href="http://www.php.net/array">array</a>( &#8216;H8ChunkID&#8217;, &#8216;VChunkSize&#8217;, &#8216;H8Format&#8217;,
                              &#8216;H8Subchunk1ID&#8217;, &#8216;VSubchunk1Size&#8217;,
                              &#8216;vAudioFormat&#8217;, &#8216;vNumChannels&#8217;, &#8216;VSampleRate&#8217;,
                              &#8216;VByteRate&#8217;, &#8216;vBlockAlign&#8217;, &#8216;vBitsPerSample&#8217; ));
    $data = &#8221;;
    foreach($wavs as $wav){
        $fp     = <a href="http://www.php.net/fopen">fopen</a>($wav,&#8217;rb&#8217;);
        $header = <a href="http://www.php.net/fread">fread</a>($fp,36);
        $info   = <a href="http://www.php.net/unpack">unpack</a>($fields,$header);
        // read optional extra stuff
        if($info['Subchunk1Size'] &gt; 16){
            $header .= <a href="http://www.php.net/fread">fread</a>($fp,($info['Subchunk1Size']-16));
        }
        // read SubChunk2ID
        $header .= <a href="http://www.php.net/fread">fread</a>($fp,4);
        // read Subchunk2Size
        $size  = <a href="http://www.php.net/unpack">unpack</a>(&#8217;vsize&#8217;,<a href="http://www.php.net/fread">fread</a>($fp, 4));
        $size  = $size['size'];
        // read data
        $data .= <a href="http://www.php.net/fread">fread</a>($fp,$size);
    }
    return $header.<a href="http://www.php.net/pack">pack</a>(&#8217;V',<a href="http://www.php.net/strlen">strlen</a>($data)).$data;
}</pre>
<p>It streams it out to the client.. .I will want to save it to the filesystem and use LAME to convert it into MP3.</p>
<p>This is the next step&#8230;&nbsp; After I am able to join them and convert them, then I will be at the point that I will have all the technical know how to do what I&#8217;m trying to do.&nbsp; Then it will be a matter of cleaning up the design, (in fact redesign (ok.. ok&#8230; not much of&nbsp; design now&#8230; just to design it)), make it look pretty, test test test&#8230; (I&#8217;m going to try to put the 15 scripts we have done so far for HabloHindu in there and see how that works), I need to add some authentication/security to it, then I will upload it and have Sara give it a try to see what she thinks&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/08/01/script-editor-adding-lines-and-recording-audio/feed</wfw:commentRss>
		</item>
		<item>
		<title>Script Editor - First Attempt</title>
		<link>http://www.gadgetnate.com/2008/08/01/script-editor-first-attempt</link>
		<comments>http://www.gadgetnate.com/2008/08/01/script-editor-first-attempt#comments</comments>
		<pubDate>Fri, 01 Aug 2008 13:16:09 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/2008/08/01/script-editor-first-attempt</guid>
		<description><![CDATA[I do not know PHP, but it seems very similar to lots of other web scripting languages I have used (NeoScript, ASP, etc.).&#160; With the help of a book, the web, and my past experience, I was able to put the following together in a few hours:
List of scripts page:
&#160;
 
&#8220;Add script&#8221; takes you to [...]]]></description>
			<content:encoded><![CDATA[<p>I do not know PHP, but it seems very similar to lots of other web scripting languages I have used (NeoScript, ASP, etc.).&nbsp; With the help of a book, the web, and my past experience, I was able to put the following together in a few hours:</p>
<p>List of scripts page:</p>
<p>&nbsp;</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="233" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb.png" width="432" border="0"></a> </p>
<p>&#8220;Add script&#8221; takes you to this page:</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image1.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="191" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb1.png" width="244" border="0"></a> </p>
<p>The date is pre-populated as the &#8220;max date&#8221; + 1 day.</p>
<p>If you clicked on a script title on the first page, then you would be taken to a view that let you change the script:</p>
<p><a href="http://www.gadgetnate.com/wp-content/uploads/2008/08/image2.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="203" alt="image" src="http://www.gadgetnate.com/wp-content/uploads/2008/08/image-thumb2.png" width="244" border="0"></a> </p>
<p>The code behind all this is not good.&nbsp; But I just wanted to get through the basics&#8230;&nbsp; Let me put it here for reference:</p>
<p>I called the list page add.php (long story&#8230;)</p>
<p>I called the add/edit page addScript.php.</p>
<p>add.php code:</p>
<p>&#8212;</p>
<p>&lt;?php<br />mysql_connect(&#8221;localhost&#8221;, &#8220;nobody&#8221;, &#8220;not_telling&#8221;);<br />mysql_select_db(&#8221;scriptEditor_dev&#8221;);
<p>$query = &#8220;select id, date, title, notes from script order by date;&#8221;;<br />$results = mysql_query($query)<br />?&gt;
<p>&lt;table&gt;<br />&lt;tr&gt;<br />&nbsp; &lt;th&gt;id&lt;/th&gt;<br />&nbsp; &lt;th&gt;date&lt;/th&gt;<br />&nbsp; &lt;th&gt;title&lt;/th&gt;<br />&nbsp; &lt;th&gt;notes&lt;/th&gt;<br />&lt;/tr&gt;
<p>&lt;?php<br />while ($row = mysql_fetch_array($results))<br />{<br />&nbsp;&nbsp;&nbsp; echo &#8216;&lt;tr&gt;&lt;td&gt;&#8217;;<br />&nbsp;&nbsp;&nbsp; echo $row['id'];<br />&nbsp;&nbsp;&nbsp; echo &#8216;&lt;/td&gt;&lt;td&gt;&#8217;;<br />&nbsp;&nbsp;&nbsp; echo $row['date'];<br />&nbsp;&nbsp;&nbsp; echo &#8216;&lt;/td&gt;&lt;td&gt;&lt;a href=&#8221;addScript.php?id=&#8217; . $row['id'] . &#8216;&#8221;&gt;&#8217;;<br />&nbsp;&nbsp;&nbsp; echo $row['title'];<br />&nbsp;&nbsp;&nbsp; echo &#8216;&lt;/a&gt;&lt;/td&gt;&lt;td&gt;&#8217;;<br />&nbsp;&nbsp;&nbsp; echo $row['notes'];<br />&nbsp;&nbsp;&nbsp; echo &#8216;&lt;/td&gt;&lt;/tr&gt;&#8217;;<br />}
<p>?&gt;&nbsp; <br />&lt;/table&gt;
<p>&lt;a href=&#8221;addScript.php&#8221;&gt;add script&lt;/a&gt;
<p>&#8212;&#8211;</p>
<p>&lt;?php<br />mysql_connect(&#8221;localhost&#8221;, &#8220;nobody&#8221;, &#8220;not_telling&#8221;);</p>
<p>mysql_select_db(&#8221;scriptEditor_dev&#8221;); </p>
<p>$id = &#8220;&#8221;;<br />$date = &#8220;&#8221;;<br />$title = &#8220;&#8221;;<br />$englishWord = &#8220;&#8221;;<br />$spanishWord = &#8220;&#8221;;<br />$hindiWord = &#8220;&#8221;;<br />$notes = &#8220;&#8221;;
<p>if($_POST["date"] != &#8220;&#8221;){<br />&nbsp;&nbsp;&nbsp; if($_POST["id"] != &#8220;&#8221;){<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $query = &#8220;update script set &#8221; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &#8220;date = &#8216;&#8221; . $_POST['date'] . &#8220;&#8216;, &#8221; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &#8220;Title = &#8216;&#8221; . $_POST['title'] . &#8220;&#8216;, &#8220;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &#8220;EnglishWord = &#8216;&#8221; . $_POST['englishWord'] . &#8220;&#8216;, &#8220;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &#8220;SpanishWord = &#8216;&#8221; . $_POST['spanishWord'] . &#8220;&#8216;, &#8220;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &#8220;HindiWord = &#8216;&#8221; . $_POST['hindiWord'] . &#8220;&#8216;, &#8220;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &#8220;Notes = &#8216;&#8221; . $_POST['notes'] . &#8220;&#8216; &#8220;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . &#8221; where id=&#8221; . $_POST["id"] . &#8220;;&#8221;;<br />&nbsp;&nbsp;&nbsp; }else<br />&nbsp;&nbsp;&nbsp; {<br />&nbsp;&nbsp;&nbsp; $query = &#8220;insert into script (date, Title, EnglishWord, SpanishWord, HindiWord, Notes) values (&#8217;&#8221; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . $_POST['date'] . &#8220;&#8216;, &#8216;&#8221; <br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . $_POST['title'] . &#8220;&#8216;, &#8216;&#8221;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . $_POST['englishWord'] . &#8220;&#8216;, &#8216;&#8221;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . $_POST['spanishWord'] . &#8220;&#8216;, &#8216;&#8221;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . $_POST['hindiWord'] . &#8220;&#8216;, &#8216;&#8221;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; . $_POST['notes'] . &#8220;&#8216;);&#8221;;<br />&nbsp;&nbsp;&nbsp; }<br />&nbsp;&nbsp;&nbsp; //echo $query;<br />&nbsp;&nbsp;&nbsp; mysql_query($query);<br />&nbsp;&nbsp;&nbsp; header(&#8217;Location: add.php&#8217;);<br />} elseif($_GET['id'] != &#8220;&#8221;)<br />{<br />&nbsp;&nbsp;&nbsp; $query = &#8220;select date, Title, EnglishWord, SpanishWord, HindiWord, Notes from script where id =&#8221; . $_GET["id"];<br />&nbsp;&nbsp;&nbsp; $results = mysql_query($query);<br />&nbsp;&nbsp;&nbsp; $row = mysql_fetch_array($results);<br />&nbsp;&nbsp;&nbsp; $id = $_GET['id'];<br />&nbsp;&nbsp;&nbsp; $date = $row['date'];<br />&nbsp;&nbsp;&nbsp; $title = $row['Title'];<br />&nbsp;&nbsp;&nbsp; $englishWord = $row['EnglishWord'];<br />&nbsp;&nbsp;&nbsp; $spanishWord = $row['SpanishWord'];<br />&nbsp;&nbsp;&nbsp; $hindiWord = $row['HindiWord'];<br />&nbsp;&nbsp;&nbsp; $notes = $row['Notes'];<br />}else{<br />$query = &#8220;select adddate( max(date), interval 1 day) as mx_dt from script order by date;&#8221;;<br />$results = mysql_query($query);<br />$row = mysql_fetch_array($results);<br />$date = $row["mx_dt"];<br />}<br />?&gt;<br />&lt;form method=&#8221;post&#8221;&gt;<br />&lt;input type=&#8221;hidden&#8221; name=&#8221;id&#8221; value=&#8221;&lt;?php echo $id ?&gt;&#8221;&gt;<br />&lt;table&gt;<br />&lt;tr&gt;&lt;th&gt;date&lt;/th&gt;&lt;td&gt;&lt;input type=&#8221;text&#8221; name=&#8221;date&#8221; value=&#8221;&lt;?php <br />echo $date; <br />?&gt;&#8221;&gt;&lt;/td&gt;&lt;/tr&gt;<br />&lt;tr&gt;&lt;th&gt;title&lt;/th&gt;&lt;td&gt;&lt;input type=&#8221;text&#8221; name=&#8221;title&#8221; value=&#8221;&lt;?php echo $title ?&gt;&#8221;&gt;&lt;/td&gt;&lt;/tr&gt;<br />&lt;tr&gt;&lt;th&gt;English Word&lt;/th&gt;&lt;td&gt;&lt;input type=&#8221;text&#8221; name=&#8221;englishWord&#8221; value=&#8221;&lt;?php echo $englishWord ?&gt;&#8221;&gt;&lt;/td&gt;&lt;/tr&gt;<br />&lt;tr&gt;&lt;th&gt;Spanish Word&lt;/th&gt;&lt;td&gt;&lt;input type=&#8221;text&#8221; name=&#8221;spanishWord&#8221; value=&#8221;&lt;?php echo $spanishWord ?&gt;&#8221;&gt;&lt;/td&gt;&lt;/tr&gt;<br />&lt;tr&gt;&lt;th&gt;Hindi Word&lt;/th&gt;&lt;td&gt;&lt;input type=&#8221;text&#8221; name=&#8221;hindiWord&#8221; value=&#8221;&lt;?php echo $hindiWord ?&gt;&#8221;&gt;&lt;/td&gt;&lt;/tr&gt;<br />&lt;tr&gt;&lt;th&gt;Notes&lt;/th&gt;&lt;td&gt;&lt;input type=&#8221;text&#8221; name=&#8221;notes&#8221; value=&#8221;&lt;?php echo $notes ?&gt;&#8221;&gt;&lt;/td&gt;&lt;/tr&gt;<br />&lt;tr&gt;&lt;th&gt;&lt;/th&gt;&lt;td&gt;&lt;input type=&#8221;submit&#8221;&gt;&lt;/td&gt;&lt;/tr&gt;<br />&lt;/table&gt;<br />&lt;/form&gt;
<p>&nbsp;
<p>&#8212;&#8211;
<p>&nbsp;
<p>Before moving on, here are the changes I am going to make:
<p>1) Need to have an include file to contain the database connection information
<p>2)&nbsp; Need to add Model and data access&#8230;&nbsp; Do not need to have SQL intermixed in my HTML page.
<p>3) Need a function that can easily switch from edit to view&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/08/01/script-editor-first-attempt/feed</wfw:commentRss>
		</item>
		<item>
		<title>Script Editor - Setting up the dev environment</title>
		<link>http://www.gadgetnate.com/2008/08/01/script-editor-setting-up-the-dev-environment</link>
		<comments>http://www.gadgetnate.com/2008/08/01/script-editor-setting-up-the-dev-environment#comments</comments>
		<pubDate>Fri, 01 Aug 2008 13:06:34 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/2008/08/01/script-editor-setting-up-the-dev-environment</guid>
		<description><![CDATA[In order to do programming for LAMP, you have to setup apache webserver, install PHP, setup MySql, and probably a number of other things.&#160; Or you could take the easy route and get from ApacheFriends.
&#160;
For IDE, I am using the Eclipse version of PHP Development Tools.
]]></description>
			<content:encoded><![CDATA[<p>In order to do programming for LAMP, you have to setup apache webserver, install PHP, setup MySql, and probably a number of other things.&nbsp; Or you could take the easy route and get <a href="http://www.apachefriends.org/en/xampp.html"><img title="XAMPP" src="http://www.apachefriends.org/images/1240.jpg" border="0"></a>from <a href="http://www.apachefriends.org/en/index.html">ApacheFriends</a>.</p>
<p>&nbsp;</p>
<p>For IDE, I am using the <a href="http://www.eclipse.org/">Eclipse</a> version of <a href="http://www.eclipse.org/pdt/">PHP Development Tools</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/08/01/script-editor-setting-up-the-dev-environment/feed</wfw:commentRss>
		</item>
		<item>
		<title>Script Editor - The Game Plan</title>
		<link>http://www.gadgetnate.com/2008/07/31/script-editor-the-game-plan</link>
		<comments>http://www.gadgetnate.com/2008/07/31/script-editor-the-game-plan#comments</comments>
		<pubDate>Thu, 31 Jul 2008 13:23:52 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/2008/07/31/script-editor-the-game-plan</guid>
		<description><![CDATA[If you read the last post, you understand the problem that I am trying to solve.&#160; I need a way to automate the creation of a script for HabloHindu.com.&#160; It should keep track of the word of the day in Spanish/English/Hindi.&#160; Allow for people to know what they need to do, e.g. review a script, [...]]]></description>
			<content:encoded><![CDATA[<p>If you read the last post, you understand the problem that I am trying to solve.&nbsp; I need a way to automate the creation of a script for <a href="http://HabloHindu.com">HabloHindu.com</a>.&nbsp; It should keep track of the word of the day in Spanish/English/Hindi.&nbsp; Allow for people to know what they need to do, e.g. review a script, answer a question, translate something, record something, etc.&nbsp; It needs to mix together the various recordings, and post the final results to WordPress.&nbsp; </p>
<p>In this post, I hope to outline my current approach.&nbsp; I plan to keep a running journal of my progress, which will be helpful to me later on to review, and will hopefully be helpful for you as well.</p>
<p>Selection of tools:&nbsp; I am going to write this targeting a LAMP stack (linux, apache, MySql, Php).&nbsp; My development environment is a windows vista laptop, but my server is a linux server running at <a href="http://DreamHost.com">DreamHost</a>.&nbsp; Other than that, my development and production environments are the same.</p>
<p>Let me give you an idea of the flow:</p>
<p>1) Log in to the application</p>
<p>2) See list of scripts with status (Just started; Need review; Need recording; Ready; Published)&nbsp; Each script will have a notes section displayed on the status screen that will allow for Sara and I to communicate with each other.</p>
<p>3) On the list of scripts page, there will be a &#8220;new script&#8221; button.&nbsp; This will allow for you to create a new script.&nbsp; Let us walk through the new script process</p>
<p>4) Clicking on the &#8220;new script&#8221; button will take you to the &#8220;script edit&#8221; page with some fields filled in with defaults, and others that will have to be filled in.</p>
<p>Publish Date: &lt;default to the next day after the last script in the system&gt;</p>
<p>Word of the Day in English:</p>
<p>word of the day in Spanish:</p>
<p>Word of the day in Hindi (devanagari):</p>
<p>Word of the day in Hindi (English Transliteration):</p>
<p>Word of the day in Hindi (Spanish Transliteration):</p>
<p>Notes:</p>
<p>Status: &lt;default to &#8220;Just started&#8221;&gt;</p>
<p>Then there will be a button to &#8220;save&#8221;</p>
<p>5) After clicking &#8220;save&#8221;, you will see the script &#8220;header&#8221; information in read only mode.&nbsp; And there will be a button to &#8220;add a line&#8221;.&nbsp; When you click this, you will be taken to a page that looks exactly like this one, but will have a new &#8220;script line&#8221; at the bottom, with the following fields:</p>
<p>Speaker (drop down with a list of speakers) (currently: Sara, Meena, Nariandas)</p>
<p>Spanish:</p>
<p>English:</p>
<p>Notes:</p>
<p>6) After clicking the &#8220;save&#8221; button, you will be taken to the read-only mode.&nbsp; And you will have some basic functions like, move line up, move line down, insert line here, delete line, go to script list page, edit script header and the like.</p>
<p>7) The above takes care of the script editing.&nbsp; Now, to the recording.&nbsp; to each script line in the recording, I will add&nbsp; a little Java Applet (Like <a href="http://www.javasonics.com/">Java Sonics ListenUp voice recording Applet</a>) or a flash based record like <a href="http://www.evoca.com/">Evoca</a>)</p>
<p> <img src='http://www.gadgetnate.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> Then a good next step will be to have a page by speaker with all the lines.&nbsp; That way I can sit with Meena or Nariandas and just record all the lines at one time.</p>
<p>9) Mix the audio together here is a discussion about this: <a title="http://ask.metafilter.com/21381/Merge-mp3s-with-PHP" href="http://ask.metafilter.com/21381/Merge-mp3s-with-PHP">http://ask.metafilter.com/21381/Merge-mp3s-with-PHP</a></p>
<p>10) post the information to HabloHindi wordpress using the webservices interface or directly into the database&#8230;</p>
<p>so, it is a very basic design..&nbsp; I&#8217;ll keep you posted on my progress&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/07/31/script-editor-the-game-plan/feed</wfw:commentRss>
		</item>
		<item>
		<title>Script Editor - The Problem</title>
		<link>http://www.gadgetnate.com/2008/07/31/script-editor-the-problem</link>
		<comments>http://www.gadgetnate.com/2008/07/31/script-editor-the-problem#comments</comments>
		<pubDate>Thu, 31 Jul 2008 12:58:34 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/2008/07/31/script-editor-the-problem</guid>
		<description><![CDATA[I am working with Sara, a friend from Venezuela to create a Spanish site to teach Hindi.&#160; It launches tomorrow with a Hindi word of the day with an audio cast and text for Spanish speakers at HabloHindu.com.&#160; It has required a lot of work to create some relatively short programs.&#160; And most of that [...]]]></description>
			<content:encoded><![CDATA[<p>I am working with Sara, a friend from Venezuela to create a Spanish site to teach Hindi.&nbsp; It launches tomorrow with a Hindi word of the day with an audio cast and text for Spanish speakers at <a href="http://HabloHindu.com">HabloHindu.com</a>.&nbsp; It has required a lot of work to create some relatively short programs.&nbsp; And most of that work had to do with things that could be automated.</p>
<p>Let me explain our process so far:</p>
<p>1) Create a script.&nbsp; You can see the list of scripts we have created so far:</p>
<p><a title="http://www.ispeakhindi.com/wiki/index.php?title=En_Espa%C3%B1ol" href="http://www.ispeakhindi.com/wiki/index.php?title=En_Espa%C3%B1ol">http://www.ispeakhindi.com/wiki/index.php?title=En_Espa%C3%B1ol</a></p>
<p>You have to create a link to each script.&nbsp; Put the text in English/Hindi (if I am working on it) and in Spanish/English/Hindi if Sara is working on it.&nbsp; Then if we have questions or need help about the script, we add a note.&nbsp; The other person can look at recent changes in the wiki to see this.&nbsp; It can take a while to create a script.&nbsp; Each of these scripts probably represent at least 2 hours of work.</p>
<p>2) Record the Spanish part.&nbsp; After the script is ready, Sara will record the Spanish part.&nbsp; You can see examples of this on this page: <a title="http://www.ispeakhindi.com/wiki/index.php?title=Make_organised_our_work_together_for_august" href="http://www.ispeakhindi.com/wiki/index.php?title=Make_organised_our_work_together_for_august">http://www.ispeakhindi.com/wiki/index.php?title=Make_organised_our_work_together_for_august</a></p>
<p>Listen to some of the files under &#8220;recording by Sara&#8221;.</p>
<p>3) Then we have to record the Hindi part.&nbsp; To do this, I need a list of the Hindi words/phrases and who says them (Nariandas or Meena).&nbsp; To create that list, I scan through the scripts looking for Hindi.&nbsp; Then I created another wiki page to track this: <a title="http://www.ispeakhindi.com/wiki/index.php?title=Recordings_that_Meena_and_Nariandas_need_to_make" href="http://www.ispeakhindi.com/wiki/index.php?title=Recordings_that_Meena_and_Nariandas_need_to_make">http://www.ispeakhindi.com/wiki/index.php?title=Recordings_that_Meena_and_Nariandas_need_to_make</a></p>
<p>Then I sit with Meena and Nariandas to record the Hindi.&nbsp; Recording each of these files took some time in Audacity.&nbsp; I had to give each file a name that reflect to the word.&nbsp; I had to click &#8220;OK&#8221; on the MP3 properties dialog box.&nbsp; All that time adds up.&nbsp; It probably takes at least a minute for each of the phrases/words&#8230;</p>
<p>4) Then I have to mix the Spanish and Hindi together.&nbsp; I listen to the Spanish in Audacity and read along with the script.&nbsp; Sara leaves pauses for me to know where the Hindi needs to go.&nbsp; Then I find the right Hindi file, insert it in.&nbsp; I try to match the volume between the two recordings, but have not been able to do a good job at this.&nbsp;&nbsp; Editing each of the recordings probably takes 15 minutes.</p>
<p>5) Then a post needs to be created in WordPress on HabloHindu.com.&nbsp; This means copying the script from the wiki to WordPress and removing all the English.&nbsp; Also, have to upload the final recording and set it up in the PodPress.&nbsp; This probably takes about 5 minutes a recording.&nbsp; And set the go live date to the appropriate day.</p>
<p>Here are the totals for one script:</p>
<p>2 hours script creation/editing</p>
<p>?? Record by sara</p>
<p>15 minutes to record the Hindi</p>
<p>15 minutes to mix together</p>
<p>5 minutes to post on HabloHindu</p>
<p>Therefore, each 30 second - 1minute HabloHindu episode is currently taking around 2 and a half hours to create.&nbsp; I think it might be possible to get that down to 30 minutes or less using an automated solution.&nbsp; I&#8217;ll talk about that in the next post.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/07/31/script-editor-the-problem/feed</wfw:commentRss>
		</item>
		<item>
		<title>Vegan Chocolate Frosting</title>
		<link>http://www.gadgetnate.com/2008/07/28/vegan-chocolate-frosting</link>
		<comments>http://www.gadgetnate.com/2008/07/28/vegan-chocolate-frosting#comments</comments>
		<pubDate>Mon, 28 Jul 2008 18:20:33 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[Cooking and Eating]]></category>

		<guid isPermaLink="false">http://www.gadgetnate.com/?p=1005</guid>
		<description><![CDATA[(from http://vegweb.com/index.php?topic=6441.0)
Vegan Chocolate Frosting
Ingredients (use vegan versions):
    1 cup margarine
    4 cups powdered sugar (make your own if you want - blend sugar and cornstarch)
    2 tablespoon vanilla
    4 tablespoon soy milk
    1/2 cup cocoa powder (or more)
    dash of salt
Directions:
Margin should be at room temperature when being placed [...]]]></description>
			<content:encoded><![CDATA[<p><span style="color: #ff6600;"><span style="font-size: 12pt; line-height: 1.3em;"><strong></strong></span></span>(from <a href="http://vegweb.com/index.php?topic=6441.0">http://vegweb.com/index.php?topic=6441.0</a>)</p>
<p><span style="color: #ff6600;"><span style="font-size: 12pt; line-height: 1.3em;"><strong>Vegan Chocolate Frosting</strong></span></span></p>
<p><span style="color: #ff6600;">Ingredients (use <a href="http://vegweb.com/index.php?PHPSESSID=4c59baabaced3ee2923773a5be62fd85&amp;topic=15403.0">vegan versions</a>):</span></p>
<p>    1 cup margarine<br />
    4 cups powdered sugar (make your own if you want - blend sugar and cornstarch)<br />
    2 tablespoon vanilla<br />
    4 tablespoon <a href="http://vegweb.com/glossary.shtml#Soy Milk"><span style="color: #008000;">soy milk</span></a><br />
    1/2 cup cocoa powder (or more)<br />
    dash of salt</p>
<p><span style="color: #ff6600;">Directions:</span></p>
<p>Margin should be at room temperature when being placed in bowl. Blend until mushy, and then add vegan powdered sugar, salt, vanilla, chocolate and soymilk. You can add in more soymilk to make it a bit smoother but not too much. Spread on cake and enjoy.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gadgetnate.com/2008/07/28/vegan-chocolate-frosting/feed</wfw:commentRss>
		</item>
	</channel>
</rss>
