Mixing GET and POST generates inconsistence in URLS...

  • Thread starter Gabriele Zannoni
  • Start date
G

Gabriele Zannoni

Hi to all,
I have an aesthetic problem to solve. I'm working on the managing part
of a site. Some pages can be called with a query string like this:
http://mysite.com/manage.aspx?code=300

The manage.aspx web form uses the view state, has some web controls that can
cause post back and so on: it's a classic POST web form. In that page
there's a navigation control that changes (virtually) the query string.
Virtually means that the query string is not actually changed but the web
form behaves as the query string was changed. Suppose that with the
manage.aspx you can manage a product: you can modify the product name, the
product description or you can navigate to a different product and manage
that different product maintaining the state of the page. All that can be
done by POST and not by GET. But initially the page has been called by using
a GET... and the query string remains "cross posting". In other words the
first call is made as above and the next posts could be related to different
products so the query string should disappear... But it remains there
creating the URL inconsistency that hurts me so much!

Is there anyone having a solution for my problem?

Thanks,
Gabriele
 
G

Gabriele Zannoni

You're right. The structure of my pages is as you said, the problem is
another.

The first time I call a page there are some params in the query string like:
http://mysite.com/manage.aspx?code=300
I press a button on the page that causes a postback; after the roundtrip the
url in the browser contains the same query string
(http://mysite.com/manage.aspx?code=300) but it's no more significant
because that "code" value should have been changed during the postback. So,
what I want is to have, after the postback, my browser connected to
http://mysite.com/manage.aspx. Is that a bad idea?

Thank you for your response,
Gabriele
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,048
Latest member
verona

Latest Threads

Top