Questions tagged [url-rewriting]

A URL rewrite engine is software that modifies a web URL's appearance (URL rewriting). Rewritten URLs are used to provide shorter and more relevant-looking links to web pages, to route users from obsolete URLs to replacements, or to simplify the format of the URL for human readability. The technique adds a degree of separation between the files used to generate a web page and the URL that is presented to the world.

Filter by
Sorted by
Tagged with
0 votes
0 answers
13 views

Slow performance wordpress sites

I recently migrated all my 4 websites from a Linux server to a Windows Server 2019 server. When the websites were on the Linux server I never had performance problems, while since I migrated the ...
Stefano Albano's user avatar
0 votes
1 answer
19 views

I need to rewrite 2 urls in htaccess to different page. Both urls start with same name but one with single parameter and the other with 2 parameter

I have 2 dynamic urls http://localhost:8080/overseas/cost/cancer and http://localhost:8080/overseas/cost/cancer/cancer-treatment structure is like user will click on any department (cancer, cardiology,...
Tariq's user avatar
  • 21
0 votes
0 answers
22 views

Next.js Rewrite Issue with Next Link Component in Version 13.5.2

I'm currently working on a multi-language website using Next.js, and I've been using rewrites to handle different languages. However, after updating to Next.js version 13.5.2, I've encountered an ...
Albing's user avatar
  • 1
0 votes
0 answers
10 views

How to publish root application and sub applications under root application in IIS?

I have a root application (Angular Application) in IIS like "www.example.com". (Main Website) I need to publish sub applications under "www.example.com" like "www.example.com/...
Shiva Prasad's user avatar
0 votes
1 answer
27 views

Apache rewrite with GET parameters not working

I have a url: www.example.com/products.php?category=category that I want to rewrite to www.example.com/products/category (the category can be either meats, condiments or smokers depending on which ...
Thomas Cottis's user avatar
1 vote
2 answers
36 views

htaccess problem with empty string in URL

I want users to only be able to access domain.com or domain.com/. Anything afterwards, even domain.com/index.php, should redirect to domain.com. I have this .htaccess RewriteBase / RewriteEngine On ...
Jelly's user avatar
  • 37
0 votes
1 answer
23 views

.htaccess redirecting non-existing file to index.php in folder with filename as parameter

I have the following .htaccess RewriteRules: RewriteEngine On RewriteBase /app/ RewriteCond %{THE_REQUEST} \s/app/index\.php\?view=([^&\s]+) [NC] RewriteRule ^ %1? [R=301,L] RewriteCond %{...
Lion Hummer's user avatar
0 votes
0 answers
9 views

Apache Rewrite with a Domain Extension Variable

I would like to rewrite all /base/ paths to a domain but with an unknown domain extension. Also removing any subdomains as well. For example: subdomain.domain.com/base/some-path → domain.com/some-path ...
Maciek Semik's user avatar
  • 1,882
0 votes
1 answer
132 views
+50

IIS Rewrite is not working across different domain

**Updating this question as per my latest scenario after correcting based on the comments ** I have installed ARR I have followed this post https://halfblood.pro/the-very-common-mistakes-when-using-...
Jey's user avatar
  • 2,087
0 votes
0 answers
16 views

Append remote IP in a rewrite rule

i would like to retrieve in a querystring, the remote ip via a simple rewrite rule, is it possible ? thanks in advance here is the sample RewriteCond Host: www.host.com RewriteRule (.*)/test.html $1/...
David's user avatar
  • 11
1 vote
1 answer
35 views

Rewrite rule to add .php extension not working in combination with HTTPS redirect

I hope somebody may be able to help. I want to remove file extensions (.php) from my internal links but of course I need to first configure this in htaccess. I believe that the correct code is ...
Rick Crofts's user avatar
0 votes
0 answers
16 views

Woocommerce : rewrite nested woocommerce product_cat taxonomy slugs to remove parent

I'm facing an issue on removing the parents' slugs from nested product_cat terms. Setup is a basic WPress + WCommerce+ Polylang Pro + Polylang Business pack, just for displaying products, in English ...
jijihbt's user avatar
  • 35
2 votes
1 answer
31 views

AWS Cloudfront 503 "FunctionThrottledError" when using Cloudfront function for URL rewriting

We have a Single Page Application (TypeScript/JS) hosted on a AWS S3 bucket, served with a Cloudfront distribution. Requesting the base URL of the Cloudfront distribution returns the application (for ...
jean553's user avatar
  • 643
-2 votes
0 answers
19 views

(3) Redirect & Rewrite my URLs with an .htaccess file?

https://www.pooeen.com/82 Please be redirected to the URL below https://www.pooeen.com/82/ I am looking forward to hearing from you soon. https://stackoverflow.com/a/76634478/22188740 https://...
POURYA.RAOUFI's user avatar
-2 votes
1 answer
45 views

Redirect & Rewrite my URLs with an .htaccess file? [duplicate]

Redirect and rewrite my URLs with an .htaccess file? Duplicate content, 2 links with the same content. https://www.pooeen.com/viewtopic.php?t=82 Please be redirected to the URL below https://www....
POURYA.RAOUFI's user avatar
0 votes
1 answer
55 views

Failed routing when deploy React + Express.js app on IIS server

I have a React app created by Create-React-app and Redux together with Node.js (specifically Express.js) backend. In the frontend package.json file I set "proxy: http://localhost:5000" to ...
Ning Zheng's user avatar
1 vote
0 answers
17 views

Rewrite sentences from first person to third person and vice versa using python packages

Are there any packages in python that can rewrite large content from Person's point of view i.e first person to third person and Third person to First person I ate apple yesterday He ate apple ...
Sathwik Vadla's user avatar
0 votes
0 answers
10 views

How to remove some words from url?

How can I remove '~' and '@abc.example.com' from url? origin url: https://example.com/[email protected]/ expect to display: https://example.com/user/ I already tried as in the apache conf: <...
Thu Ra's user avatar
  • 2,013
0 votes
0 answers
12 views

IIS URL Rewrite with Wrangler/workers

we are trying to set up wrangler on our local dev and feature environments. we have 2 brands/sites that run out of a single IIS Site. We have configured a URL Rewrite rule that checks for the HTTP ...
mikeg's user avatar
  • 1
0 votes
1 answer
24 views

In HttpRoute resource, use regexMatch captured group in URLRewrite

I am moving from an nginx ingress controller to a Gateway controller in GKE. In my Ingress resource, I do a URL rewrite using the nginx.ingress.kubernetes.io/rewrite-target annotation. In the rewrite, ...
David Gourde's user avatar
  • 3,729
0 votes
0 answers
21 views

NGINX redirect multiple paths to subdomains rewrite

I want to achieve url rewrite as such: https://documentation.domain.com/login to https://app.domain.com/login https://api.domain.com/login to https://app.domain.com/login , any sudomain with url {...
Jason The Dynamite's user avatar
-1 votes
0 answers
45 views

Vaadin + Spring Boot different sub domains for documentation & API

I have a big server application with spring boot and vaadin. Vaadin is used to display views, mainly for dashboard etc. Spring boot is used for API. The problem: I want to have rest controllers on sub ...
Jason The Dynamite's user avatar
0 votes
1 answer
52 views

ASP.NET MVC Url Rewrite - WWW redirect

I'm trying to add a iis url rewrite rule in web.config. The rule should be as follows. If the url does not contain www, then redirect to www However, if the Host contains, 'svha-prd-as-careservices-01'...
chamara's user avatar
  • 12.6k
0 votes
1 answer
54 views

URL Rewrite from web.config in Azure Application does not work

I want to redirect my users from "https://mywebsite.azurewebsites.net/Spa/de/#/.." to "https://mywebsite.azurewebsites.net/Spa/en/#/.." using url rewrite in web.config but it is ...
therealwolf's user avatar
-1 votes
1 answer
20 views

IIS7 url rewriting results in 500 internal server error

I run my website on IIS7 and have the following rewrite rule for my website: <rule name="five21 https redirect" stopProcessing="true"> <match url="(.*)&...
Hedayat's user avatar
  • 39
0 votes
0 answers
32 views

Wordpress custom permalink issue

I have created custom post_type_link in wordpress. It works very well. But when I open a single post of that post type it doesn't work, it redirects to 404 page. Any suggestions please? function ...
Mary X Nabors's user avatar
0 votes
1 answer
34 views

IIS Manager - replace URL containing folder structure with only Website URL

we are using a website which is managed via IIS Manager. A web tool is currently accessed via the full URL containing the folder structure. So if someone does trial and error with different paths in ...
fennix's user avatar
  • 13
-1 votes
0 answers
27 views

Wordpress add_rewrite_rule with custom post_type

I have created custom post_type_link in wordpress. It works very well. Its code is- function tpcl_post_permalinks( $post_link, $post = 0 ) { $topic_id = get_post_meta( get_the_ID(), '_post_related_id',...
Mary X Nabors's user avatar
-1 votes
0 answers
19 views

After rewriting the URL I got issue in the anchor tags link

I have a URL https://www.example.com/abc/xyz/index.php?slug=are-you-ready. I have changed my URL to https://www.example.com/abc/xyz/are-you-ready using the below htaccess code and it's working. ...
Naren Verma's user avatar
  • 2,205
0 votes
0 answers
26 views

Non www to www subfolders and inner pages are not redirecting

I am redirecting non www to www and I have added the below code in my htaccess file RewriteEngine On RewriteCond %{HTTP_HOST} !^www\. [NC] RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L] Also ...
Naren Verma's user avatar
  • 2,205
0 votes
0 answers
24 views

How can I create a rewrite that redirects all traffic from subdomains to the root/apex domain?

I have a very simple application gateway that has two listeners, one for 80 and one for 443. Two rules that either allow you to the backend pool with the website, or redirects you from 80 to 443. I'm ...
BristleBeard's user avatar
0 votes
1 answer
23 views

Apache URL rewrite: remove index.php and query string

I have a link, for example: https://test.com/index.php?code=myko I would like to turn it into: https://test.com/myko My best attempt so far is: RewriteEngine On RewriteRule ^(.*)$ index.php?code=$1 [L]...
Kobus Myburgh's user avatar
0 votes
1 answer
27 views

Firebase static website hosting stop working "Site Not Found"

Need to rewrite the rules for some of the pages of my site. So I want to simply include my rewrites likes below. Here is my firebase.json { "hosting": { "site": "...
Jeyaprakash's user avatar
0 votes
1 answer
14 views

Is there a way to use the rewrite module to dynamic redirect based on host header root domain

I have a specification from a customer. Given a apache web server with rewrite module find a way to dynamically redirect based on host header root domain. For example - if request is coming from www....
Paul's user avatar
  • 203
1 vote
0 answers
79 views

Angular Proxy Config "Not rewriting GET /api/account/user because the client prefers JSON"

Having run into a CORS error in Angular v16.1.0 (using port 44498) with a ASPNET CORE DotNet 6.0 backend (using port 44303), I have followed the recommendation of using the Angular Proxy to rewrite a ...
Jeff Davies's user avatar
-1 votes
0 answers
12 views

How to rewrite url in htaccess to show filename instead of filename with file name

My problem is : I want to change the 'category' name according to file name (E.g., Education,Result,Health.....etc). Original is http://localhost/project/bihar-news/category/result I want like this ...
Ranjeet Kumar's user avatar
0 votes
1 answer
29 views

ARR throws 404 on adx URLs after rewrite

I have a IIS HA setup (2 ARR, 2 IIS) that work fine except for .axd ressources. When going thru ARR any and all .axd return a 404 but when I bypass the ARR (simple DNS record change), the request ...
JulioQc's user avatar
  • 310
0 votes
1 answer
34 views

Accessing URL variables in custom WordPress blocks with URL rewriting and permalinks

Preface: I know this is an extremely common question. I've read about two dozen of these and tried all the proposed solutions, but just can't get it to work on my site. There are no other WordPress ...
Jesse Kuzy's user avatar
0 votes
0 answers
11 views

the site https://test.domain.co.il is redirected to https://www.domain.co.il

I have a site in prod enviorment that is monitored CloudFlare. I also have a test site, that is not monitored there. still, when entering the test site, it redirects to the prod site. I am a new ...
lior mtf's user avatar
0 votes
0 answers
11 views

Ajaxfileuploader fails on rewritten url for page by Intelligencia URL rewriter

So I used the Intelligencia URL rewriter to rewrite my .aspx pages. (I find it very easy to implement to rewrite URLs compared to other methods). Everything worked fine until i realized that ...
Gamonki's user avatar
  • 21
0 votes
0 answers
12 views

Wordpress url rewrite issue for wordpress rest api url

I have an issue of url rewrite. A page created from wp-admin in which the title suppose profile and a custom template are assigned to the profile page. I used a custom permalink structure(/%postname%) ...
Goutam Sarkar's user avatar
0 votes
0 answers
18 views

Wordpress Pages With Categories and category url in page link

I have created a taxonomy (category) for pages (not for posts). add_action('init', function() { register_taxonomy('arrest_records', ['page'], [ 'label' => __('Arrest Records', 'txtdomain')...
Bogdan Claudiu's user avatar
0 votes
0 answers
16 views

Remove jsessionid from url Spring boot

I'm using spring boot to make my app and run it on tomcat 10 server. But the jsessionid show on my url. I've tried using tuckey rewrite filter, but it's don't work. jsessionid just display when the ...
Zos's user avatar
  • 51
0 votes
1 answer
26 views

How to redirect requests to a different URL with Nginx without changing the URL in the browser for subdomains

I am trying to rewrite requests from a subdomain to a subfolder, so the URL stays as subdomain.example.com in the browser, but the content of example.com/subdomain is shown. I have tried using the ...
Alex Sofonea's user avatar
0 votes
0 answers
42 views

Kubernetes nginx Ingress reverse proxy on subpath with http_referer

Is it possible to use the networking.k8s.io/v1 Ingress nginx to route and serve multiple services on different subpaths of a single domain using the same port? The applications cannot be adjusted in ...
Magnus Ingwersen's user avatar
1 vote
1 answer
34 views

Remove or hide specific string in a url using .htaccess

I have this url https://test.app/myapp/login. All I want is to remove the 'myapp' string using .htaccess. This is what I tried so far. RewriteEngine on RewriteCond $1 !^(index\.php|resources|robots\....
unice's user avatar
  • 2,685
0 votes
0 answers
17 views

Change the WordPress Permalink Structure for specific post

hi I use Polylang for my post languages my post look like these example.com/postname example.com/es/postname example.com/fr/postname but now I am trying something new through php redirect code in ...
SS Apps's user avatar
1 vote
2 answers
117 views

AWS CloudFront Rewrite to External URL

Background I have a big repository that uses CRA React, and I need an SEO Feature in SSR. So I created a new NextJS 13 Repo and put only the page that needed the SEO Feature such as the Landing page ...
Michael Harley's user avatar
0 votes
1 answer
53 views

Angular App hosted with IIS not handling % sign correctly

I'm encountering an issue with my Angular app that's hosted using IIS (Internet Information Services) and I want to hide server name details from response headers. The problem I'm facing is related to ...
falgun modi's user avatar
1 vote
1 answer
20 views

Nginx rewrite url with parameters without changing url

I am using Nginx as a proxy server and want use certain user friendly url with parameters to proxypass/rewrite to another url with the respective parameters. I am expecting that from this url: www....
Andreas Constantinou's user avatar

1
2 3 4 5
410