Social Links Icon in Django language

I am stuck here. I shall be grateful if anyone can help me.

I have been frequently facing problem of not loading CSS in Chrome Browser when I shall render the web-app in localhost. Can anyone provide me solution for this CSS not loading during running development server?

I have been also trying to create icon as a social links in footer. Can anyone provide any solution code for this problem?

NO JAVASCRIPT


**settings.py:**

DEBUG = TRUE
STATICFILES_DIRS = [
    'myapp/static',
]
STATIC_URL = 'static/'
MEDIA = '/media/'
````````````````````````````````````````````````````````````````````````````````````````````````````````

**base.html:**

{% load static %}
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="stylesheet" href="{% static 'css/styles.css' %}">
    <title>Document</title>
</head>
<body>
    {% include 'partials/_header.html' %}

    <main> {% block content  %}{% endblock  %}</main>

    {% include 'partials/_footer.html' %}
    
</body>
</html>

````````````````````````````````````````````````````````````````````````````````````````````

footer:
<footer>
         <div>
                  <a href=" https://www.linkedin.com/in/aninda-kundu-481718188/recent-activity/all/">LinkedIn</a>
          </div>

</footer>

Please format your code in proper code blocks in order to get better help.

Also, post your STATIC_URL and STATICFILES_DIRS from your settings.py and your javacript console output.

1 Like

A clickable icon is an image within an <a> element.
e.g. <a href=...><img ...></a>

1 Like

Thank you @anefta for quick response. You are truly a wonderful django-problem solver. I have updated the code.

I have also facing problem of CSS not loading sometimes when I shall render in CHROME Browser. Can you please provide me the solution for this?

Thank you sir @KenWhitesell for taking this step. Your solutions are really genuine and it will really help me a lot.

I have been also facing trouble of CSS not loading sometimes in CHROME Browser when I render the page in Development mode. Can you please provide me the solution for this CSS not loading in chrome browser?

It depends upon the specific reason, but frequently it’s because of the browser cache.
You have a couple of options:

  • Turn caching off in the developer’s tools (this only applies when the developer’s tools window is open).
  • Use shift-reload to load the page
  • Use a private or incognito window

(I tend to mostly rely on the shift-reload when I first encounter it in a session.)

1 Like

Thank you sir. I shall always use these methods.