Open Bug 1798616 Opened 3 years ago Updated 2 years ago

Going back / forward can change the originalURI

Categories

(Firefox :: Address Bar, task, P3)

task

Tracking

()

People

(Reporter: jteow, Unassigned)

Details

We're using the browser custom element's originalURI to reference the URI that was used to request the page.

A website can add multiple history entries after the load to change the last history item.

For example, when searching "chocolate" in DDG the first URL used to make the request is:
https://duckduckgo.com/?t=ffab&q=chocolate

Following the page load, DDG will add another entry to my history:
https://duckduckgo.com/?t=ffab&q=chocolate&ia=web.

In this case, originalURI will still be referencing the first URL>

However, when the user goes to another webpage and then goes back, the URL that is loaded is https://duckduckgo.com/?t=ffab&q=chocolate&ia=web, so the originalURI will change to that, which means it won't match the URL we tried to match it against the first time around.

I don't think this is a defect, since it makes sense for originalURI to reflect the proper URI that was used to make the request, and so when going back, we are requesting the second URI rather than the first.

So we might need a more rigorous solution for tracking parameters we want to look out for from specific engines in cases where the originalURI solution doesn't hold up.

Severity: -- → N/A
Type: enhancement → task
Priority: -- → P3
You need to log in before you can comment on or make changes to this bug.