New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"Keep Page URL fragments when tracking Page URLs" not persistent #9896
Comments
The value seems to be saved in the database correctly. But the saved value isn't preselected. Seems to be a bug. |
I tried to reproduce but couldn't. Maybe I don't understand this part correctly:
Whatever value I select and save for a website, when I open the website again, it's always correctly preselected. Tested with latest Chrome and latest Piwik 2.16 |
I'm able to reproduce that on my local instance. When editing any website most of the select values are not correctly preselected. Only selection of currency and time zone is correct. Chrome dev tools are showing this generated html for the fragment selection: <select ng-options="key as value for (key, value) in keepURLFragmentsOptions" ng-model="site.keep_url_fragment" class="ng-pristine ng-valid">
<option value="?" selected="selected" label=""></option>
<option value="0" label="No (Default)">No (Default)</option>
<option value="1" label="Yes">Yes</option>
<option value="2" label="No">No</option>
</select> |
Which browser are you using? I can prepare a patch to see if it changes something... maybe you can test it afterwards. I'll comment in a bit |
Can you try the following change? I couldn't test it since I'm on a branch and cannot switch easily but it should work: |
latest Chrome on Windows 7 but doesn't work on Firefox, aswell. |
@tsteur I've adjusted the branch a bit. Using integers as keys solves the problem for me. Would you check if it still works and merge it to master if so. |
I think that would break it on other systems. It seems to depend whether you get from database or rather from API an integer or a string. In my case I'm getting |
FYI, AFAIK it's possible this inconsistency (int VS string) comes from the MySQL adapter used (PDO vs Mysqli). |
I am having trouble setting the "Keep Page URL fragments when tracking Page URLs" option for a website. The site is tracking fine. The select box for the "Keep Page URL fragments when tracking Page URLs" option has no value selected. When I select "Yes", then click "Save", it appears to save OK. But when I go back to the config menu for that website, the option is once again unselected.
Any ideas anyone?
The text was updated successfully, but these errors were encountered: