<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Simple Menu for User Input</title>
	<atom:link href="http://www.tech-recipes.com/rx/983/simple-menu-for-user-input/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.tech-recipes.com/rx/983/simple-menu-for-user-input/</link>
	<description>Computer and technology tutorials and guides</description>
	<lastBuildDate>Sun, 22 Nov 2009 00:56:44 -0800</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: LukeS</title>
		<link>http://www.tech-recipes.com/rx/983/simple-menu-for-user-input/comment-page-1/#comment-11774</link>
		<dc:creator>LukeS</dc:creator>
		<pubDate>Mon, 25 May 2009 15:39:34 +0000</pubDate>
		<guid isPermaLink="false">guid-fix-me!#comment-11774</guid>
		<description>there are sever problems in his, try this, its still not perfect, but it works:&lt;br&gt;#!/bin/bash&lt;br&gt;&lt;br&gt;## Clears the screen and builds the user input screen&lt;br&gt;&lt;br&gt;function screen() {&lt;br&gt;clear&lt;br&gt;cat &lt;&lt;EOF&lt;br&gt;####################################################################&lt;br&gt;## Main Screen for Input                                          ##&lt;br&gt;####################################################################&lt;br&gt;##                                                                ##&lt;br&gt;## User Name: [________________________________________]          ##&lt;br&gt;## Directory: [________________________________________]          ##&lt;br&gt;## Group:     [________________________________________]          ##&lt;br&gt;##                                                                ##&lt;br&gt;####################################################################&lt;br&gt;##            [ Preferences ]        [ Other Info ]               ##&lt;br&gt;####################################################################&lt;br&gt;## [_] Show Email?     [_] Receive News?                          ##&lt;br&gt;## [_] Show Address?   [_] Receive RSS?                           ##&lt;br&gt;####################################################################&lt;br&gt;EOF&lt;br&gt;}&lt;br&gt;&lt;br&gt;## This will echo out the contents of the helpString variable&lt;br&gt;## below the screen&lt;br&gt;function showHelp() {&lt;br&gt;tput cup 14 0&lt;br&gt;## Clear out the last information&lt;br&gt;echo &quot; &quot;&lt;br&gt;tput cup 14 0&lt;br&gt;echo $helpString&lt;br&gt;}&lt;br&gt;## Display the screen&lt;br&gt;screen&lt;br&gt;&lt;br&gt;## Set up the help information, and call the showHelp function&lt;br&gt;## that displays it&lt;br&gt;helpString=&quot;Enter the user or press ENTER to quit&quot;&lt;br&gt;showHelp&lt;br&gt;tput cup 4 15&lt;br&gt;read username&lt;br&gt;## If they don&#039;t enter a username, quit&lt;br&gt;if [ &quot;$username&quot; = &quot;&quot; ]&lt;br&gt;then&lt;br&gt;exit&lt;br&gt;fi&lt;br&gt;&lt;br&gt;## Now go through and get the other data&lt;br&gt;helpString=&quot;Enter Home Directory&quot;&lt;br&gt;showHelp&lt;br&gt;tput cup 5 15&lt;br&gt;read directory&lt;br&gt;&lt;br&gt;helpString=&quot;What group does $username belong to?&quot;&lt;br&gt;showHelp&lt;br&gt;tput cup 6 15&lt;br&gt;read group&lt;br&gt;&lt;br&gt;helpString=&quot;Do you want to show the Email Address to others? [y/n&quot;&lt;br&gt;showHelp&lt;br&gt;tput cup 11 4&lt;br&gt;read showEmail&lt;br&gt;&lt;br&gt;helpString=&quot;Do you want to show your Home Address to others [y/n]&quot;&lt;br&gt;showHelp&lt;br&gt;tput cup 12 4&lt;br&gt;read showAddress&lt;br&gt;&lt;br&gt;helpString=&quot;Would you like to receive the News Letter?&quot;&lt;br&gt;showHelp&lt;br&gt;tput cup 11 24&lt;br&gt;read getNews&lt;br&gt;&lt;br&gt;helpString=&quot;Would you like to receive the RSS Feed?&quot;&lt;br&gt;showHelp&lt;br&gt;tput cup 12 24&lt;br&gt;read getRSS&lt;br&gt;&lt;br&gt;helpString=&quot;Thank you for your input&quot;&lt;br&gt;showHelp&lt;br&gt;echo &quot;&quot;</description>
		<content:encoded><![CDATA[<p>there are sever problems in his, try this, its still not perfect, but it works:<br />#!/bin/bash</p>
<p>## Clears the screen and builds the user input screen</p>
<p>function screen() {<br />clear<br />cat &lt;&lt;EOF<br />####################################################################<br />## Main Screen for Input                                          ##<br />####################################################################<br />##                                                                ##<br />## User Name: [________________________________________]          ##<br />## Directory: [________________________________________]          ##<br />## Group:     [________________________________________]          ##<br />##                                                                ##<br />####################################################################<br />##            [ Preferences ]        [ Other Info ]               ##<br />####################################################################<br />## [_] Show Email?     [_] Receive News?                          ##<br />## [_] Show Address?   [_] Receive RSS?                           ##<br />####################################################################<br />EOF<br />}</p>
<p>## This will echo out the contents of the helpString variable<br />## below the screen<br />function showHelp() {<br />tput cup 14 0<br />## Clear out the last information<br />echo &#8221; &#8220;<br />tput cup 14 0<br />echo $helpString<br />}<br />## Display the screen<br />screen</p>
<p>## Set up the help information, and call the showHelp function<br />## that displays it<br />helpString=&#8221;Enter the user or press ENTER to quit&#8221;<br />showHelp<br />tput cup 4 15<br />read username<br />## If they don&#39;t enter a username, quit<br />if [ "$username" = "" ]<br />then<br />exit<br />fi</p>
<p>## Now go through and get the other data<br />helpString=&#8221;Enter Home Directory&#8221;<br />showHelp<br />tput cup 5 15<br />read directory</p>
<p>helpString=&#8221;What group does $username belong to?&#8221;<br />showHelp<br />tput cup 6 15<br />read group</p>
<p>helpString=&#8221;Do you want to show the Email Address to others? [y/n"<br />showHelp<br />tput cup 11 4<br />read showEmail</p>
<p>helpString="Do you want to show your Home Address to others [y/n]&#8220;<br />showHelp<br />tput cup 12 4<br />read showAddress</p>
<p>helpString=&#8221;Would you like to receive the News Letter?&#8221;<br />showHelp<br />tput cup 11 24<br />read getNews</p>
<p>helpString=&#8221;Would you like to receive the RSS Feed?&#8221;<br />showHelp<br />tput cup 12 24<br />read getRSS</p>
<p>helpString=&#8221;Thank you for your input&#8221;<br />showHelp<br />echo &#8220;&#8221;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sunny</title>
		<link>http://www.tech-recipes.com/rx/983/simple-menu-for-user-input/comment-page-1/#comment-10692</link>
		<dc:creator>Sunny</dc:creator>
		<pubDate>Thu, 23 Apr 2009 02:41:52 +0000</pubDate>
		<guid isPermaLink="false">guid-fix-me!#comment-10692</guid>
		<description>when i just copy paste your script and try to run, i encountered with below error, please suggest what is wrong... and thx for your script...&lt;br&gt;===============&lt;br&gt;ERROR:&lt;br&gt;user-input.sh: line 7: syntax error near unexpected token `newline&#039;&lt;br&gt;user-input.sh: line 7: `cat &lt;&#039;&lt;br&gt;=================</description>
		<content:encoded><![CDATA[<p>when i just copy paste your script and try to run, i encountered with below error, please suggest what is wrong&#8230; and thx for your script&#8230;<br />===============<br />ERROR:<br />user-input.sh: line 7: syntax error near unexpected token `newline&#39;<br />user-input.sh: line 7: `cat &lt;&#39;<br />=================</p>
]]></content:encoded>
	</item>
</channel>
</rss>
