Article 5HBBY javascript localStorage not working

javascript localStorage not working

by
rblampain
from LinuxQuestions.org on (#5HBBY)
I have a CGI script storing value in localStorage and an HTML page (Firefox and Javascript in both cases) trying to read the value but not finding it (key is 'null'). It seems I do not understand the "same origin" correctly.
This is done on a home testing PC and the only difference is that the CGI is located in /usr/lib/cgi-bin/ while the html page is located in /var/www/html/ on the same machine. The CGI displays the value stored in localStorage when checked.
According to my understanding, the different paths do not change the "origin".

Has anyone any suggestion of what to look for (except typos)?

Thank you for your help.latest?d=yIl2AUoC8zA latest?i=jJbZeUii83I:PziAnGzVjPQ:F7zBnMy latest?i=jJbZeUii83I:PziAnGzVjPQ:V_sGLiP latest?d=qj6IDK7rITs latest?i=jJbZeUii83I:PziAnGzVjPQ:gIN9vFwjJbZeUii83I
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments