If i have the file on local server like XAMPP/htdocs/graph.json it works fine. What i want to do is to make a form where i can submit a custom json file, and javascript reads that file.
XAMPP with Apache running. I have my file in XAMPP/htdocs named graph.json. It is hard coded.
I have the following in my index.html:
d3.json("graph.json", function (error, json) {
...
}
I have tried this and at first sight this is exactly what i want
<form action="/index.html">
<input type="file" name="graph">
<input type="submit">
</form>
When i select the json and click "submit" it says "object not found"