Re: how to Display images other than from static folder.

2022-01-31 Thread Lunga Baliwe
i think you want to use MEDIA_URL, see https://learndjango.com/tutorials/django-file-and-image-uploads-tutorial and also check https://docs.djangoproject.com/en/3.2/topics/files/ static files are things like logos, css and maybe some javascript. On Mon, Jan 31, 2022 at 5:36 PM DJANGO DEVELOPER wr

Re: Model Design

2022-05-06 Thread Lunga Baliwe
Also/maybe if you haven't please check https://django-import-export.readthedocs.io/en/latest/ On Thu, May 5, 2022 at 3:59 PM 'David Turner' via Django users < django-users@googlegroups.com> wrote: > We receive the data every two weeks and then use django-import-export to > import the data into ou

Django sms

2012-09-14 Thread Lunga Baliwe
Good day, I am writting a website that sends sms to a cell phone. I am using django-sendsms-0.2.2. I followed the README.rst doc and the output does appear on the console. How do I make it to actually send the sms? Your help will appreciated. Kind regards, Lunga -- You received this message

Re: Django sms

2012-09-14 Thread Lunga Baliwe
s like Dennis said, that this is meant for testing purpose, do I have to subscribe to twilio in order to be able to actually send the sms? On Friday, September 14, 2012 8:40:10 PM UTC+2, Lunga Baliwe wrote: > > Good day, > > I am writting a website that sends sms to a cell phone. I am &

Re: Django sms

2012-09-15 Thread Lunga Baliwe
pp, I will post back. The website will send sms' to a group of people who are members of an organisation informing them of meetings and other group announcements. Thanks for the clear explanation and for your help. On Friday, September 14, 2012 8:40:10 PM UTC+2, Lunga Baliwe wrote: &g

Re: No module named wsgi

2013-05-29 Thread Lunga Baliwe
Thanks for your replying, am only seeing your reply now. On Thu, May 23, 2013 at 7:49 PM, Sandeep kaur wrote: > On Thu, May 23, 2013 at 8:29 PM, Luggaz wrote: > > I don't know what I dd but it seems to work now! > > > mod wsgi installation could have also solved he purpose, using this > comman

Re: Django not showing css - static files

2014-03-14 Thread Lunga Baliwe
Good day Mike, I have STATIC_ROOT = os.path.join(BASE_DIR, 'website/static/') website being the app name On Fri, Mar 14, 2014 at 12:57 AM, Mike Dewhirst wrote: > On 14/03/2014 9:05am, Luggaz wrote: > >> Good day, >> >> My static files are not showing on production, they show when I run them >>

Re: Django not showing css - static files

2014-03-14 Thread Lunga Baliwe
yes I think I have on apache I got it like this. Alias /static/ /home/project_name/website/static Order allow, deny Allow from all I did run collecstatic aswell On Fri, Mar 14, 2014 at 8:18 PM, Tom Evans wrote: > On Fri, Mar 14, 2014 at 6:08 PM, Lunga Baliwe wrote: > >

Re: Django not showing css - static files

2014-03-14 Thread Lunga Baliwe
I just put on the last forward slash on Alias /static/ /home/project_name/website/static/ And it worked, yho thanks Mike... On Fri, Mar 14, 2014 at 8:29 PM, Lunga Baliwe wrote: > yes I think I have on apache I got it like this. > > Alias /static/ /home/project_name/websi

Re: Django not showing css - static files

2014-03-14 Thread Lunga Baliwe
Really appreciate it On Fri, Mar 14, 2014 at 8:34 PM, Lunga Baliwe wrote: > I just put on the last forward slash on > Alias /static/ /home/project_name/website/static/ > > And it worked, yho thanks Mike... > > > On Fri, Mar 14, 2014 at 8:29 PM, Lunga Baliwe wrote: >

Re: Django not showing css - static files

2014-03-14 Thread Lunga Baliwe
And thank you Tom as well On Fri, Mar 14, 2014 at 8:35 PM, Lunga Baliwe wrote: > Really appreciate it > > > On Fri, Mar 14, 2014 at 8:34 PM, Lunga Baliwe wrote: > >> I just put on the last forward slash on >> Alias /static/ /home/project_name/website/static/ >

Re: what is the meaning of this error

2019-05-27 Thread Lunga Baliwe
You probably have to import and use like this https://docs.djangoproject.com/en/2.2/topics/http/shortcuts/#redirect from django.shortcuts import redirect def my_view(request): ... obj = MyModel.objects.get(...) return redirect(obj) On Tue, May 28, 2019 at 1:49 AM Saeed Pooladzadeh w

Re: Django Testing

2020-03-31 Thread Lunga Baliwe
Good day, I hope this ( https://docs.djangoproject.com/en/3.0/intro/tutorial05/#writing-our-first-test) can help, its part of the Django tutorials. On Tue, Mar 31, 2020 at 4:35 PM ekong, emmanuel wrote: > I’m having the same difficulty... > > On Tue, 31 Mar 2020 at 3:32 PM, Abrar Ahmad > wrote

Re: Django pdfs

2020-04-22 Thread Lunga Baliwe
Maybe you can check Django FileField for upload and check what it looks like on the admin side. On Wed, Apr 22, 2020 at 6:09 PM Hella Nick wrote: > me to。do you help me? > > Perceval Maturure 于2020年4月22日 周三07:31写道: > >> Hi Dj

Re: Django pdfs

2020-04-23 Thread Lunga Baliwe
020 at 12:26 PM Perceval Maturure wrote: > Hi Lunga > When debug mode is False in production the url link of the file is not > accessible in admin which is ok for security reasons but in admin I can > download the file for preview > Regards > Perceval > > On Wed, 22 Apr 2020

Re: Django pdfs

2020-04-23 Thread Lunga Baliwe
Also check https://docs.djangoproject.com/en/3.0/ref/models/instances/#get-absolute-url Kind regards, Lunga Baliwe On Thu, Apr 23, 2020 at 1:04 PM Lunga Baliwe wrote: > Hi Perceval, > > On production I think you have to allow access to your MEDIA path, I > normally do this on the a

Re: Django pdfs

2020-04-23 Thread Lunga Baliwe
the file in django admin in production. > when debug is off i cant access to url to download the file, would be nice > to have an download button in admin, just clicking on it and download the > file. is the possible? > Regards > Perceval > > On Thu, Apr 23, 2020 at 1:13 PM

Re: How to create variables for an e-commerce website

2020-05-06 Thread Lunga Baliwe
maybe also check https://djangopackages.org/grids/g/ecommerce/ for django ecommerce packages On Wed, May 6, 2020 at 8:35 PM Motaz Hejaze wrote: > One solution is to make a 3 columns table , the first column is > 'property_name' , second column 'property_value' , third column is a > foriegn key t

Django REST, Djoser and LOGIN_REDIRECT_URL

2018-11-19 Thread Lunga Baliwe
Hello everyone. I am not an experienced Django dev, also I am new to Django REST and I'm working on a project that uses Django REST with Djoser. The requirement is that every-time a user logs-in, the user must be sent an sms for authentication(Two factor authentication). Is this possible with Dj

Re: STATIC FILES not working for admin site, projects and apps on DJANGO

2018-12-30 Thread Lunga Baliwe
Please have a look at this link https://docs.djangoproject.com/en/2.1/howto/deployment/wsgi/modwsgi/ on how to setup static files. You may also want to run python manage.py collectstatic On Sun, Dec 30, 2018 at 4:31 AM abel otugeme wrote: > This is how a site looks when i open it up in my browse

Re: get user that is member of two different group

2020-01-02 Thread Lunga Baliwe
Hi there, maybe you can use something like User.objects.filter(groups__name__in=['test1', 'test2']). Also check https://docs.djangoproject.com/en/3.0/ref/models/querysets/#in for examples of using __in On Thu, Jan 2, 2020 at 6:49 AM sum abiut wrote: > Hi, > I have two separate groups, for examp