<?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: How to create your own customized calculator via JavaScript</title>
	<atom:link href="http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/</link>
	<description>Random Snippets of Code and Ideas for any Web Developer</description>
	<lastBuildDate>Sat, 17 Jul 2010 11:08:13 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=abc</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Knix</title>
		<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/comment-page-1/#comment-822</link>
		<dc:creator>Knix</dc:creator>
		<pubDate>Thu, 20 Nov 2008 05:47:38 +0000</pubDate>
		<guid isPermaLink="false">http://www.randomsnippets.com/?p=15#comment-822</guid>
		<description>Hi,

Please have a look at my post on JavaScript prompts.  You can use the same exact idea and just use &lt;b&gt;eval&lt;/b&gt; on the string that the user has entered into the prompt.  The only thing here is that you would have to do input verification and make sure the user has only entered the allowed characters in constructing the string.</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>Please have a look at my post on JavaScript prompts.  You can use the same exact idea and just use <b>eval</b> on the string that the user has entered into the prompt.  The only thing here is that you would have to do input verification and make sure the user has only entered the allowed characters in constructing the string.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Guest</title>
		<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/comment-page-1/#comment-702</link>
		<dc:creator>Guest</dc:creator>
		<pubDate>Thu, 13 Nov 2008 14:18:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.randomsnippets.com/?p=15#comment-702</guid>
		<description>how would i make a calculator using javascript prompts??</description>
		<content:encoded><![CDATA[<p>how would i make a calculator using javascript prompts??</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Knix</title>
		<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/comment-page-1/#comment-621</link>
		<dc:creator>Knix</dc:creator>
		<pubDate>Tue, 28 Oct 2008 22:50:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.randomsnippets.com/?p=15#comment-621</guid>
		<description>Hi May,

I&#039;m doing well.  Thanks =)</description>
		<content:encoded><![CDATA[<p>Hi May,</p>
<p>I&#8217;m doing well.  Thanks =)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: may</title>
		<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/comment-page-1/#comment-601</link>
		<dc:creator>may</dc:creator>
		<pubDate>Sat, 25 Oct 2008 00:55:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.randomsnippets.com/?p=15#comment-601</guid>
		<description>hi knix how are you</description>
		<content:encoded><![CDATA[<p>hi knix how are you</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Knix</title>
		<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/comment-page-1/#comment-593</link>
		<dc:creator>Knix</dc:creator>
		<pubDate>Fri, 24 Oct 2008 04:00:15 +0000</pubDate>
		<guid isPermaLink="false">http://www.randomsnippets.com/?p=15#comment-593</guid>
		<description>This is possible but it would take a little tweaking of the code.  Basically, you would need to alter the &lt;b&gt;equation&lt;/b&gt; before submitting it to &lt;b&gt;eval&lt;/b&gt;. For example, let&#039;s say &quot;%&quot; will represent your percent function.

If equation = 2%4

Alter the equation such that = 2/4*100

Then execute the &lt;b&gt;eval&lt;/b&gt; function with this string

That should do it.</description>
		<content:encoded><![CDATA[<p>This is possible but it would take a little tweaking of the code.  Basically, you would need to alter the <b>equation</b> before submitting it to <b>eval</b>. For example, let&#8217;s say &#8220;%&#8221; will represent your percent function.</p>
<p>If equation = 2%4</p>
<p>Alter the equation such that = 2/4*100</p>
<p>Then execute the <b>eval</b> function with this string</p>
<p>That should do it.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: laura Word</title>
		<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/comment-page-1/#comment-557</link>
		<dc:creator>laura Word</dc:creator>
		<pubDate>Fri, 17 Oct 2008 20:06:30 +0000</pubDate>
		<guid isPermaLink="false">http://www.randomsnippets.com/?p=15#comment-557</guid>
		<description>This is exactly what I have been looking for! with one exception. :)

I have added a few other buttons to show a word and represent a specific corresponding number so I get how to modify the code but I can&#039;t seem to figure out how to add one that calculates the percentage that one number represents of another.

Can you help?</description>
		<content:encoded><![CDATA[<p>This is exactly what I have been looking for! with one exception. :)</p>
<p>I have added a few other buttons to show a word and represent a specific corresponding number so I get how to modify the code but I can&#8217;t seem to figure out how to add one that calculates the percentage that one number represents of another.</p>
<p>Can you help?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Knix</title>
		<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/comment-page-1/#comment-415</link>
		<dc:creator>Knix</dc:creator>
		<pubDate>Thu, 25 Sep 2008 01:10:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.randomsnippets.com/?p=15#comment-415</guid>
		<description>Hi Paul,

Can you please post your code so that I can what you are referring to?</description>
		<content:encoded><![CDATA[<p>Hi Paul,</p>
<p>Can you please post your code so that I can what you are referring to?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Paul</title>
		<link>http://www.randomsnippets.com/2008/04/26/how-to-create-your-own-customized-calculator-via-javascript/comment-page-1/#comment-414</link>
		<dc:creator>Paul</dc:creator>
		<pubDate>Wed, 24 Sep 2008 15:35:20 +0000</pubDate>
		<guid isPermaLink="false">http://www.randomsnippets.com/?p=15#comment-414</guid>
		<description>Thanks for the JavaScript calculator. I was high-centered on the eval function ie. how to make it work on the input string.
My calculator was set up similar to yours except mine didn&#039;t work! Much appreciated.</description>
		<content:encoded><![CDATA[<p>Thanks for the JavaScript calculator. I was high-centered on the eval function ie. how to make it work on the input string.<br />
My calculator was set up similar to yours except mine didn&#8217;t work! Much appreciated.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
