<?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>apache Архиви - rosen4o.net</title>
	<atom:link href="https://rosen4o.net/tag/apache/feed/" rel="self" type="application/rss+xml" />
	<link>https://rosen4o.net/tag/apache/</link>
	<description></description>
	<lastBuildDate>Fri, 14 Oct 2016 11:28:50 +0000</lastBuildDate>
	<language>bg-BG</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9</generator>
	<item>
		<title>Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource</title>
		<link>https://rosen4o.net/2016/10/14/cross-origin-request-blocked-the-same-origin-policy-disallows-reading-the-remote-resource/</link>
					<comments>https://rosen4o.net/2016/10/14/cross-origin-request-blocked-the-same-origin-policy-disallows-reading-the-remote-resource/#respond</comments>
		
		<dc:creator><![CDATA[rosen4o]]></dc:creator>
		<pubDate>Fri, 14 Oct 2016 11:28:50 +0000</pubDate>
				<category><![CDATA[Joomla]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[htaccess]]></category>
		<category><![CDATA[http]]></category>
		<category><![CDATA[httpd]]></category>
		<category><![CDATA[rewrite]]></category>
		<guid isPermaLink="false">http://rosen4o.net/?p=1075</guid>

					<description><![CDATA[<p>If you have following error Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at Then you need to add some lines to your .htaccess file &#60;IfModule mod_rewrite.c&#62; RewriteEngine On RewriteBase / Header add Access-Control-Allow-Origin &#8222;*&#8220; Header<span class="ellipsis">&#8230;</span></p>
<div class="read-more"><a href="https://rosen4o.net/2016/10/14/cross-origin-request-blocked-the-same-origin-policy-disallows-reading-the-remote-resource/">Прочетете повече ›</a></div>
<p><!-- end of .read-more --></p>
<p>Материалът <a href="https://rosen4o.net/2016/10/14/cross-origin-request-blocked-the-same-origin-policy-disallows-reading-the-remote-resource/">Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>If you have following error</p>
<p>Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at</p>
<p>Then you need to add some lines to your .htaccess file</p>
<blockquote><p>&lt;IfModule mod_rewrite.c&gt;<br />
RewriteEngine On<br />
RewriteBase /</p>
<p><strong>Header add Access-Control-Allow-Origin &#8222;*&#8220;</strong><br />
<strong>Header add Access-Control-Allow-Headers &#8222;origin, x-requested-with, content-type&#8220;</strong><br />
<strong>Header add Access-Control-Allow-Methods &#8222;PUT, GET, POST, DELETE, OPTIONS&#8220;</strong></p>
<p>RewriteRule ^index\.php$ &#8211; [L]<br />
RewriteCond %{REQUEST_FILENAME} !-f<br />
RewriteCond %{REQUEST_FILENAME} !-d<br />
RewriteRule . /index.php [L]<br />
&lt;/IfModule&gt;</p></blockquote>
<p>Материалът <a href="https://rosen4o.net/2016/10/14/cross-origin-request-blocked-the-same-origin-policy-disallows-reading-the-remote-resource/">Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rosen4o.net/2016/10/14/cross-origin-request-blocked-the-same-origin-policy-disallows-reading-the-remote-resource/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Redirect all php files to wordpress posts or strip .php extension</title>
		<link>https://rosen4o.net/2016/05/30/redirect-all-php-files-to-wordpress-posts-or-strip-php-extension/</link>
					<comments>https://rosen4o.net/2016/05/30/redirect-all-php-files-to-wordpress-posts-or-strip-php-extension/#respond</comments>
		
		<dc:creator><![CDATA[rosen4o]]></dc:creator>
		<pubDate>Mon, 30 May 2016 15:08:52 +0000</pubDate>
				<category><![CDATA[wordpress]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[htaccess]]></category>
		<category><![CDATA[redirect]]></category>
		<guid isPermaLink="false">http://rosen4o.net/?p=1059</guid>

					<description><![CDATA[<p>If you need to redirect your old urls which are like alabala.com/see-this-post.php to alabala.com/see-this-post/ You can use this simple .htaccess redirect RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)\.php$ /$1/ [l,R=301,NC]</p>
<p>Материалът <a href="https://rosen4o.net/2016/05/30/redirect-all-php-files-to-wordpress-posts-or-strip-php-extension/">Redirect all php files to wordpress posts or strip .php extension</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>If you need to redirect your old urls which are like</p>
<blockquote><p>alabala.com/see-this-post.php to alabala.com/see-this-post/</p></blockquote>
<p>You can use this simple .htaccess redirect</p>
<blockquote><p>
RewriteEngine On<br />
RewriteCond %{REQUEST_FILENAME} !-f<br />
RewriteRule ^(.*)\.php$ /$1/ [l,R=301,NC]</p></blockquote>
<p>Материалът <a href="https://rosen4o.net/2016/05/30/redirect-all-php-files-to-wordpress-posts-or-strip-php-extension/">Redirect all php files to wordpress posts or strip .php extension</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rosen4o.net/2016/05/30/redirect-all-php-files-to-wordpress-posts-or-strip-php-extension/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>catch spam from apache</title>
		<link>https://rosen4o.net/2014/05/20/catch-spam-from-apache/</link>
					<comments>https://rosen4o.net/2014/05/20/catch-spam-from-apache/#respond</comments>
		
		<dc:creator><![CDATA[rosen4o]]></dc:creator>
		<pubDate>Tue, 20 May 2014 08:53:53 +0000</pubDate>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[postfix]]></category>
		<category><![CDATA[qmail]]></category>
		<category><![CDATA[sendmail]]></category>
		<category><![CDATA[spam]]></category>
		<guid isPermaLink="false">http://rosen4o.net/?p=1006</guid>

					<description><![CDATA[<p>Sometimes is very hard to debug from which virtual host spam is This can be check very easy with this trick create a new file  vim /usr/local/bin/phpsendmail place inside it #!/usr/bin/php &#60;?php $sendmail = &#8216;/usr/sbin/sendmail&#8217;; $logfile = &#8216;/var/log/mail.form&#8217;; /* Get<span class="ellipsis">&#8230;</span></p>
<div class="read-more"><a href="https://rosen4o.net/2014/05/20/catch-spam-from-apache/">Прочетете повече ›</a></div>
<p><!-- end of .read-more --></p>
<p>Материалът <a href="https://rosen4o.net/2014/05/20/catch-spam-from-apache/">catch spam from apache</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Sometimes is very hard to debug from which virtual host spam is<br />
This can be check very easy with this trick</p>
<p>create a new file</p>
<p style="padding-left: 30px;"> <strong>vim /usr/local/bin/phpsendmail</strong></p>
<p>place inside it</p>
<p style="padding-left: 30px;"><strong>#!/usr/bin/php</strong><br />
<strong> &lt;?php</strong></p>
<p style="padding-left: 30px;"><strong>$sendmail = &#8216;/usr/sbin/sendmail&#8217;;</strong><br />
<strong> $logfile = &#8216;/var/log/mail.form&#8217;;</strong></p>
<p style="padding-left: 30px;"><strong>/* Get email content */</strong><br />
<strong> $logline = &#8220;;</strong><br />
<strong> $mail = &#8220;;</strong><br />
<strong> $fp = fopen(&#8216;php://stdin&#8217;, &#8216;r&#8217;);</strong></p>
<p style="padding-left: 30px;"><strong>while ($line = fgets($fp))</strong><br />
<strong> {</strong><br />
<strong> if(preg_match(&#8216;/^to:/i&#8217;, $line) || preg_match(&#8216;/^from:/i&#8217;, $line))</strong><br />
<strong> {</strong><br />
<strong> $logline .= trim($line).&#8217; &#8216;;</strong><br />
<strong> }</strong><br />
<strong> $mail .= $line;</strong><br />
<strong> }</strong></p>
<p style="padding-left: 30px;"><strong>/* Build sendmail command */</strong><br />
<strong> $cmd = &#8216;echo &#8216; . escapeshellarg($mail) . &#8216; | &#8216;.$sendmail.&#8217; -t -i&#8217;;</strong><br />
<strong> for ($i = 1; $i &lt; $_SERVER[&#8216;argc&#8217;]; $i++)</strong><br />
<strong> {</strong><br />
<strong> $cmd .= escapeshellarg($_SERVER[&#8216;argv&#8217;][$i]).&#8217; &#8216;;</strong><br />
<strong> }</strong></p>
<p style="padding-left: 30px;"><strong>/* Log line */</strong><br />
<strong> $path = isset($_ENV[&#8216;PWD&#8217;]) ? $_ENV[&#8216;PWD&#8217;] : $_SERVER[&#8216;PWD&#8217;];</strong><br />
<strong> file_put_contents($logfile, date(&#8216;Y-m-d H:i:s&#8217;) . &#8216; &#8216; . $logline .&#8217;  ==&gt; &#8216; .$path.&#8220;\n&#8220;, FILE_APPEND);</strong></p>
<p style="padding-left: 30px;"><strong>/* Call sendmail */</strong><br />
<strong> return shell_exec($cmd);</strong><br />
<strong> ?&gt;</strong></p>
<p>Then you need to make it executable</p>
<p style="padding-left: 30px;"><strong>chmod +x /usr/local/bin/phpsendmail</strong></p>
<p style="padding-left: 30px;"><strong>touch /var/log/mail.form</strong></p>
<p style="padding-left: 30px;"><strong>chmod a+w /var/log/mail.form</strong></p>
<p>In your php.ini file you need to add</p>
<p style="padding-left: 30px;"><strong>sendmail_path = /usr/local/bin/phpsendmail</strong></p>
<p>Restart apache</p>
<p>This will cause all emails which are send from apache to be logged in the file /var/log/mail.form</p>
<p>Материалът <a href="https://rosen4o.net/2014/05/20/catch-spam-from-apache/">catch spam from apache</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rosen4o.net/2014/05/20/catch-spam-from-apache/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>php post with big array</title>
		<link>https://rosen4o.net/2013/08/21/php-post-with-big-array/</link>
					<comments>https://rosen4o.net/2013/08/21/php-post-with-big-array/#respond</comments>
		
		<dc:creator><![CDATA[rosen4o]]></dc:creator>
		<pubDate>Wed, 21 Aug 2013 07:40:55 +0000</pubDate>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[limit]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[post]]></category>
		<guid isPermaLink="false">http://rosen4o.net/?p=940</guid>

					<description><![CDATA[<p>Starting from php 5.3.9 there is brand new config option max_input_vars which is limiting the input variables to posted arrays and etc. max_input_vars integer How many input variables may be accepted (limit is applied to $_GET, $_POST and $_COOKIE superglobal<span class="ellipsis">&#8230;</span></p>
<div class="read-more"><a href="https://rosen4o.net/2013/08/21/php-post-with-big-array/">Прочетете повече ›</a></div>
<p><!-- end of .read-more --></p>
<p>Материалът <a href="https://rosen4o.net/2013/08/21/php-post-with-big-array/">php post with big array</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Starting from php 5.3.9 there is brand new config option <strong><code>max_input_vars </code></strong>which is limiting the input variables to posted arrays and etc.</p>
<dl>
<dt id="ini.max-input-vars"><em><code>max_input_vars</code></em> <a href="http://www.php.net/manual/en/language.types.integer.php">integer</a></dt>
<dd>How many <a href="http://www.php.net/manual/en/language.variables.external.php">input variables</a> may be accepted (limit is applied to $_GET, $_POST and $_COOKIE superglobal separately). Use of this directive mitigates the possibility of denial of service attacks which use hash collisions. If there are more input variables than specified by this directive, an <strong><code>E_WARNING</code></strong> is issued, and further input variables are truncated from the request. This limit applies only to each nesting level of a multi-dimensional input array.</p>
</dd>
</dl>
<p>Default value is 1000, to set different value you need to add to your <strong>php.ini</strong></p>
<p style="padding-left: 30px;"><strong><code> max_input_vars = 3000</code></strong></p>
<p>Материалът <a href="https://rosen4o.net/2013/08/21/php-post-with-big-array/">php post with big array</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rosen4o.net/2013/08/21/php-post-with-big-array/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>mod_evastive</title>
		<link>https://rosen4o.net/2012/12/11/mod_evastive/</link>
					<comments>https://rosen4o.net/2012/12/11/mod_evastive/#respond</comments>
		
		<dc:creator><![CDATA[rosen4o]]></dc:creator>
		<pubDate>Tue, 11 Dec 2012 17:06:43 +0000</pubDate>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[DOS]]></category>
		<category><![CDATA[httpd]]></category>
		<category><![CDATA[mod_evastive]]></category>
		<guid isPermaLink="false">http://rosen4o.net/?p=884</guid>

					<description><![CDATA[<p>cd /usr/local/src Download the module wget http://www.zdziarski.com/blog/wp-content/uploads/2010/02/mod_evasive_1.10.1.tar.gz Untar tar zxvf mod_evasive_1.10.1.tar.gz Go to the folder cd mod_evasive Compile it /usr/sbin/apxs -cia mod_evasive20.c Add to apache config file /etc/httpd/conf/httpd.conf &#60;IfModule mod_evasive20.c&#62; DOSHashTableSize 3097 DOSPageCount 6 DOSSiteCount 100 DOSPageInterval 2 DOSSiteInterval 2<span class="ellipsis">&#8230;</span></p>
<div class="read-more"><a href="https://rosen4o.net/2012/12/11/mod_evastive/">Прочетете повече ›</a></div>
<p><!-- end of .read-more --></p>
<p>Материалът <a href="https://rosen4o.net/2012/12/11/mod_evastive/">mod_evastive</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>cd /usr/local/src</p>
<p><strong><em>Download the module</em></strong><br />
wget http://www.zdziarski.com/blog/wp-content/uploads/2010/02/mod_evasive_1.10.1.tar.gz</p>
<p><em><strong>Untar </strong></em><br />
tar zxvf mod_evasive_1.10.1.tar.gz</p>
<p><em><strong>Go to the folder</strong></em><br />
cd mod_evasive</p>
<p><em><strong>Compile it</strong></em><br />
/usr/sbin/apxs -cia mod_evasive20.c</p>
<p><strong><em>Add to apache config file</em></strong><br />
/etc/httpd/conf/httpd.conf</p>
<p>&lt;IfModule mod_evasive20.c&gt;<br />
DOSHashTableSize 3097<br />
DOSPageCount 6<br />
DOSSiteCount 100<br />
DOSPageInterval 2<br />
DOSSiteInterval 2<br />
DOSBlockingPeriod 600<br />
DOSEmailNotify root@domain<br />
&lt;/IfModule&gt;</p>
<p><strong><em>Restart apache</em></strong><br />
/etc/init.d/httpd restart</p>
<p><strong><em>You can test the modules with</em></strong><br />
perl test.pl</p>
<p>Материалът <a href="https://rosen4o.net/2012/12/11/mod_evastive/">mod_evastive</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rosen4o.net/2012/12/11/mod_evastive/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>perl buffering</title>
		<link>https://rosen4o.net/2010/09/25/perl-buffering/</link>
					<comments>https://rosen4o.net/2010/09/25/perl-buffering/#respond</comments>
		
		<dc:creator><![CDATA[rosen4o]]></dc:creator>
		<pubDate>Sat, 25 Sep 2010 17:21:58 +0000</pubDate>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[buffering]]></category>
		<category><![CDATA[cgi-bin]]></category>
		<category><![CDATA[deflate]]></category>
		<category><![CDATA[perl]]></category>
		<guid isPermaLink="false">http://rosen4o.net/?p=722</guid>

					<description><![CDATA[<p>Срещнах проблем с буферирането на данни от perl когато го използвам като cgi приложение. Това се решава много просто като се изключи модула deflate в конфигурацията на Apache 2. Disabling deflate in Apache worked, just as you described. I wish<span class="ellipsis">&#8230;</span></p>
<div class="read-more"><a href="https://rosen4o.net/2010/09/25/perl-buffering/">Прочетете повече ›</a></div>
<p><!-- end of .read-more --></p>
<p>Материалът <a href="https://rosen4o.net/2010/09/25/perl-buffering/">perl buffering</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Срещнах проблем с буферирането на данни от perl когато го използвам като cgi приложение. Това се решава много просто като се изключи модула deflate в конфигурацията на Apache 2.</p>
<blockquote><p>Disabling deflate in Apache worked, just as you described.  I wish this were in the Apache2 FAQ.  Thanks for sharing that.</p></blockquote>
<p>Материалът <a href="https://rosen4o.net/2010/09/25/perl-buffering/">perl buffering</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rosen4o.net/2010/09/25/perl-buffering/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>plesk +FollowSymLinks</title>
		<link>https://rosen4o.net/2010/01/19/plesk-followsymlinks/</link>
					<comments>https://rosen4o.net/2010/01/19/plesk-followsymlinks/#respond</comments>
		
		<dc:creator><![CDATA[rosen4o]]></dc:creator>
		<pubDate>Tue, 19 Jan 2010 20:19:09 +0000</pubDate>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[httpd]]></category>
		<category><![CDATA[plesk]]></category>
		<guid isPermaLink="false">http://rosen4o.net/?p=677</guid>

					<description><![CDATA[<p>Много просто просто създаваме един .htaccess файл в главната директория на домейна и поставяме в него Options +FollowSymLinks</p>
<p>Материалът <a href="https://rosen4o.net/2010/01/19/plesk-followsymlinks/">plesk +FollowSymLinks</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Много просто просто създаваме един <strong>.htaccess</strong> файл в главната директория на домейна и поставяме в него</p>
<p><strong>Options +FollowSymLinks</strong></p>
<p>Материалът <a href="https://rosen4o.net/2010/01/19/plesk-followsymlinks/">plesk +FollowSymLinks</a> е публикуван за пръв път на <a href="https://rosen4o.net">rosen4o.net</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rosen4o.net/2010/01/19/plesk-followsymlinks/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
