Project

General

Profile

Actions

Support #13299

open

Setting internal path does not clear path parameters

Added by max p 16 days ago. Updated 4 days ago.

Status:
Feedback
Priority:
Normal
Assignee:
Target version:
-
Start date:
12/05/2024
Due date:
% Done:

0%

Estimated time:

Description

Hello,

I want to use path parameters between pages of my application. Unfortunately I have noticed, that once I set some parameter values, I'm no longer able to clear them.

Is there a function somewhere to delete all the path parameters, so that when I set the new internal path, the parameters are not propagated?

BR,
Max.

Actions #1

Updated by Matthias Van Ceulebroeck 4 days ago

  • Status changed from New to Feedback
  • Assignee set to max p

Hello Max,

the internal path is used by Wt to remember its state, and facilitate browser navigation (back and forward). If you were to use a menu for your application, the parameter would be automatically updated when you change the currently selected item in the menu. If you then allow the menu to use the path (with WMenu::setInternalPathEnabled()), it will use the parameter for its navigation. Keeping the parameter as something you should not manage yourself, but the application does. That keeps it consistent per page.

If you DO want to manually manage it as well, a WApplication::redirect() allows you to remove/change it.

I hope that sufficiently answers the question? If not let me know!

Best,
Matthias

Actions

Also available in: Atom PDF