Search Results

Search found 5181 results on 208 pages for '301 redirect'.

Page 12/208 | < Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >

  • tracking 301 redirects with awstats

    - by ceejayoz
    I'd like to use awstats to track usage of a URL shortener I'm using. Unfortunately, awstats treats log records with a non 200 status as an error, and excludes them from statistics. Is there a way to get awstats to treat 301s as 200s for stats tracking?

    Read the article

  • Apache2 - mod_expire and mod_rewrite not working in httpd.conf - serving content from tomcat

    - by Ankit Agrawal
    Hi, I am using apache2 server running on debian which forwards all the http request to tomcat installed on same machine. I have two files under my /etc/apache2/ folder apache2.conf and httpd.conf I modified httpd.conf file to look like following. # forward all http request on port 80 to tomcat ProxyPass / ajp://127.0.0.1:8009/ ProxyPassReverse / ajp://127.0.0.1:8009/ # gzip text content AddOutputFilterByType DEFLATE text/plain AddOutputFilterByType DEFLATE text/html AddOutputFilterByType DEFLATE text/xml AddOutputFilterByType DEFLATE text/css AddOutputFilterByType DEFLATE text/javascript AddOutputFilterByType DEFLATE application/xml AddOutputFilterByType DEFLATE application/xhtml+xml AddOutputFilterByType DEFLATE application/rss+xml AddOutputFilterByType DEFLATE application/javascript AddOutputFilterByType DEFLATE application/x-javascript DeflateCompressionLevel 9 BrowserMatch ^Mozilla/4 gzip-only-text/html BrowserMatch ^Mozilla/4\.0[678] no-gzip BrowserMatch \bMSIE !no-gzip !gzip-only-text/html # Turn on Expires and mark all static content to expire in a week # unset last modified and ETag ExpiresActive On ExpiresDefault A0 <FilesMatch "\.(jpg|jpeg|png|gif|js|css|ico)$" ExpiresDefault A604800 Header unset Last-Modified Header unset ETag FileETag None Header append Cache-Control "max-age=604800, public" </FilesMatch RewriteEngine On # rewrite all www.example.com/content/XXX-01.js and YYY-01.css files to XXX.js and YYY.css RewriteRule ^content/(js|css)/([a-z]+)-([0-9]+)\.(js|css)$ /content/$1/$2.$4 # remove all query parameters from URL after we are done with it RewriteCond %{THE_REQUEST} ^GET\ /.*\;.*\ HTTP/ RewriteCond %{QUERY_STRING} !^$ RewriteRule .* http://example.com%{REQUEST_URI}? [R=301,L] # rewrite all www.example.com to example.com RewriteCond %{HTTP_HOST} ^www\.example\.com$ [NC] RewriteRule ^(.*)$ http://example.com/$1 [R=301,L] I want to achieve following. forward all traffic to tomcat GZIP all the text content. Put 1 week expiry header to all static files and unset ETag/last modified header. rewrite all js and css file to certain format. remove all the query parameters from URL forward all www.example.com to example.com The problem is only 1 and 2 are working. I tried a lot with many combinations but the expire and rewrite rule (3-6) do not work at all. I also tried moving these rules to apache2.conf and .htaccess files but it didn't work either. It does not give any error but these rules are simple ignored. expires and rewrite modules are ENABLED. Please let me know what should I do to fix this. 1. Do I need to add something else in httpd.conf file (like Options +FollowSymLink) or something else? 2. Do I need to add something in apache2.conf file? 3. Do I need to move these rules to .htaccess file? If yes, what should I write in that file and where should I keep that file? in /etc/apache2/ folder or /var/www/ folder? 4. Any other info to make this work? Thanks, Ankit

    Read the article

  • Apache2 - mod_expire and mod_rewrite not working in httpd.conf - serving content from tomcat

    - by Ankit Agrawal
    I am using apache2 server running on debian which forwards all the http request to tomcat installed on same machine. I have two files under my /etc/apache2/ folder apache2.conf and httpd.conf I modified httpd.conf file to look like following. # forward all http request on port 80 to tomcat ProxyPass / ajp://127.0.0.1:8009/ ProxyPassReverse / ajp://127.0.0.1:8009/ # gzip text content AddOutputFilterByType DEFLATE text/plain AddOutputFilterByType DEFLATE text/html AddOutputFilterByType DEFLATE text/xml AddOutputFilterByType DEFLATE text/css AddOutputFilterByType DEFLATE text/javascript AddOutputFilterByType DEFLATE application/xml AddOutputFilterByType DEFLATE application/xhtml+xml AddOutputFilterByType DEFLATE application/rss+xml AddOutputFilterByType DEFLATE application/javascript AddOutputFilterByType DEFLATE application/x-javascript DeflateCompressionLevel 9 BrowserMatch ^Mozilla/4 gzip-only-text/html BrowserMatch ^Mozilla/4\.0[678] no-gzip BrowserMatch \bMSIE !no-gzip !gzip-only-text/html # Turn on Expires and mark all static content to expire in a week # unset last modified and ETag ExpiresActive On ExpiresDefault A0 <FilesMatch "\.(jpg|jpeg|png|gif|js|css|ico)$" ExpiresDefault A604800 Header unset Last-Modified Header unset ETag FileETag None Header append Cache-Control "max-age=604800, public" </FilesMatch RewriteEngine On # rewrite all www.example.com/content/XXX-01.js and YYY-01.css files to XXX.js and YYY.css RewriteRule ^content/(js|css)/([a-z]+)-([0-9]+)\.(js|css)$ /content/$1/$2.$4 # remove all query parameters from URL after we are done with it RewriteCond %{THE_REQUEST} ^GET\ /.*\;.*\ HTTP/ RewriteCond %{QUERY_STRING} !^$ RewriteRule .* http://example.com%{REQUEST_URI}? [R=301,L] # rewrite all www.example.com to example.com RewriteCond %{HTTP_HOST} ^www\.example\.com$ [NC] RewriteRule ^(.*)$ http://example.com/$1 [R=301,L] I want to achieve following. forward all traffic to tomcat GZIP all the text content. Put 1 week expiry header to all static files and unset ETag/last modified header. rewrite all js and css file to certain format. remove all the query parameters from URL forward all www.example.com to example.com The problem is only 1 and 2 are working. I tried a lot with many combinations but the expire and rewrite rule (3-6) do not work at all. I also tried moving these rules to apache2.conf and .htaccess files but it didn't work either. It does not give any error but these rules are simple ignored. expires and rewrite modules are ENABLED. Please let me know what should I do to fix this. 1. Do I need to add something else in httpd.conf file (like Options +FollowSymLink) or something else? 2. Do I need to add something in apache2.conf file? 3. Do I need to move these rules to .htaccess file? If yes, what should I write in that file and where should I keep that file? in /etc/apache2/ folder or /var/www/ folder? 4. Any other info to make this work? Thanks, Ankit

    Read the article

  • point multiple domain to single web hosting account

    - by suriyan suresh
    point multiple domain to single web hosting account using htaccess i have used the following .htaccess file in my public_html directory RewriteEngine on RewriteCond %{HTTP_HOST} ^site1.org$ [OR] RewriteCond %{HTTP_HOST} ^www.site1.org$ RewriteRule ^/?$ "/site1.org\/" [R=301,L] directory structure /public_html/site1.org/welcome.html if i typed site1.org redirection works perfect but the URL will be http://site1.org/site1.org/welcome.html instead of http://site1.org/welcome.html and the URL will be SEO Friendly

    Read the article

  • htaccess redirect problem

    - by jimbo
    Hi all, I am currently building a site and want to hide all development work on the site. I am using a htaccess file and redirecting to my holding page index.php?id=7: Options +FollowSymlinks RewriteCond %{REQUEST_URI} !/index.php RewriteCond %{REQUEST_URI} !/assets/ RewriteRule $ /index.php?id=7 [R=307,L] This is working for pretty much all pages, but, changing index.php?id=7 to another number id=6 for example still shows the page with no redirect. Any help welcome...

    Read the article

  • RewriteRules targeting a directory result in a gratuitous redirect

    - by MapDot
    I have a standard CMS-like RewriteRule set up in my .htaccess: RewriteRule ^(.+)$ index.php?slug=$1 Let's say I have a directory called "foo" in the root directory. For some reason, if you hit the page it causes a redirect: http://www.mysite.com/foo -- http://www.mysite.com/foo?slug=foo Removing the directory fixes the problem, but unfortunately, it's not an option. Does anyone know of a workaround?

    Read the article

  • rewrite 301 replace domain name with a new domain name

    - by user172697
    Hello , guys I need some help on mod rewrite 301 , to redirect my old website address to the new address , here is my scenario ive www.domain1.com/page1/ want to be redirect to domain2.com/page1/ ive to replace all request goes to domain1 with domain2 and keep the page after .com so watever was after .com should be the same just replace domain1 with domain2 . anyone can help me with this Regards

    Read the article

  • Can 302 redirect on wordpress homepage affect SEO?

    - by user2402116
    I manage a website. In order to lead the visitor to the latest post when entering the website, I set a 302 redirect from the homepage URL to the latest post URL. There's 1 to 2 posts a month so the redirection is made manually each time a new post gets published. Despite the website registration on google it doesn't get indexed at all. After searching for some solution on blogs and forums I understood this issue might be related to the 302 redirection. It's the first time I use redirections on a website, can someone help me?

    Read the article

  • I made an .htaccess template; is there anything else that should be added or changed?

    - by purpler
    # DEFAULTS ServerSignature Off AddDefaultCharset UTF-8 DefaultLanguage en-US SetEnv Europe/Belgrade SetEnv SERVER_ADMIN [email protected] # Rewrites RewriteEngine On RewriteBase / # Redirect to WWW RewriteCond %{HTTP_HOST} ^serpentineseo.com RewriteRule (.*) http://www.serpentineseo.com/$1 [R=301,L] # Cache media files <filesMatch "\.(gif|jpg|jpeg|png|ico|swf|js)$"> Header set Cache-Control "max-age=2592000, public" </filesMatch> <FilesMatch "\.(js|css|pdf|swf)$"> Header set Cache-Control "max-age=604800" </FilesMatch> <FilesMatch "\.(html|htm|txt)$"> Header set Cache-Control "max-age=600" </FilesMatch> # DONT CACHE <FilesMatch "\.(pl|php|cgi|spl|scgi|fcgi)$"> Header unset Cache-Control </FilesMatch> # Deny access to .htaccess <Files .htaccess> order allow,deny deny from all </Files>

    Read the article

  • Nginx reverse proxy + URL rewrite

    - by jeffreyveon
    Nginx is running on port 80, and I'm using it to reverse proxy URLs with path /foo to port 3200 this way: location /foo { proxy_pass http://localhost:3200; proxy_redirect off; proxy_set_header Host $host; } This works fine, but I have an application on port 3200, for which I don't want the initial /foo to be sent to. That is - when I access http://localhost/foo/bar, I want only /bar to be the path as received by the app. So I tried adding this line: rewrite ^(.*)foo(.*)$ http://localhost:3200/$2 permanent; This causes 302 redirect (change in URL), but I want 301. What should I do?

    Read the article

  • need help with 301 redirect and seo urls

    - by tyler
    Ok, i used the below to "seoize" my urls. It works great..the only problem is when i go to the old page it doesnt redirect to the new page.. so i have a feeling i will get two pages indexed in google... how can i just permenantly redirect the old pages eto new urls... RewriteRule ^city/([^/]+)/([^/]+) /rate-page.php?state=$1&city=$2 [NC] http: / / www.ratemycommunity.com/city/Kansas/Independence and old page = http://www.ratemycommunity.com/rate-page.php?state=Kansas&city=Independence

    Read the article

  • IIS6 - 301 permanent redirect response accessing an asp.net web site

    - by omatrot
    I've installed an ASP.NET 2.0 virtual directory application on the default web site in IIS6 (Windows 2003 computer) with a Visual Studio generated web deployment setup. Unfortunately, following a successfull installation, I'm unable to access our web site. I get a permanent redirect from IIS as shown in the log below : 2010-02-25 15:32:41 W3SVC1 127.0.0.1 GET /naweb3 - 80 - 127.0.0.1 Mozilla/4.0+(compatible;+MSIE+8.0;+Windows+NT+5.2;+Trident/4.0;+.NET+CLR+1.1.4322;+.NET+CLR+2.0.50727;+.NET+CLR+3.0.04506.30;+.NET+CLR+3.0.4506.2152;+.NET+CLR+3.5.30729) 301 0 0 This is the first time I have this kind of problem. Before I go with completely resetting IIS6 on this machine, I'm wondering what could cause this problem. The virtual directory configuration seems fine to me, no redirection at all at this level. Any help appreciated. TIA.

    Read the article

  • IIS7 and 301 permanent redirects using the location tag in web.config

    - by Mike
    I need to setup some 301 permanent redirects in the web.config of an ASP.NET MVC application running under IIS. The easiest way is to add a tag similar to the one below to the web.config file: <location path="TheMenu.aspx"> <system.webServer> <httpRedirect enabled="true" destination="menus/" httpResponseStatus="Permanent" /> </system.webServer> </location> When I go to the site at http://domain.com/TheMenu.aspx it redirects me to http://domain.com/menusxd instead of http://domain.com/menus. What would be causing this?

    Read the article

  • IIS7 and 301 permanment redirects using the location tag in web.config (ASP.NET MVC application)

    - by Mike
    I need to setup some 301 permanent redirects in the web.config of an ASP.NET MVC application running under IIS. The easiest way is to add a tag similar to the one below to the web.config file: <location path="TheMenu.aspx"> <system.webServer> <httpRedirect enabled="true" destination="menus/" httpResponseStatus="Permanent" /> </system.webServer> </location> When I go to the site at http://domain.com/TheMenu.aspx it redirects me to http://domain.com/menusxd instead of http://domain.com/menus What would be causing this? Thanks!

    Read the article

  • 302 vs 301 redirect in this specific case

    - by Binder
    We have a website that displays information in a location based manner, i.e. it detects the IP of the visiting user and redirects him/her to an appropriate landing page; for e.g. a user coming from 'Egypt' will be redirected to http://www.mysite.com/egypt/cairo and a user visting from dubai will be redirected to http://www.mysite.com/uae/dubai, so on and so forth and we cater to multiple locations in the middle-east. Now, we have been advised by our SEO consultant that we should put a 301 (permanent redirect) on http://www.mysite.com to point to http://www.mysite.com/ksa/riyadh I would like to know the negative implications that this would have on Google indexing or otherwise, as I fundamentally disagree with this suggestion and believe that in a siutation like this a 302 redirect would be more appropriate.

    Read the article

  • Mass 301 redirects mvc

    - by Massive Boisson
    Hi (this is a common problem with few twists). We are on IIS 6, without ISAPI_Rewrite with .net 4 and mvc 2 app. We would like to 301 forward bunch of old urls to matching new urls. (We are deploying a new site and google index will still point to old urls, and we need to map those urls to new urls) a) Is there a way to do this through IIS (but without ISAPI_Rewrite) and how? b) Is there a way to do this through the application code and how? All answers really appreciated, Thanks a lot --MB

    Read the article

  • .htaccess rewrite all queries to static page

    - by user127219
    I have an account where hundreds of inbound links to their calender are showing up as 404 (they moved their site to a new platform). I would like to make a wildcard redirection of all URLs with a query to their old event calender to land on a new static page, and do the same for their webstore queries. I've tried several variations, but can't seem to get it to work. CASE 1: I need to redirect URLs like these (note the difference between "showDay" and "showWeek"): apps/calendar/showWeek?calID=5107976&year=2011&month=7&day=10 apps/calendar/showDay?calID=5107976&year=2011&month=9&day=10 To: http://domain.com/events/ CASE 2: And also URLs like these: apps/webstore/products/show/1927074 TO: http://subdomain.domain.com/ I can't seem to get the syntax right to take all of the URLS and redirect them. I'm looking for the equivalent of a wildcard like "apps/calendar/*" would give you at a command line. Any help is appreciated!

    Read the article

  • Windows 2008 IIS 7.0 HTTP to HTTPS Redirect -- Versus IIS 6.0 Mechanism

    - by Dan7el
    This topic, creating a mechanism for redirection from HTTP to HTTPS on a Windows 2008 server running IIS 7.0 is a much written-about topic on the Internet. How this is done is really not so much my issue. My issue is more of explaining why this can't be done with the standard HTTP Redirect module that ships with Windows 2008 IIS 7.0. Instead, there are other methods needed that are more arduous. First, the IIS 6.0 method requires no externally available modules nor does it require any additional modifications to the web.config or any type of other development effort. It's outlined here: http://blogs.microsoft.co.il/blogs/dorr/archive/2009/01/13/how-to-force-redirection-from-http-to-https-on-iis-6-0.aspx And, you can see the basic steps are to run the snap-in, get the properties on the site, and do some modifications. Presto, you have the HTTP -- HTTP redirect setup. Now, on the IIS 7.0 platform, it doesn't seem this simple. An initial search found the following site: http://www.sslshopper.com/iis7-redirect-http-to-https.html Which has two separate approcates: 1. Involves installing a separately available Microsoft module -- URL Rewrite Module, and then adding XML to the web.config. 2. Custom Error Page. ...there might be other methods, but these are the basic ones and the first is listed as the primary method. But wait...There exists on the IIS 7.0 an HTTP Redirect Module. So...why can't I use the HTTP Redirect Module to do this very thing? This is really my big question. I need to know this because my management is going to insist I use the HTTP Redirect Module and set up the HTTP to HTTPS redirect in a similar fashion to how we do in IIS 6.0. Can someone please explain to me, in clean, simple, easy to understand, terms that both I and my management can understand as to why I need to go get the URL Rewrite Module and install that on the server and make the web.config changes suggested by the article instead of simply using the HTTP Redirect module that's already installed on the site? Thanks a bunch.

    Read the article

  • Django + jquery : getting 301

    - by llazzaro
    Hello, I have tabs that calls via javascript urls of django to complete the "container" But i am getting 301, any idea why this is happening? Server misconfiguration? urls.py urlpatterns = patterns('', (r'^admin/', include(admin.site.urls)), (r'^list/', 'carsproj.cars.views.list'), ) view def list(request): if request.is_ajax(): return render_to_response('templates/generic_list.html', { 'items' : Cars.objects.all(), 'name' : 'List - Cars' }, context_instance = RequestContext(request)) javascript the_tabs.click(function(e){ var element = $(this); if(element.find('#overLine').length) return false; var bg = element.attr('class').replace('tab ',''); $('#overLine').remove(); $('<div>',{ id:'overLine', css:{ display:'none', width:element.outerWidth()-2, background:topLineColor[bg] || 'white' }}).appendTo(element).fadeIn('slow'); if(!element.data('cache')) { $('#contentHolder').html('<img src="/media/img/ajax_preloader.gif" width="64" height="64" class="preloader" />'); $.get(element.data('page'),function(msg){ $('#contentHolder').html(msg); element.data('cache',msg); }); } else $('#contentHolder').html(element.data('cache')); e.preventDefault(); }) Please tell me what more information you need, js code? template? url.py? I WILL EDIT THIS POST FOR ADD MORE DATA

    Read the article

  • Several domains using 302 redirect to our domain

    - by Yamaha32088
    I am wondering what implications we can run into if one of our dealers is redirecting several of their domains using a 302 to our domain. The reason they are doing this is because they want to have time to build on their current sites but still want some content on the domains they own. Currently our domain is under a Manual Penalty for back links that we are working on removing. I do not like the idea of them linking back to our site but I need logical reasons other than "because I don't want you to".

    Read the article

  • 302 Redirect causes garbage at end of Wordpress link in Facebook

    - by Joao
    When I try to link my Wordpress blog to Facebook, the url doesn't resolve properly. There's garbage appended at the end and Facebook is not able to retrieve information from the site. Happens in every page, post or main entry. Here's what happens: http://clarissarezende.com.br/ shows up in Facebook as http://clarissarezende.com.br/UPLcS/ (when copy/paste the link) and no information about the site shows up in FB. I'm using Wordpress 3.3.1 with ProPhoto 4. Recently I moved the DNS entry on my ISP. The blog is hosted at clarissarezende.com.br/public_html/blog2 and before the DNS would point to public_html and then I changed it to public_html/blog2. Note that I did not move any Wordpress files. Made the (I think) necessary changes all over Facebook, but still no dice... Any ideas on what can be happening?

    Read the article

  • Why doesn't my htaccess redirect work?

    - by cosmicbdog
    I have setup a simple htaccess redirect which looks like this (this is the whole .htaccess file): Options +FollowSymLinks RewriteEngine On Redirect 301 /something http://something.com/something.php If I then load the site which contains this .htaccess, ie, myredirectsite.com/something I end up with the following 404: The requested URL /something was not found on this server. Apache/2.2.3 (Red Hat) Server at myredirectsite.com Port 80 And the logs: [Tue Jul 10 14:25:46 2012] [error] [client xx.xx.xxx.xx] File does not exist: /home/sites/scp/something Something is not a file, and something does not exist. I have assumed I could use Redirect the same as a Rewrite but it looks like the redirect needs to be for a file that actually exists? I created the file 'something' and it just attempts to load the blank file. No redirect. What am I missing in getting this working?

    Read the article

  • SEO: Duplicated URLs with and without dash "/" and ASP.NET MVC

    - by Guillermo Guerini
    Hello guys, after reading this article "Slash or not to slash" (link: http://googlewebmastercentral.blogspot.com/2010/04/to-slash-or-not-to-slash.html) on Google Webmaster Central Blog (the oficial one) I decided to test my ASP.NET MVC app. For example: http://domain.com/products and http://domain.com/products/ (with "/" in the end), return the code 200, which means: Google understands it as two different links and likely to be a "duplicated content". They suggest to choose the way you want... with or without dash and create a 301 permanent redirect to the preferred way. So if I choose without dash, when I try to access http://domain.com/products/ it will return a 301 to the link without dash: http://domain.com/products. The question is, how can I do that with ASP.NET MVC? Thanks, Gui

    Read the article

  • Can I use a 302 redirect to serve up static content from a url with escaped_fragment?

    - by Starfs
    We would like to serve up seo-friendly ajax-driven content. We are following this documentation. Has anyone ever tried to write a 302 redirect into the htaccess file, that takes the '?_escaped_fragment=' string and send that to a static page? For example /snapshot/yourfilename/ How will Google react to this? I've gone through the documentation and it's not very clear. The below quote is from Google's documentation this is what I find. I'm not sure if they are saying that you can redirect the _escaped_fragment_ url to a different static page, or if this is to redirect the hashtag URL to static content? Thoughts? From Google's site: Question: Can I use redirects to point the crawler at my static content? Redirects are okay to use, as long as they eventually get you to a page that's equivalent to what the user would see on the #! version of the page. This may be more convenient for some webmasters than serving up the content directly. If you choose this approach, please keep the following in mind: Compared to serving the content directly, using redirects will result in extra traffic because the crawler has to follow redirects to get the content. This will result in a somewhat higher number of fetches/second in crawl activity. Note that if you use a permanent (301) redirect, the url shown in our search results will typically be the target of the redirect, whereas if a temporary (302) redirect is used, we'll typically show the #! url in search results. Depending on how your site is set up, showing #! may produce a better user experience, because the user will be taken straight into the AJAX experience from the Google search results page. Clicking on a static page will take them to the static content, and they may experience avoidable extra page load time if the site later wants to switch them to the AJAX experience.

    Read the article

< Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >