cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
923
Views
12
Helpful
10
Replies

url rewrite

ddavisson
Level 1
Level 1

My platform is CSS11503-AC

My question:

Is it possible to take a post with associated passed parameters? ie

http://www.one.com/crinput.nsf\vendorinputform?CreateDocument

and rewrite it to something like http://www.two.com/crinput.jsp and retain the passed parameters.

My attempts to use a redirect changes from a "post" to a "get" and loses the attached info.

1 Accepted Solution

Accepted Solutions

This is indeed not possible with the CSS.

If you need a document saying this is not feasible, you will not find one.

But if you take the configuration guide, you will not see any command that says you can do it either.

Gilles.

View solution in original post

10 Replies 10

wong34539
Level 6
Level 6

No, AFAIK, it is not possible.

Hi,

I posted a similar question before, can you please refer us to a link or a document which talks about this and reads that this is not supported in CSS.

Thanks,

Haitham

This is indeed not possible with the CSS.

If you need a document saying this is not feasible, you will not find one.

But if you take the configuration guide, you will not see any command that says you can do it either.

Gilles.

Hi Gilles,

By following the below link he can do rewrite the url but absolutely not to change the domain itself:

http://www.cisco.com/en/US/products/hw/contnetw/ps789/products_configuration_example09186a00801de8d6.shtml

Regards,

Haitham

Read the question carefully.

What he wants to do is extract part of the url to build a new one.

If you know a way to do it, I'll be glad to learn it.

Thanks for your (1) rating.

G.

Hi Gilles,

I meant to remove the rating but it didn't work, my apologies on this as with this particular scenario URL rewriting won't work. URL redirection can however be configured according to the link I previoulsy sent.

I'm rating you full 5 points here.

Rgrds,

Haitham

Hi Davisson and Gilles,

I did further investigation on this and figured out a way on how to do url rewriting for the complete path including the domain; you need to configure the following:

service redirect_url

ip address 2.x.x.2

keepalive type none

type redirect

redirect-string "www.domain2.com/Test/Test.html"

active

content redirect

add service redirect_url

port 80

protocol tcp

url "//www.domain1.com/"

active

Hope this makes sense to you.

Regards,

Haitham

Haitham,

I don't think that this will solve what he wants. He seems to want to go from:

www.abc.com/directory/TOKEN=constant_url_value

to

www.xyz.com/another_dir/NEWTOKEN=constant_url_value

We have developer at our site that want the CSS to do this also but I haven't found any way of doing it, and I don't believe that it can be done.

Am I wrong? If so, could you expand on your solution, please.

Douglas

Douglas,

Yes it's doable; in the redirect CONTENT you can specify the url command to be like this:

url "//www.abc.com/*"

This will match requests to www.abc.com with the full path (i.e. www.abc.com/whatever).. On the other hand, if you want to redirect requests to www.abc.com without typing any sub-directoy directory below it then your url command should be as follows:

url "//www.abc.com/"

As you see, without *, any request to abc without any sub-directories being entered will match this rule.

Next, you need to define what you want the url to be redirected to, under the redirect service using the redirect-string command mentioned in my previous post.

Hope it's clear now. Please let me know if it didnt work with you so I can assist more on this as it worked with me.

Regards,

Haitham

Haitham,

be carreful when answering questions.

Your participation is appreciated but you seem to rush quickly to a solution without first understanding completely the question.

In this case, the question is "how to capture any url, extract part of the full path, and create a new url based on this path ?"

The solution you give us is well-known to redirect any url to 1 static, pre-configured url.

This is not the question for this thread.

And, there is no need to search for a solution, because as a software engineer working with the CSS code, I can tell you there is no solution.

Again, thanks for your participation, but please make sure to fully understand the question next time you decide to answer.

Gilles.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: