<?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"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>ubuntu,debian,redhat -linuxany.com &#187; javascript</title>
	<atom:link href="http://www.linuxany.com/archives/tag/javascript/feed" rel="self" type="application/rss+xml" />
	<link>http://www.linuxany.com</link>
	<description></description>
	<lastBuildDate>Thu, 26 Jan 2012 08:59:02 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Python 执行js的2种解决方案</title>
		<link>http://www.linuxany.com/archives/1956.html</link>
		<comments>http://www.linuxany.com/archives/1956.html#comments</comments>
		<pubDate>Sun, 08 Jan 2012 08:23:47 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[Mozilla]]></category>
		<category><![CDATA[PerlConnect]]></category>
		<category><![CDATA[SpiderMonkey]]></category>

		<guid isPermaLink="false">http://www.linuxany.com/?p=1956</guid>
		<description><![CDATA[第1种方案 SpiderMonkey是Mozilla项目的一部分，是一个用C语言实现的JavaScript脚本引擎， 该引擎分析、编译和执行脚本，根据JS数据类型和对象的需要进行内存分配及释放操作；利用该引擎可以让你的应用程序具有解释JavaScript脚本的能力。 要想使用spidermonkey得先安装，方法如下： cd /home/linuxany.com/ wget http://ftp.mozilla.org/pub/mozilla.org/js/js-1.7.0.tar.gz -O- &#124; tar xvz cd js/src make -f Makefile.ref mkdir -p /usr/include/smjs/ -v cp *.{h,tbl} /usr/include/smjs/ -v cd Linux_All_DBG.OBJ cp *.h /usr/include/smjs/ -v mkdir -p /usr/local/{bin,lib}/ -v cp js /usr/local/bin/ -v cp libjs.so /usr/local/lib/ -v 以上安装完成后，运行/usr/local/bin/js 就应该可以启动js解释运行引擎了. python使用举例： # coding:utf-8 import&#160;os import&#160;tempfile &#160; def&#160;call_js(js): &#160; &#160; &#160; [...]]]></description>
		<wfw:commentRss>http://www.linuxany.com/archives/1956.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>兼容IE/Firefox的设为首页加入收藏(javascript)</title>
		<link>http://www.linuxany.com/archives/1260.html</link>
		<comments>http://www.linuxany.com/archives/1260.html#comments</comments>
		<pubDate>Sun, 02 May 2010 12:13:13 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Html5/JS/CSS]]></category>
		<category><![CDATA[favorite]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://www.linuxany.com/?p=1260</guid>
		<description><![CDATA[调用方法： &#60;a href=&#34;#&#34; onclick=&#34;setHomepage();&#34;&#62;设为首页&#60;/a&#62;&#160;&#160; &#60;a&#160;href=&#34;javascript:AddToFavorite();&#34; &#62;添加收藏&#60;/a&#62; 具体代码： //添加到收藏夹 function&#160;AddToFavorite() { &#160; &#160; if&#160;(document.all){ &#160; &#160; &#160;&#160; window.external.addFavorite(document.URL,document.title); &#160; &#160; }else&#160;if (window.sidebar){ &#160; &#160; &#160;&#160; window.sidebar.addPanel(document.title, document.URL, &#34;&#34;); &#160; &#160; } } &#160; //设为首页 function&#160;setHomepage(){ &#160; &#160; if&#160;(document.all){ &#160; &#160; document.body.style.behavior='url(#default#homepage)'; &#160; &#160; document.body.setHomePage(document.URL); &#160; }else&#160;if (window.sidebar){ &#160; &#160; &#160; &#160; if(window.netscape){ &#160; &#160; &#160;&#160; try{&#160; [...]]]></description>
		<wfw:commentRss>http://www.linuxany.com/archives/1260.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>IE+JavaScript上传之前检测图片文件大小</title>
		<link>http://www.linuxany.com/archives/654.html</link>
		<comments>http://www.linuxany.com/archives/654.html#comments</comments>
		<pubDate>Thu, 04 Dec 2008 04:37:32 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Html5/JS/CSS]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.linuxlaptop.cn/?p=654</guid>
		<description><![CDATA[文件上传之前的检测，通常是通过文件名来判断文件类型是否合法，但是要想检测文件的大小很难办到，除非在本地或者使用控件。不过在IE下img有几个附加的属性，如：fileCreatedDate、fileModifiedDate、fileSize、fileUpdatedDate、filters，我们可以通过这些属性来获取图片文件的部分信息，如文件大小，我们用file表单同img标签结合，就能够在上传之前判断图片文件的大小是否合法了。 限制：&#60;input type=&#34;text&#34; size=&#34;4&#34; value=&#34;10&#34; name=&#34;fileSizeLimit&#34; id=&#34;fileSizeLimit&#34;/&#62; K &#60;input&#160;type=&#34;file&#34; name=&#34;file1&#34; id=&#34;file1&#34; size=&#34;40&#34; onchange=&#34;changeSrc(this)&#34;/&#62; &#60;img&#160;src=&#34;about:blank&#34; id=&#34;fileChecker&#34; alt=&#34;test&#34;&#160; height=&#34;18&#34;/&#62; &#160; &#60;script&#160;type=&#34;text/javascript&#34;&#62; var oFileChecker = document.getElementById(&#34;fileChecker&#34;); &#160; function changeSrc(filePicker) { &#160; &#160; oFileChecker.src = filePicker.value; } &#160; oFileChecker.onreadystatechange = function () { &#160; &#160; if (oFileChecker.readyState == &#34;complete&#34;) &#160; &#160; { &#160; &#160; &#160; &#160; checkSize(); &#160; &#160; [...]]]></description>
		<wfw:commentRss>http://www.linuxany.com/archives/654.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

