Re: Images are not showing up in the page

2023-04-09 Thread Sahan Srinivas
Yeah thanks everyone, the problem is resolved.

On Sun, Apr 9, 2023 at 5:19 PM Kiyavilo Msekwa  wrote:

> If you are running it on a live server make sure that media/photos folder
> is on public_html before you run load %satic% since the access to the
> domain will look into public_html folder to which Django does not run from.
>
> I had previously encountered similar situation and the solution was to
> copy the folder into public_html instead
>
> I hope this answer the question.
>
> Regards
>
> Kiyavilo
>
> On 9 Apr 2023, at 22:52, Sahan Srinivas <26sa...@gmail.com> wrote:
>
> Yeah I gave that, actually that is also not the problem. Not sure what it
> is
>
> Kind Regards,
> Sahan
>
> On Sun, Apr 9, 2023 at 3:44 PM Mir Junaid  wrote:
>
>> The command is {% load static%}
>>
>> On Sun, 9 Apr, 2023, 11:45 pm Sahan Srinivas, <26sa...@gmail.com> wrote:
>>
>>> Hi Devs,
>>>
>>> *Images are not showing up in Django. Below is the screenshot*
>>>
>>> 
>>> *Below are the screenshots of Settings.py file and urls.py files*
>>>
>>> *settings.py*
>>> 
>>>
>>> *urls.py*
>>> 
>>> *home.html:* (I have give like this in html file)
>>> 
>>> *views.py*
>>> 
>>> *Media Images:*
>>> 
>>>
>>> *I followed the documentation, stack overflow but, I am still not sure
>>> why images are not showing up. Can anyone help me out?*
>>>
>>> Kind regards,
>>> Sahan
>>>
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to django-users+unsubscr...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/CAO3SeezAm3Lbe8JGxoCrZ2DCd74p8gFsxzUUoLa5166t6Dm9Kg%40mail.gmail.com
>>> 
>>> .
>>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CAM%2BpT8z6w2Pjs6Hb_CxrOvoWSNhYe4SoL3RrTpkp7pHEXr2spg%40mail.gmail.com
>> 
>> .
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAO3SeeyoR-A%3DW7f0fC-NjLZcqyG-m4oMVoqonQ7r_XmAoaEEMg%40mail.gmail.com
> 
> .
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/FD4AD59E-9002-46D9-97AB-41DB5B9E4E3D%40gmail.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAO3SeewM5VGZGNn-ruSToDUPifu85MPLLd5nCeDfw7SSNuNTFg%40mail.gmail.com.


Re: Images are not showing up in the page

2023-04-09 Thread Kiyavilo Msekwa
If you are running it on a live server make sure that media/photos folder is on 
public_html before you run load %satic% since the access to the domain will 
look into public_html folder to which Django does not run from.

I had previously encountered similar situation and the solution was to copy the 
folder into public_html instead

I hope this answer the question.

Regards

Kiyavilo

> On 9 Apr 2023, at 22:52, Sahan Srinivas <26sa...@gmail.com> wrote:
> 
> Yeah I gave that, actually that is also not the problem. Not sure what it is
> 
> Kind Regards,
> Sahan
> 
> On Sun, Apr 9, 2023 at 3:44 PM Mir Junaid  > wrote:
> The command is {% load static%}
> 
> On Sun, 9 Apr, 2023, 11:45 pm Sahan Srinivas, <26sa...@gmail.com 
> > wrote:
> Hi Devs,
> 
> Images are not showing up in Django. Below is the screenshot
> 
> 
> Below are the screenshots of Settings.py file and urls.py files
> 
> settings.py
> 
> 
> urls.py
> 
> home.html: (I have give like this in html file)
> 
> views.py
> 
> Media Images:
> 
> 
> I followed the documentation, stack overflow but, I am still not sure why 
> images are not showing up. Can anyone help me out?
> 
> Kind regards,
> Sahan
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to django-users+unsubscr...@googlegroups.com 
> .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/CAO3SeezAm3Lbe8JGxoCrZ2DCd74p8gFsxzUUoLa5166t6Dm9Kg%40mail.gmail.com
>  
> .
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to django-users+unsubscr...@googlegroups.com 
> .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/CAM%2BpT8z6w2Pjs6Hb_CxrOvoWSNhYe4SoL3RrTpkp7pHEXr2spg%40mail.gmail.com
>  
> .
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to django-users+unsubscr...@googlegroups.com 
> .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/CAO3SeeyoR-A%3DW7f0fC-NjLZcqyG-m4oMVoqonQ7r_XmAoaEEMg%40mail.gmail.com
>  
> .

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/FD4AD59E-9002-46D9-97AB-41DB5B9E4E3D%40gmail.com.