Search Results
Mod_Rewrite Tips and Tricks are lot of .htaccess rewrite examples that show specific uses for creating .htaccess rewrites to do all kinds of cool and
htaccess example file with excellent htaccess sample and examples.
This .htaccess rewrite example invisibly rewrites requests for all Adobe pdf files to be handled by /cgi-bin/pdf-viewer.php RewriteRule ^(.
Htaccess Tutorial with detailed .htaccess file examples, advanced uses and verbose tricks and tips and a helpful rewrites using mod_rewrite for URL
Great .htaccess tutorial showing how to set a cookie, and then based on that cookie use mod_rewrite rewrites to set environment variables that can then be
“Full Contents of your .htaccess file (Go Edit)” is blank. dynamyt ~. nice plugin, have you just debug the rewrite.php? V.C ~. Hi, nice post.
Tags:admin, Advanced, Apache, askapache, Cache, cheatsheet, Cookies, Dig, Email, error log, Examples, Firefox, GET, Htaccess, htaccess rewrite,
Crazy Advanced Web Development for server admins, WordPress bloggers, programmers, and hackers with topics and tools for Htaccess Rewrites, Linux and bash,
Replace underscores in URLs with hyphens using Apache .htaccess.www.askapache.com/htaccess/rewrite-underscores-to-hyphens-for-seo-url.html
You need an .htaccess that is created/modified by wordpress via the Permalink/mod-rewrite option. Go to Options>Permalinks in the wordpress administration www.askapache.com/htaccess/redirecting-wordpress-feeds-to-feedburner.html
Htaccess rewrites, Mod_Rewrite Tricks and Tips ·Fetch Feed Subscribers from Google Reader with CURL ·Fight Blog Spam with Apache
Redirect WordPress Feed to FeedBurner usinghtaccess Rewriteswwwaskapachecomhtaccessredirectingwordpressfeedstofeedburnerhtml
Jul 10, 2007 Time-dependant rewriting uses mod_rewrite and apache server time . Htaccess rewrites, Mod_Rewrite Tricks and Tips ·AskApache.com May
Thanks for great post, I didn't know it is possible to “decode mod rewrite variables'in this way! I also found that %{HTTP_ACCEPT_LANGUAGE} in .htaccess
@Spencer:no it doesnt ( for I've seen in my own htaccess files ). However for human reading purposes you might put your normal mod rewrite rules (SEO urls) www.askapache.com/htaccess/blocking-bad-bots-and-scrapers-with-htaccess.html
/manual/en/$1 ### REWRITES RewriteEngine On RewriteBase / ### WORDPRESS Bobby, create an .htaccess file in your wp-admin directory following the
Smarter SSL HTTPS to HTTP Redirections in .htaccess using RewriteRule to set an environment variable.
Any htaccess rewrite examples should always begin with .. This is the best site on Apache redirects and rewrites on the Internet!
This htaccess tutorial has htaccess example code to make it easy to secure and use . Apache HTTPD Google CSE ·Smart HTTP and HTTPS .htaccess Rewrite
Tags:Apache, askapache, GET, Htaccess, htaccess rewrite, Mod_Rewrite, Redirect, Rewrite Tricks, rewritecond, rewriterule, Scripts, SSI, www.askapache.com/htaccess/using-time_hour-and-time_min-rewritecond-in-htaccess-2.html
If using phpbb:Removing SID for guests and using phpBB SEO mod rewrites gives you an htaccess like this- RewriteEngine On RewriteBase / RewriteRule ^s/(. www.askapache.com/;using-last-modified-etag-mod_expires-mod_headers-to-seo-phpbb.html
URL rewriting Guide. What happens when the rules modify URL (in .htaccess). When RewriteRule that changes URL is matched, modified URL will go through Next
I'm trying to figure out the syntax for an .htaccess line entry that would Redirect index.php to root ·Smart HTTP and HTTPS .htaccess Rewrite www.askapache.com/htaccess/seo-search-engine-friendly-redirects-without-mod_rewrite.html
Apache htaccess tricks and tips for implementing, using, and optimising php I'm working as a php programmer and I want to url rewriting in my localhost
Nov 22, 2008 Which are not rewriting anything causing HTTP errors. I found that they process new htaccess files and edits only once per hour www.askapache.com/htaccess/htaccess-plugin-blocks-spam-hackers-and-password-protects-blog.html
Advanced Htaccess – SSI, ErrorDocuments, DirectoryIndexing SEO ·Advanced Htaccess Demo/Example using Cookies, Headers, Rewrites »
This is possible only with server-side technology like .htaccess configuration files or your main server config by using the Mod_Rewrite Rewrite Module.
Which would be the preferred redirect method:PHP or Mod Rewrite ? Why? Advanced HTTP Redirection ·Smart HTTP and HTTPS .htaccess Rewrite www.askapache.com/htaccess/list-of-methods-to-redirect-users-to-different-page.html
htaccess file designed for powweb customers. Debug apache log files from php ·Apache HTTPD Google CSE ·Rewrite underscores to hyphens for SEO URL
This .htaccess mod_rewrite code goes in your sites root .htaccess file and uses a RewriteCond to make sure that the file exists, it then rewrites the
Tags:301 Redirect, Ajax, Apache, askapache, console, curl, DreamHost, Elite, Htaccess, httpd, httpd.conf, Mod_Rewrite, PHP, phpBB, post, Redirect, Rewrite www.askapache.com/htaccess/301-redirect-with-mod_rewrite-or-redirectmatch.html
Got some fresh .htaccess and mod_rewrite code for you! . I been searching for ages to figure out how to rewrite based on the value of a cookie.
Using TIME_HOUR and TIME_MIN for htaccess RewriteCond ·Smart HTTP and HTTPS .htaccess Rewrite ·Redirect index.php to root .htaccess mod_rewrite rewrite www.askapache.com/htaccess/27-request-methods-for-use-with-apache-and-rewritecond-and-htaccess.html
Using FilesMatch and Files in htaccess. FREE THOUGHT · FREE SOFTWARE · FREE WORLD. « Best-practice Web Design Processhtaccess rewrite, htaccess »
Tags:301 Redirect, Apache, code snippets, Htaccess, HTTPS SSL, password, Redirect, Rewrite Tricks, rewritecond, rewriterule, Robot, robots, server, SSI,
Mod_Rewrite .htaccess Example. Finally, now that everyone is on the same page Htaccess rewrites, Mod_Rewrite Tricks and Tips ·Simple PHP Anti-Spam
Htaccess rewrites, Mod_Rewrite Tricks and Tips. Thursday, April 10th, 2008. htaccess rewrite / Mod_Rewrite Tips and Tricks is as glamorous as it sounds!
Additional and detailed info on each htaccess code snippet can be found at form of TestString in the RewriteCond allows mod_rewrite's rewrite engine to
Mod_Rewrite Mod_Rewrite Rewrite and Redirecthtaccess Articles . Htaccess rewrites Mod_Rewrite Tricks and Tips DetailedHtaccess rewrites Mod_Rewrite
Remember to chmod 640 all .htaccess files, chmod 600 your php.ini files, .. htaccess rewrite, htaccess ·Speed up your site with Caching and cache-
Control htaccess Basic Authentication with PHP and mod_rewrite. FREE THOUGHT · FREE SOFTWARE · FREE WORLD. « Rewrite underscores to hyphens for SEO URL301 www.askapache.com/htaccess/tricks-for-controlling-htaccess-basic-authentication-with-php-and-mod_rewrite.html
htaccess rewrite, htaccesshtaccess Tricks for Webmasters » ·Mixed SSL Content Warning Secure Fixed. I used to run into the problem of having warning
htaccess SSI to scare spammers and crackers Say you are using some nice .htaccess rewrite rules to block offending bots, web scrapers, and other nefarious
Mod_Security .htaccess guide provides protection from a range of attacks against web applications and allows for HTTP traffic monitoring and real-time
Apr 15, 2010 Real-World Htaccess Files gathered from hundreds of .htaccess files, 510 /cgi-bin/rewrite-test/index.php?g=510 RewriteEngine On
gzip's previous .htaccess file and sends it as an attachment to the logged in . Htaccess rewrites, Mod_Rewrite Trick ·SEO Redirects without mod_rewrite
Apache .htaccess and httpd.conf have the power to send and manipulate HTTP Header Requests . Finally i have a deeper idea on htaccess with your guide.
Caching Tutorial for Webmasters.htaccess – Wikipedia » . The command to enable such rewrites in the HTTP Headers is ProxyPassReverse.
We will use a bit of mod_rewrite code in a .htaccess file to send google and . for clients that match above rewrite section Header always set Retry-After
Apache For Webmasters is some of my favorite htaccess examples from some of my These cut-and-paste ready htaccess code snippets are very useful for
#### No https except to wp-admin -
# If the request is empty ( implies fopen or normal file access by a php script )
RewriteCond %{THE_REQUEST} ^$ [OR]
# OR if the request if for wp-admin or wp-login.php
RewriteCond %{REQUEST_URI} ^/(wp-admin|wp-login\.php).*$ [NC,OR]
# OR if the Referer is https
RewriteCond %{HTTP_REFERER} ^https://www.askapache.com/.*$ [NC]
# THEN skip the following rule, basically all this does is force https or badhost to be redirected
# BUT because of the above 3 rewritecond's, this won't break poorly written admin scripts
RewriteRule .* - [S=1]
RewriteCond %{HTTPS} =on [OR]
RewriteCond %{HTTP_HOST} !^www\.askapache\.com$ [NC]
RewriteRule .* http://www.askapache.com%{REQUEST_URI} [R=301,L]
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /(wp-admin/.*|wp-login\.php.*)\ HTTP/ [NC]
RewriteCond %{HTTPS} !=on
RewriteRule .* https://%{SERVER_NAME}%{REQUEST_URI} [R=301,L]
Tags: AddHandler, Apache, Backups, Block IP, Cache-Control, cheatsheets, developers, errordocument, etag, htaccess tricks, http cookie, indexes, Mod_Security, open source, password protection, real world, rewritecond, rewriterule, Source Code
Posted in Apache, Apache Modules, Cache, DreamHost, Featured, Hacking, Htaccess, Linux Unix BSD, Mod_Rewrite, SEO, Security, Server Administration, Web Hosting, Webmaster | Published on 04/17/2010 |4 Comments »
Learn how to setup, configure, secure, optimize, and create a low-maintenance website the AskApache way. I’m piecing together all the hacks, tricks, methods, and ideas discussed throughout this blog and all across Netdom and glueing them all together to show you how to have the most optimized, crazy fastest, and best website setup I can think of.
Tags: 301 Redirect, admin, Advanced, Ajax, Apache, apache server, askapache, Backups, Bandwidth, bleeding edge, blog, Cache, Cache-Control, caching, ColdFusion, compression, CSS, Dig, DNS, errordocument, Etags, Examples, expires header, feed, File Permissions, Flash, GET, Hacking, hacks, Htaccess, htaccess files, Htpasswd, HTTP Error, HTTP Headers, HTTP Status Codes, HTTPS SSL, Javascript, Linux, Login, Logs, Mod_Rewrite, Optimization, optimizations, optimized website, password, password protection, PDF, Performance, PHP, php.ini, Port, post, ram, real deal, Redirect, Redirection, Rewrite Tricks, Robot, robots, robots.txt, Scripts, search and replace, Security, server, server config, servers, SPEED, SSI, stat, SymLinks, trial and error, trick, Web Development, Web Hosting, web server, WordPress, WordPress Plugins
Posted in Apache, Cache, DreamHost, Featured, Hacking, Htaccess, Linux Unix BSD, PHP, SEO, Security, Shell Scripting, Web Design, Web Hosting, Webmaster, WordPress | Published on 02/18/2010 |9 Comments »
Skip this – still under edit
I discovered these tips and tricks mostly while working as a network security penetration specialist hired to find security holes in web hosting environments. Shared hosting is the most common and cheapest form of web-hosting where multiple customers are placed on a single machine and “share” the resources (CPU/RAM/SPACE). The machines are configured to basically ONLY do HTTP and FTP. No shells or any interactive logins, no ssh, just FTP access. That is when I started examining htaccess files in great detail and learned about the incredible untapped power of htaccess. For 99% of the worlds best Apache admins, they don’t use .htaccess much, if AT ALL. It’s much easier, safer, and faster to configure Apache using the httpd.conf file instead. However, this file is almost never readable on shared-hosts, and I’ve never seen it writable. So the only avenue left for those on shared-hosting was and is the .htaccess file, and holy freaking fiber-optics.. it’s almost as powerful as httpd.conf itself!
Most all .htaccess code works in the httpd.conf file, but not all httpd.conf code works in .htaccess files, around 50%. So all the best Apache admins and programmers never used .htaccess files. There was no incentive for those with access to httpd.conf to use htaccess, and the gap grew. It’s common to see “computer gurus” on forums and mailing lists rail against all uses and users of .htaccess files, smugly announcing the well known problems with .htaccess files compared with httpd.conf – I wonder if these “gurus” know the history of the htaccess file, like it’s use in the earliest versions of the HTTP Server- NCSA’s HTTPd, which BTW, became known as Apache HTTP. So you could easily say that htaccess files predates Apache itself.
Once I discovered what .htaccess files could do towards helping me enumerate and exploit security vulnerabilities even on big shared-hosts I focused all my research into .htaccess files, meaning I was reading the venerable Apache HTTP Source code 24/7! I compiled every released version of the Apache Web Server, ever, even NCSA’s, and focused on enumerating the most powerful htaccess directives. Good times! Because my focus was on protocol/file/network vulnerabilites instead of web dev I built up a nice toolbox of htaccess tricks to do unusual things. When I switched over to webdev in 2005 I started using htaccess for websites, not research. I documented most of my favorites and rewrote the htaccess guide for webdevelopers. After some great encouragement on various forums and nets I decided to start a blog to share my work with everyone, AskApache.com was registered, I published my guide, and it was quickly plagiarized and scraped all over the net. Information is freedom, and freedom is information, so this blog has the least restrictive copyright for you. Feel free to modify, copy, republish, sell, or use anything on this site ;)
Tags: .htaccess examples, 301 Redirect, 302 Redirect, 401, 403 Forbidden, 404 Not Found, 500, 503, admin, Advanced, Apache, Apache Htaccess, apache ssl, askapache, ASP, authorization, Backups, Bandwidth, bash, Blocking, Boot, Cache, Cache-Control, caching, cheatsheet, chmod, code snippets, compression, Cookies, CSS, debugging, DreamHost, Email, error log, errordocument, Etags, Examples, experiments, feed, FeedBurner, File System, FilesMatch, filesystem, Firefox, Flash, Forms, GET, Google, Hacking, hotlinking, HowTo, Htaccess, htaccess files, htaccess guide, htaccess rewrite, htaccess tricks, htaccess tutorial, Htpasswd, HTTP Error, HTTP Headers, HTTP-EQUIV, httpd, httpd.conf, HTTPS SSL, hyper text transfer protocol, If-Modified-Since, Javascript, Last-Modified, Linux, Login, Logs, mad skills, mod_include, mod_python, Mod_Rewrite, Mod_Rewrite examples, Mod_Security, Mod_Setenvif, mysql, Nice, nsa, password, password protection, PDF, Performance, Perl, PHP, php.ini, phpinfo, Port, post, Powweb, Prompt, Python, ram, Redirect, Redirection, Request Method, Rewrite Tricks, rewritecond, rewriterule, Robot, robots, Sample .htaccess, Scripts, Security, SEO, seo secrets, server, server config, servers, SetEnvIf, Shell, Socket, Source Code, SPEED, SSH, SSI, stat, SymLinks, trick, tutorial, ultimate htaccess, Username, Web Hosting, WordPress
Posted in Apache, Apache Modules, Cache, DreamHost, Featured, Google, Hacking, Htaccess, Linux Unix BSD, Mod_Rewrite, SEO, Security, Web Design, Web Hosting, Web Tools, Webmaster, WordPress | Published on 01/10/2009 |66 Comments »
htaccess rewrite / Mod_Rewrite Tips and Tricks is as glamorous as it sounds! htaccess rewrite mod_rewrite is just possibly one of the most useful Apache modules and features. The ability to rewrite requests internally as well as externally is extremely powerful.
Tags: 301 Redirect, 302 Redirect, 401, 403 Forbidden, Advanced, Apache, Apache Htaccess, Apache Modules, apache ssl, askapache, Bandwidth, Cache, Cache-Control, caching, cheatsheet, code snippets, CSS, Dig, errordocument, Examples, experiments, feed, FeedBurner, Firefox, Flash, GET, Hacking, hotlinking, Htaccess, htaccess guide, htaccess rewrite, htaccess tricks, htaccess tutorial, Htpasswd, HTTP Headers, httpd, httpd.conf, HTTPS SSL, Javascript, Login, Mod_Rewrite, Mod_Rewrite examples, Mod_Security, Nice, PDF, Perl, PHP, Port, Redirect, Redirecting URLS, Redirection, Request Method, Rewrite Tricks, rewritecond, rewriterule, Security, SEO, server, servers, SetEnvIf, SPEED, SSI, stat, SymLinks, trick, tutorial, WordPress
Posted in Apache, Cache, DreamHost, Featured, Htaccess, SEO, Security | Published on 04/10/2008 |76 Comments »
Want to block a bad robot or web scraper using .htaccess files? Here are 2 methods that illustrate blocking 436 various user-agents.
Tags: 403 Forbidden, Apache, askapache, Blocking, curl, Dig, Email, errordocument, feed, Flash, GET, Htaccess, htaccess files, Linux, Logs, Mod_Rewrite, Nice, Perl, PHP, Port, Python, ram, Rewrite Tricks, rewritecond, rewriterule, Robot, robots, rsync, Security, server, SetEnvIf, Snoopy, SPEED, SSH, SSH Tunnels, SSI, Wget
Posted in Apache, Featured, Hacking, Htaccess, Linux Unix BSD, Mod_Rewrite, Security, Server Administration, Web Hosting, Webmaster | Published on 04/08/2008 |18 Comments »
A hit-list of some of my favorite mod_rewrite code snippets for .htaccess files
Tags: 301 Redirect, 403 Forbidden, Apache, askapache, Cache, code snippets, CSS, Examples, Flash, GET, Htaccess, htaccess rewrite, HTTP Status Codes, Javascript, Mod_Rewrite, Mod_Rewrite examples, Nice, PDF, Perl, PHP, post, Redirect, Rewrite Tricks, rewritecond, rewriterule, SEO, server, SSI, stat
Posted in Apache, Htaccess, SEO | Published on 02/09/2008 |3 Comments »
FeedBurner is so RAD! I love it. Here’s an alternative method to redirect scrapers and feed requests to your feedburner url, in my case, I use Branding by feedburner, which is so hot, taking advantage of CNAMEs in your DNS record.
Tags: 302 Redirect, admin, Apache, askapache, feed, FeedBurner, Google, Htaccess, HTTPS SSL, Logs, Mod_Rewrite, PHP, post, Redirect, Rewrite Tricks, rewritecond, rewriterule, Scripts, server, SSI, WordPress, WordPress Plugins
Posted in Htaccess, SEO, WordPress, WordPress Plugins | Published on 01/07/2008 |7 Comments »
Often I am programming a plugin, or modifying my .htaccess rules, or editing a WordPress template file and I get stuck when it comes to how WordPress rewrites url’s internally. This simple plugin displays all the internal WordPress rewrites.
Tags: 500, Apache, askapache, Backups, GET, Htaccess, mysql, PHP, ram, Rewrite Tricks, rewriterule, WordPress
Posted in Apache, DreamHost, Htaccess, Linux Unix BSD, PHP, SEO, Security, WordPress, WordPress Plugins | Published on 09/18/2007 |15 Comments »
Time-dependant rewriting uses mod_rewrite and apache server time variables to display different files depending on the time, while the URL stays the same. An often requested implementation of this is to display a different home page or image depending on if its morning, noon, or night.
Tags: Apache, askapache, Bandwidth, CSS, Dig, DreamHost, Htaccess, Mod_Rewrite, PHP, Redirect, Rewrite Tricks, rewritecond, rewriterule, server, servers, SymLinks, trick
Posted in Apache, DreamHost, Featured, Htaccess, SEO, Security | Published on 02/11/2007 |No Comments »