Re: Iframe'd page in Django template can't find it's Javascript or CSS files, 404 error

2017-03-05 Thread Melvyn Sopacua
On Friday 03 March 2017 20:37:29 Tom Tanner wrote: > When the iframe requests > `/interactive`, it loads `interactive-1/index.html`. But the iframe still loads /interactive. So it's base url is /interactive and a request for scripts/main.js is /interactive/scripts/main.js. Unless you either: 1/

Re: Iframe'd page in Django template can't find it's Javascript or CSS files, 404 error

2017-03-05 Thread chris rose
there is a lack of information here, though you last post suggests maybe you missed a couple of template tags at the start of you index.html add: {% load staticfiles %} and then when adding you scripts use: -- You received this message because you are subscribed to the Google Groups

Re: Iframe'd page in Django template can't find it's Javascript or CSS files, 404 error

2017-03-04 Thread Daniel Roseman
On Saturday, 4 March 2017 15:57:49 UTC, Tom Tanner wrote: > > >How are you referring to the assets in the template? > > In `interactive/index.html`, in the `` tag, I have ` src="scripts/main.js">` > Well, if you wanted to load the scripts from /interactive-1/scripts/main.js, then that's what you

Re: Iframe'd page in Django template can't find it's Javascript or CSS files, 404 error

2017-03-04 Thread Tom Tanner
>How are you referring to the assets in the template? In `interactive/index.html`, in the `` tag, I have `` On Saturday, March 4, 2017 at 8:55:22 AM UTC-5, Daniel Roseman wrote: > > On Saturday, 4 March 2017 13:30:37 UTC, Tom Tanner wrote: >> >> In my `views.py`, I have one path render an html

Re: Iframe'd page in Django template can't find it's Javascript or CSS files, 404 error

2017-03-04 Thread Daniel Roseman
On Saturday, 4 March 2017 13:30:37 UTC, Tom Tanner wrote: > > In my `views.py`, I have one path render an html file: > > def interactive(request): > if request.session.get('interactiveID') == None: > t= get_template('blank-interactive.html') > else: > interactive_template=

Iframe'd page in Django template can't find it's Javascript or CSS files, 404 error

2017-03-04 Thread Tom Tanner
In my `views.py`, I have one path render an html file: def interactive(request): if request.session.get('interactiveID') == None: t= get_template('blank-interactive.html') else: interactive_template= 'interactive-' + str(request.session['id']) + '/index.html' t=