Skip to content
Snippets Groups Projects
Commit 3484c6b6 authored by Michal Cyprian's avatar Michal Cyprian
Browse files

Add template rendering to hello/views.py

parent 362293d6
No related branches found
No related tags found
No related merge requests found
from django.shortcuts import render from django.http import HttpResponse
from django.template import loader
def index(request): def index(request):
return render(request, 'base.html') template = loader.get_template('base.html')
context = {
'message': "Hello, and welcome to the Platform.sh world",
}
return HttpResponse(template.render(context, request))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment