Re: django-cache-machine with Redis

2014-04-24 Thread Ramón Carrillo
hing and django-cache-machine doesn't come with one for redis. Just > memcache and localmem. I'm wondering if its safe to just use the redis cache > i've setup. > > > On Thursday, April 24, 2014 9:30:49 AM UTC-7, Ramón Carrillo wrote: >> >> Hi Mike, >> >&g

Re: django-cache-machine with Redis

2014-04-24 Thread Ramón Carrillo
Hi Mike, You need a cache backend, you can write it by yourself [0] or use an existing one [1,2] [0] https://docs.djangoproject.com/en/1.6/topics/cache/#using-a-custom-cache-backend [1] https://github.com/niwibe/django-redis [2] https://github.com/sebleier/django-redis-cache On Wed, Apr 23, 201

Re: Admin - editable list

2014-04-24 Thread Ramón Carrillo
Hi Radhika, You mean this? https://docs.djangoproject.com/en/1.6/ref/contrib/admin/#django.contrib.admin.ModelAdmin.list_editable On Thu, Apr 24, 2014 at 10:52 AM, Radhika Srinivasan wrote: > Could you please update me on. How to create an admin-editable list > [check-list] in django? Thank you,

Re: get user profile info in templates

2014-04-24 Thread Ramón Carrillo
Hi, Did you set CustomUserAuth as your auth model in settings.py? [1] [0] https://docs.djangoproject.com/en/1.6/ref/settings/#std:setting-AUTH_USER_MODEL On Thu, Apr 24, 2014 at 3:41 AM, sourav wrote: > hi i am a newbie in django i am creating an app with customuser and profile > > i want get

Re: django, mod_wsgi, apache and sharing media files (video) from a separate directory

2014-04-20 Thread Ramón Carrillo
Hi Adam, >From your settings.py I guess the expanded url is something like /PROYECTOS/file.xyz, right? But, in your Apache alias your are serving the url /proyectos/ [0], and urls are case sensitive unless you're using mod_speling [1]. I think "Alias /PROYECTOS/ /PROYECTOS/" should do the trick.

Re: POST URL questions

2014-04-20 Thread Ramón Carrillo
Hi, POST variables are appended to the HTTP request body instead of the URL [0]. If you want a variable to be available in the request.POST dictionary, the browser must send it as a POST variable (in the request body). You could use a hidden input to do it: [0] https://developer.mozilla.org

Re: Questions about setting up my first app in django tutorial

2014-04-17 Thread Ramón Carrillo
The file is probably in the wrong directory or you're naming it incorrectly. It must be project_name/app_name/admin.py Maybe you're placing it in project_name/admin.py or project_name/project_name/admin.py On Thu, Apr 17, 2014 at 9:51 AM, Xiaofeng Feng wrote: > Yes. > INSTALLED_APPS = ( > '

Re: Deferred reverse geo coding upon record save/update

2014-04-17 Thread Ramón Carrillo
Hi Subodh, I would use use the same model as a queue. Add a address field to the sensordata model, make it nullable (null=True). Then write a custom django-admin command [0] that gets all the records in sensordata with null address, make the request to the geodecoder and save the result in the ad

Re: Including Page Fragments

2014-04-17 Thread Ramón Carrillo
I guess you are not supposed to use spaces there. IIRC spaces aren't allowed when using filters, neither (e.g. var|filter1 is ok, var | filter1 is not) You could find the exact reason digging in the template compiler code. https://github.com/django/django/blob/master/django/template/__init__.py

Re: I can't connect Django with SQL Anywhere 11 Database

2014-04-15 Thread Ramón Carrillo
Hi, You should use exactly the same parameters from your test_sqlany.py in your DATABASES dictionary. The sqlany-django documentation states that "(eg. ENG, which is required for client versions prior to v12.0.0)". In the DATABASES dictionary, you seem to misunderstand the ENG option with PORT

Re: Autoupdate

2014-04-15 Thread Ramón Carrillo
Basically, you need to get the data from the server using Ajax, and then modify the DOM to show the received data to the user. The easiest way I know is using jQuery, a JavaScript library that will spare you some headaches. The get (or ajax