<?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>PHP Freelancer &#187; Javascript</title>
	<atom:link href="http://php-freelancer.in/category/javascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://php-freelancer.in</link>
	<description></description>
	<lastBuildDate>Mon, 30 Jan 2012 13:31:07 +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>How To Mobile Redirect Your Website On Any Mobile Device</title>
		<link>http://php-freelancer.in/2011/02/11/how-to-mobile-redirect-your-website-on-any-mobile-device/</link>
		<comments>http://php-freelancer.in/2011/02/11/how-to-mobile-redirect-your-website-on-any-mobile-device/#comments</comments>
		<pubDate>Fri, 11 Feb 2011 17:30:49 +0000</pubDate>
		<dc:creator>Ankur</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Mobile Redirect]]></category>
		<category><![CDATA[Mobile Redirect With Javascript]]></category>
		<category><![CDATA[Mobile Redirection]]></category>

		<guid isPermaLink="false">http://php-freelancer.in/?p=220</guid>
		<description><![CDATA[Hello Friends, after long time I am writing post. So today I am writing about one new topic in which I will show you how can we redirect our website to mobile website when it opened from any mobile device. I have done this thing already in one of my client website and this code &#8230; <a href="http://php-freelancer.in/2011/02/11/how-to-mobile-redirect-your-website-on-any-mobile-device/">Read more <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hello Friends, after long time I am writing post. So today I am writing about one new topic in which I will show you how can we redirect our website to mobile website when it opened from any mobile device. I have done this thing already in one of my client website and this code worked properly. This code is in javascript. We can make code in PHP also, but right now I am just writing you code for JavaScript. Might be I will post code in PHP in next post<span id="more-220"></span>.</p>
<p>So below is the code for mobile redirection to mobile website on any mobile device.</p>
<pre class="brush: jscript; title: ; notranslate">
&lt;script language=javascript&gt;
&lt;!--
var redirectagent = navigator.userAgent.toLowerCase();
var redirect_devices = ['vnd.wap.xhtml+xml', 'sony', 'symbian', 'nokia', 'samsung', 'mobile', 'windows ce', 'epoc', 'opera mini', 'nitro', 'j2me', 'midp-', 'cldc-', 'netfront', 'mot', 'up.browser', 'up.link', 'audiovox', 'blackberry', 'ericsson', 'panasonic', 'philips', 'sanyo', 'sharp', 'sie-', 'portalmmm', 'blazer', 'avantgo', 'danger', 'palm', 'series60', 'palmsource', 'pocketpc', 'smartphone', 'rover', 'ipaq', 'au-mic', 'alcatel', 'ericy', 'vodafone', 'wap1', 'wap2', 'teleca', 'playstation', 'lge', 'lg-', 'iphone', 'android', 'htc', 'dream', 'webos', 'bolt', 'nintendo'];
for (var i in redirect_devices) {
if (redirectagent.indexOf(redirect_devices[i]) != -1) {
location.replace(&quot;http://mymobilewebsite.mobi/&quot;);
}
}
--&gt;
&lt;/script&gt;
</pre>
<div id="in_post_ad_middle_1" style="text-align:center;margin: 5px;padding: 0px;"><script type="text/javascript"><!--
google_ad_client = "ca-pub-8444019803708971";
/* Middleofpost */
google_ad_slot = "5399229243";
google_ad_width = 336;
google_ad_height = 280;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></div><p>So above is the code which you should put at top of your website page, So when your website will  open in any mobile browser, it will redirect you to your mobile website (in above code http://mymobilewebsite.mobi).</p>
<p>Let me know if you have any problem in using this code.</p>
<p>I am PHP freelancer , So <a href="http://php-freelancer.in/contact-me/" class="kblinker" title="More about contact me &raquo;">Contact me</a> if you are interested to develop  any website.</p>
<div style='clear:both'></div>]]></content:encoded>
			<wfw:commentRss>http://php-freelancer.in/2011/02/11/how-to-mobile-redirect-your-website-on-any-mobile-device/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Convert Javascript Array To String</title>
		<link>http://php-freelancer.in/2010/07/08/how-to-convert-javascript-array-to-string/</link>
		<comments>http://php-freelancer.in/2010/07/08/how-to-convert-javascript-array-to-string/#comments</comments>
		<pubDate>Thu, 08 Jul 2010 07:13:24 +0000</pubDate>
		<dc:creator>Ankur</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Convert Javascript array to String]]></category>

		<guid isPermaLink="false">http://php-freelancer.in/?p=126</guid>
		<description><![CDATA[Hi Friends, In last article I have explained that how can we get checked check box values by jquery in array. Now if we want to convert that javascript array to string to use it in php So there is very simple way to do this. We can&#8217;t use js array in PHP as PHP &#8230; <a href="http://php-freelancer.in/2010/07/08/how-to-convert-javascript-array-to-string/">Read more <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hi Friends, In last article I have explained that how can we get checked check box values by jquery in array. Now if we want to convert that javascript array to string to use it in php So there is very simple way to do this. We can&#8217;t use js array in PHP as PHP array so we can convert it to string and then use that string in php<span id="more-126"></span>.</p>
<p>Suppose for example exclude_category is javascript array which we want to convert in string to use it in PHP, So below is the way by which we can do it</p>
<div id="in_post_ad_middle_1" style="text-align:center;margin: 5px;padding: 0px;"><script type="text/javascript"><!--
google_ad_client = "ca-pub-8444019803708971";
/* Middleofpost */
google_ad_slot = "5399229243";
google_ad_width = 336;
google_ad_height = 280;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></div><p><code>var arv = exclude_category.toString();</code></p>
<p>toString is js function by which we can convert any js array to string. So now in arv we will get converted string from js array. let me know if you need any help in this.</p>
<div style='clear:both'></div>]]></content:encoded>
			<wfw:commentRss>http://php-freelancer.in/2010/07/08/how-to-convert-javascript-array-to-string/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced

Served from: php-freelancer.in @ 2012-02-06 21:33:08 -->
