Django 3.1|Python 3.6.12: Custom Template Tags not showing up all the sudden?

116 views Asked by At

I was following one tutorial about Django, and I got stuck, so I've searched for another and another and I come to the situation where I've reinstalled my Linux system x6 (due to Python changes in ~/.bashrc and similar things)

I am new here and I am new at Python and Django (beginner level). Still learning, but I have experience (8 years) working in various companies such as NCR... and others as a freelancer where I learned a lot of sys admin/ back-end things.

The point is: ALL THE SUDDEN IN AN ANOTHER TUTORIAL (MEANWHILE I BELIEVE PYCHARM HAD AN UPDATE I cannot pull the tags created.

So, in my base.html all my .html pages in pages.app are in templates folder, all setup in settings....

But, my {{ tags }} are not showing up !

Here's some info,... I have the same problem!

In models:

from django.http import HttpResponse
from django.shortcuts import render
from .models import *
from django import templatetags
from django import template

# Create your views here.


def home_view(request):
    return render(request, "home.html", {})


def contact_view(request):
    return render(request, "contact.html", {})


def about_view(request):

    my_context:{
        "my_text": "This is about us",
        "my_number" : 123
    }
    return render(request, 'about.html', my_context)


def social_view(request):
    return render(request, "social.html", {})

I have in source folder the 'template dir' added all in settings Settings

Here's the code itself...

PLEASE HELP I CANNOT CONTINUE WITH TUTORIAL I WANT TO LEARN DJANGO AS WELL ON BEGINNER LEVEL AS I DID WITH PYTHON So I can move on, I am sick and tired of making newapp , projects, changing the Python interpreter and then get into (x6) situations to reinstall Ubuntu...

So now, this is the longest period of having same OS not reinstalled due practice and learning Python and Django... :(

from django.http import HttpResponse
from django.shortcuts import render
from .models import *
from django import templatetags
from django import template

# Create your views here.


def home_view(request):
    return render(request, "home.html", {})


def contact_view(request):
    return render(request, "contact.html", {})


def about_view(request):

    my_context:{
        "my_text": "This is about us",
        "my_number" : 123
    }
    return render(request, 'about.html', my_context)


def social_view(request):
    return render(request, "social.html", {})

please, ANY IDEA?

0

There are 0 answers