Re: Freelance Django and Python work

2023-06-15 Thread Francis F. Massaquoi, Jr.
Hi, 

I am interested in the Django and Python Developer freelancing role, I am a 
Python Developer with great experience working Django, Flask, FastApi and 
other advance frameworks. Based on my experience I believed I am be a great 
candidate for this role. 

I remain available, if there are any additional information needed. 

Regards. 

Francis F. Massaquoi Jr. 
On Tuesday, June 13, 2023 at 11:30:40 AM UTC אורי wrote:

> Hi,
>
> I'm looking for a programmer to hire as a freelancer for Django and Python 
> work.
>
> - Experience with Python and Django
> - Experience with open source
> - Committed to the Django repository on GitHub - an advantage
> - Committed to other open-source projects in Python - an advantage
> - Experience with Stack Overflow -  an advantage
> - BSc or BA in computers or science (math, physics) -  an advantage
> - Knowledge of HTML, CSS, and JavaScript - an advantage
> - Can issue receipts
>
> I need about 5 hours per month on average. Some months I might need up to 
> 15 hours per month. Some months I might not need anything. The work is 
> remote. My project is open source. I can give you a free license to 
> PyCharm. My website is at https://en.speedy.net/ and 
> https://github.com/speedy-net/speedy-net
>
> To apply please send one email to jobs+jango...@speedy.net, with your 
> name, your email address, where you live, your experience, how many commits 
> you committed to Django, how many commits you committed to other open 
> source projects, a link to your profile on LinkedIn, a link to your profile 
> on GitHub, a link to your profile on Stack Overflow, your diploma if you 
> have any, how much you charge per hour and in which currency (I prefer USD 
> or Euro), and if you can issue receipts. If you don't have a profile on one 
> of the above websites please mention this too.
>
> Thanks,
> Uri Rodberg, Speedy Net.
> אורי
> u...@speedy.net
>

-- 
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/6228db4a-936d-43de-8bb2-173ade7b48f2n%40googlegroups.com.


Re: How to update old data with new data everyday from a scraper

2021-09-19 Thread Adib Neymar Jr.

Interesting, is there a way to peek for an existing record instead of 
calling get to see whether the record exists in the database? I'm thinking 
of making this snippet of code a bit more efficient

try:
   obj = Hackathon.objects.get(**each_dict)
except Hackathon.DoesNotExist:
   obj = Hackathon(**each_dict)
   obj.save()
On Saturday, September 18, 2021 at 10:31:46 AM UTC-4 J.T. wrote:

> Take a look at update_or_create()
>
>
> https://docs.djangoproject.com/en/3.2/ref/models/querysets/#update-or-create
>
> On Sat, Sep 18, 2021, 9:27 AM Adib Neymar Jr.  wrote:
>
>> Hello,
>>
>> What is a good way to compare new data with old data which is updated 
>> everyday with Django ORM? Basically I have a scraper which fetches 
>> hackathons everyday (basically just a celery task) and I want the newest to 
>> be unioned it with my master database which has the latest fetched 
>> hackathons from yesterday. I don't want to destroy my master database and 
>> then just upload everything that I just fetched since that seems wasteful. 
>> This is my strategy in approaching my problem but I am open to hear other 
>> options as well.
>>
>>
>> Thanks,
>>
>>
>>
>> Adib
>>
>> -- 
>> 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...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/CAN%3Doy7JkqHEtaizgKtHniofSS7T%2BybqVer0mJc1uRPRLupUSdQ%40mail.gmail.com
>>  
>> <https://groups.google.com/d/msgid/django-users/CAN%3Doy7JkqHEtaizgKtHniofSS7T%2BybqVer0mJc1uRPRLupUSdQ%40mail.gmail.com?utm_medium=email_source=footer>
>> .
>>
>

-- 
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/07e19d5a-579a-4ec6-91f0-4ccba9790d0fn%40googlegroups.com.


How to update old data with new data everyday from a scraper

2021-09-18 Thread Adib Neymar Jr.
Hello,

What is a good way to compare new data with old data which is updated
everyday with Django ORM? Basically I have a scraper which fetches
hackathons everyday (basically just a celery task) and I want the newest to
be unioned it with my master database which has the latest fetched
hackathons from yesterday. I don't want to destroy my master database and
then just upload everything that I just fetched since that seems wasteful.
This is my strategy in approaching my problem but I am open to hear other
options as well.


Thanks,



Adib

-- 
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/CAN%3Doy7JkqHEtaizgKtHniofSS7T%2BybqVer0mJc1uRPRLupUSdQ%40mail.gmail.com.


How to use Topaz T-S460-HSB-R USB Electronic Signature Capture Pad in a Django Project

2020-10-09 Thread Francis F. Massaquoi, Jr.
Hi, 

I want to use Topaz Electronic Signature Capture Pad in my Django Web 
Application is it possible? Is there a way to integrate this signature in 
my Web Application I'm using https://github.com/szimek/signature_pad.

Below is a photo of the signature pad.
[image: 61b9noIw2mL._AC_SL1274_.jpg]

-- 
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/054a19d6-2cee-438c-ab65-10f4a702155cn%40googlegroups.com.


Re: Tutorial Part 1

2020-05-08 Thread Luqman Jr
Hello
Did you create urls.py under polls app?
You should have urls.py under polls app which will list all urls fall under 
this app.
Then share with us polls/urls.py and polls/views.py so that we can help more on 
this.
On 9 May 2020, 03:11 +0300, Randy Zeitvogel , wrote:
> I just started working with Django in the last couple of days.
> First environment is Ubuntu 19.10, python 3.7.5 and Django 3.1.  Second 
> environment is Fedora 31, python 3.7.5, and Django 3.0.6.
> In both cases after I create the polls app and try it out, I get this:
>
> Page not found (404)
> Request Method:
> GET
> Request URL:
> http://localhost:8000/polls/
> Using the URLconf defined in mysite.urls, Django tried these URL patterns, in 
> this order:
>
> 1. admin/
>
> The current path, polls/, didn't match any of these.
> You're seeing this error because you have DEBUG = True in your Django 
> settings file. Change that to False, and Django will display a standard 404 
> page.
>
> The feedback from the development web server (python manage.py runserver) is:
>
> jango version 3.0.6, using settings 'mysite.settings'
> Starting development server at http://127.0.0.1:8000/
> Quit the server with CONTROL-C.
> Not Found: /polls/
> [08/May/2020 17:28:16] "GET /polls/ HTTP/1.1" 404 1957
>
> My mysite/urls.py looks like this:
>
> from django.contrib import admin
> from django.urls import include, path
>
> urlpatterns = [
>path('polls/', include('polls.urls')),
>path('admin/', admin.site.urls),
> ]
>
> Any help would be appreciated.
>
> --
> 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/b7b3b071-7255-4fc1-84c8-db7d1766e5dd%40googlegroups.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/3baac878-0c7c-4bec-8788-5d04b21b%40Spark.


need help on multiple file uploads

2020-03-12 Thread Robb Rodirguez Jr.
im having to with multiple file uploads, when i tried to upload files only 
1 file will be saved..

here's my code:
views.py

def attachments(request):
to = TravelOrder.objects.order_by('-date_filling').last()
if request.method == 'POST':
form = AttachmentsForm(request.POST, request.FILES)
if form.is_valid():
for f in request.FILES.getlist('attachment'):
instance = form.save(commit=False)
instance.travel_order = to
instance.attachment = f
instance.save()
print('YEW')
return redirect('attach')

else:
form = AttachmentsForm()

context = {
'form': form
}
return render(request, 'employee/attachments.html', context)

models.py

class TravelOrder(models.Model):
created_by = models.CharField(max_length=255)
start_date = models.DateField(auto_now=False)
end_date = models.DateField(auto_now=False)
wfp = models.CharField(max_length=255, verbose_name='Wfp Where to be 
charged')
purpose_of_travel = models.CharField(max_length=255)
region = models.ForeignKey(Region, on_delete=models.CASCADE)
venue = models.CharField(max_length=255)
date_filling = models.DateTimeField(auto_now_add=True)
status = models.CharField(max_length=15)

def __str__(self):
return self.purpose_of_travel


class Attachements(models.Model):
at_id = models.AutoField(primary_key=True)
travel_order = models.ForeignKey(TravelOrder, on_delete=models.CASCADE)
attachment = models.FileField(upload_to='attachment/')


forms.py

class AttachmentsForm(forms.ModelForm):
class Meta:
model = Attachements
exclude = ['travel_order']
fields = ('attachment',)
widgets = {
'attachment': forms.ClearableFileInput(attrs={'multiple':True})
}



hope you can help me guys. thank you..

-- 
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/6d59b634-b6d9-4597-b502-012de4ac3c89%40googlegroups.com.


Running into a "Cannot assign... must be a ...instance" error

2020-03-04 Thread Joey Jo Jo Jr
New to Django.

I'm trying to set up a simple comment form where I can add a title for the 
comment, content of the comment, and attach the username of the user that 
is currently signed in and posting it.

I run into the following error when running it:

Cannot assign "'john'": "Entry.author" must be a "User" instance.


 I think I understand what's happening here, however I'm having a hard time 
figuring out how to implement it properly.


*Here's my model code:*


class Entry(models.Model):

title = models.CharField(max_length=60)

content = models.TextField(max_length=500)

author = models.ForeignKey(User, on_delete=models.CASCADE, null=True)



def __str__(self):

return f"{self.id}"


*Here's my view code:*


@login_required

def add(request):

if request.method == "POST":

entry = Entry(

title = request.POST["title"],

content = request.POST["content"],

author = request.POST["username"]

)


entry.save()


return render(request, "articles/index.html", {

"entries": Entry.objects.all()

})


else:

return render(request, "articles/add.html", {

"username": request.user

})


*And here's my form code in my template:*


{% block body %}

New Entry



{% csrf_token %}




Title:







Content:



Content goes here










{% endblock %}


-- 
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/e0bb05c3-ecee-4f75-97ca-a659cb7e6181%40googlegroups.com.


Many to Many relationships in template

2020-02-27 Thread Robb Rodirguez Jr.
Good day guys, im new to django im having in many to many relationship 
display in template

How can display this into a normal list..

from . 
, , , , 
]>

to.
webadmin
kim
sem
quinito
user1

Here's my code

model.py 

class ListOfUser(models.Model):
users = models.ManyToManyField(User, verbose_name='List of User')



views.py

def listofusers(request):
userlist = ListOfUser.objects.get(id=1)

form = ListofUserForms()

context = {
'form': form,
'userlist': userlist
}
return render(request, 'listofusers.html', context)


template

{{userlist.users.all}}


-- 
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/f3e604a7-5613-4f12-8aa6-526b19ae0fc7%40googlegroups.com.


New to Django. Trying to wrap my head around markdown to html conversion using regex

2020-02-20 Thread Joey Jo Jo Jr
Hello all,

I'm working on a class assignment, so I'm not seeking a specific 
answer/code, but I'm just trying to figure out a general process.

The task is this...

I have some markdown files located in a directory, however when running the 
website they need to be displayed as html.  Because this is a learning 
assignment, no markdown conversion libraries are allowed.

So I'm tasked with using regular expressions to convert.  I understand 
regular expressions and have already formulated a few to change things like 
**text** to text and so on, but being so new to Django and 
still figuring out how it works, I'm just completely flummoxed on the 
execution/implementation.

So any general advice would be appreciated.

-- 
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/4d3fe147-d502-40c2-a866-d72bb30f8352%40googlegroups.com.


null value in column “ProjectName_id” violates not-null constraint

2019-09-11 Thread Robb Rodirguez Jr.
Hello need help on null value in column "ProjectName_id" violates not-null 
constraint, im new to django
i want my ProjectName_id (Foreignkey) is the same/equal id that user choose 
in my majordetails = ProjectNameInviToBid.objects.get(id=sid) please help 
me...

my model views

class ProjectNameInviToBid(models.Model):
ProjectName = models.CharField(max_length=255, verbose_name='Project Name', 
null=True)
DateCreated = models.DateField(auto_now=True)

class InviToBid(models.Model):
today = date.today()
ProjectName = models.ForeignKey('ProjectNameInviToBid', 
on_delete=models.CASCADE)
NameOfFile = models.CharField(max_length=255, verbose_name='Name of File')

my views.py

def project_name_details(request, sid):

majordetails = ProjectNameInviToBid.objects.get(id=sid)

if request.method == 'POST':
form = invitoBidForm(request.POST, request.FILES)
if form.is_valid():
*majordetails = InviToBid.ProjectName*
form.save()
messages.success(request, 'File has been Uploaded')
else:
form = invitoBidForm()

args = {
'majordetails': majordetails,
'form': form

}
return render(request,'content/invitoBid/bacadmininvitoBid.html', args)

-- 
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/f25acfab-8fc3-4597-9905-376d9d27f0b9%40googlegroups.com.


Re: How to make Django Project Mobile Compatible

2019-05-11 Thread Luqman Jr
Between Angular and React which one is the best to be used with Django?
On 11 May 2019, 10:38 +0300, Balaji Shetty , wrote:
> Hi  Nick Sarbicki
>
> Thank You very much for your reply.
> May I know which framework is to be learned for necessary implementation?.
> It should be easy to earn with help support.
>
> > On Sat, May 11, 2019 at 12:40 PM Nick Sarbicki  
> > wrote:
> > > Hi,
> > >
> > > Django is completely naive to whether a frontend is mobile friendly or 
> > > not.
> > >
> > > You can use react or angular, you can also use many other frontend 
> > > frameworks. Django can work with all frontend frameworks. The choice is 
> > > entirely up to you.
> > >
> > > > On Sat, 11 May 2019, 08:04 Balaji Shetty,  
> > > > wrote:
> > > > > Hi
> > > > >
> > > > > How can i make my Django Project view Mobile Compatible.
> > > > > Should i use Angular JS / React  . Please let me know.
> > > > >
> > > > > Thanks in Advance
> > > > >
> > > > > --
> > > > > Mr. Shetty Balaji S.
> > > > > Asst. Professor
> > > > > Department of Information Technology,
> > > > > SGGS Institute of Engineering & Technology, Vishnupuri, 
> > > > > Nanded.MH.India
> > > > > Official: bsshe...@sggs.ac.in
> > > > >   Mobile: +91-9270696267
> > > > >
> > > > > --
> > > > > 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 post to this group, send email to django-users@googlegroups.com.
> > > > > Visit this group at https://groups.google.com/group/django-users.
> > > > > To view this discussion on the web visit 
> > > > > https://groups.google.com/d/msgid/django-users/CAECSbOveKW_5aohHGKCJcVxPtwMg-wTBC8ttVRpPJc3YOA7dKg%40mail.gmail.com.
> > > > > For more options, visit https://groups.google.com/d/optout.
> > > --
> > > 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 post to this group, send email to django-users@googlegroups.com.
> > > Visit this group at https://groups.google.com/group/django-users.
> > > To view this discussion on the web visit 
> > > https://groups.google.com/d/msgid/django-users/CAGuvt92gdOmQSsZrW2BixcsFfc17DWbia0mfvv4rUYr7WZtyfw%40mail.gmail.com.
> > > For more options, visit https://groups.google.com/d/optout.
>
>
> --
> Mr. Shetty Balaji S.
> Asst. Professor
> Department of Information Technology,
> SGGS Institute of Engineering & Technology, Vishnupuri, Nanded.MH.India
> Official: bsshe...@sggs.ac.in
>   Mobile: +91-9270696267
>
> --
> 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 post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/CAECSbOszXSWCEkEtxTmXQuK53k-A-AW_pPJVri_NWEqoovXunA%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/00348a15-c851-4117-8a26-91fd5cd21a34%40Spark.
For more options, visit https://groups.google.com/d/optout.


Re: log out a user when user closes tab or browser

2019-03-21 Thread Marconi Moreto Jr.
How about on `window.onbeforeunload` you delete the session id from the cookie, 
on next visit no session id to send so should be considered logged-out.

On Thu, Mar 21, 2019, at 10:17 PM, KadirCEBEL wrote:
> You can use jquery. you can write a function like logout (in the view)
> after that when browser tab is closed (you have to check with jquery
> code) you can kill user session. 
> 
> Prş, 2019-03-21 tarihinde 17:15 +0330 saatinde, Mohammad Etemaddar
> yazdı:
> > I have a suggest for you. Its non standard.
> > 
> > First create a javascript infinite loop to make a get call every 1
> > minute.
> > Also make session expiration time at 2 minutes. So if tabs closed the
> > session will expire at 1 minute.
> > 
> > On Thu, 21 Mar 2019 15:17 Christian Ledermann, <
> > christian.lederm...@gmail.com> wrote:
> > > SESSION_EXPIRE_AT_BROWSER_CLOSE works for me 
> > > but only when you close the browswer, closing a tab will not log
> > > you out
> > > also it depends on the browser (firefox seemed in the past to
> > > ignore this)
> > > 
> > > On Thu, 21 Mar 2019 at 05:34, Sam W  wrote:
> > > > Is there a way in Django to  log out a user when user closes tab
> > > > or browser?
> > > > 
> > > > This one "SESSION_EXPIRE_AT_BROWSER_CLOSE =True" Doesn't work
> > > > 
> > > > -- 
> > > > 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 post to this group, send email to 
> > > > django-users@googlegroups.com.
> > > > Visit this group at https://groups.google.com/group/django-users.
> > > > To view this discussion on the web visit 
> > > > https://groups.google.com/d/msgid/django-users/644cca74-0443-4c71-8d8e-7326a252eb2e%40googlegroups.com
> > > > .
> > > > For more options, visit https://groups.google.com/d/optout.
> > > 
> > > 
> > > -- 
> > > Best Regards,
> > > 
> > > Christian Ledermann
> > > 
> > > Newark-on-Trent - UK
> > > Mobile : +44 7474997517
> > > 
> > > https://uk.linkedin.com/in/christianledermann
> > > https://github.com/cleder/
> > > 
> > > 
> > > <*)))>{
> > > 
> > > If you save the living environment, the biodiversity that we have
> > > left,
> > > you will also automatically save the physical environment, too. But
> > > If
> > > you only save the physical environment, you will ultimately lose
> > > both.
> > > 
> > > 1) Don’t drive species to extinction
> > > 
> > > 2) Don’t destroy a habitat that species rely on.
> > > 
> > > 3) Don’t change the climate in ways that will result in the above.
> > > 
> > > }<(((*>
> -- 
> 
> Teşekkürler,
> http://www.kadircebel.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 post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/07d89baa005bb001a3c2b034b073264edd05c40c.camel%40gmail.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/bbe838b9-56cd-4411-bd46-1e1f1001c5e1%40www.fastmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: URL Concatenation Issue

2018-05-31 Thread John Regis, Jr.
In blog/urls.py I have my my homepage mapped to my view.index. Are you
saying to also map view.about as well? Also, when you say namespace are you
saying to create a dictionary and include my index (blog) and about pages
as values? New to Python so I'm trying to still wrap my head around the
utilization of python dictionaries.

On Wed, May 30, 2018 at 10:42 PM, Aditya Singh 
wrote:

> For this you have provide an app inside your urls and refer to it as
> home:about where home is the app name and about is the page to be rendered.
> Also provide namespace in the urls so that the url is linked to the app
> name.
> Kind Regards,
> Aditya
>
> On Thu, May 31, 2018, 7:54 AM Spence Patrick 
> wrote:
>
>> Is your link tag href="./about" or href="/about/"
>>
>> On Wed, May 30, 2018, 19:14  wrote:
>>
>>> Hello,
>>>
>>> I'm debugging an issue that I'm having with my URL patterns. In my HTML
>>> I have an "about me" page that is linking to an about.html file in my
>>> templates/blog/ directory. When I load the homepage and click on the "about
>>> me" link than "domain.com/about/" loads, which matches the URL pattern
>>> in my blog/urls.py file, and the page renders perfectly fine.
>>>
>>> However, while on the "about me" page I can't link to any other page
>>> because the URL pattern starts to concatenate instead of overwrite (if that
>>> makes any sense). For example, if I click on "about me" again than Django
>>> tries to load domain.com/about/about and I get an error.
>>>
>>> I'm using a python 3.5.2 venv and I'm running Django 2.0.5. I'm new to
>>> programming by the way (to include Python, Django, HTML/CSS).
>>>
>>> --
>>> 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 post to this group, send email to django-users@googlegroups.com.
>>> Visit this group at https://groups.google.com/group/django-users.
>>> To view this discussion on the web visit https://groups.google.com/d/
>>> msgid/django-users/1213b3f9-c74b-4af9-b585-61f2423720f0%
>>> 40googlegroups.com
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
>> 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 post to this group, send email to django-users@googlegroups.com.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit https://groups.google.com/d/
>> msgid/django-users/CAD6-5Ch7%3DSTQGPdPg3iU%3Dvy2H1GMqcFnycBqb5bquXGDDV6ZB
>> A%40mail.gmail.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/
> topic/django-users/UB1iqDXjy3g/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/django-users/CAEPfumjqtuz9bTfh%2Bfk%3D8iFYOKUQwSGpQqwwuyqX%2BQ%
> 3DABgL3%3Dw%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2BtE7VRZfAQo58YojBDg0WShaM3h2PBu3B5-VHKyXKP870HYkQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: URL Concatenation Issue

2018-05-31 Thread John Regis, Jr.
I have *href="about/"*. Also tried *href="./about/"* and same result.

On Wed, May 30, 2018 at 10:23 PM, Spence Patrick  wrote:

> Is your link tag href="./about" or href="/about/"
>
> On Wed, May 30, 2018, 19:14  wrote:
>
>> Hello,
>>
>> I'm debugging an issue that I'm having with my URL patterns. In my HTML I
>> have an "about me" page that is linking to an about.html file in my
>> templates/blog/ directory. When I load the homepage and click on the "about
>> me" link than "domain.com/about/" loads, which matches the URL pattern
>> in my blog/urls.py file, and the page renders perfectly fine.
>>
>> However, while on the "about me" page I can't link to any other page
>> because the URL pattern starts to concatenate instead of overwrite (if that
>> makes any sense). For example, if I click on "about me" again than Django
>> tries to load domain.com/about/about and I get an error.
>>
>> I'm using a python 3.5.2 venv and I'm running Django 2.0.5. I'm new to
>> programming by the way (to include Python, Django, HTML/CSS).
>>
>> --
>> 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 post to this group, send email to django-users@googlegroups.com.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit https://groups.google.com/d/
>> msgid/django-users/1213b3f9-c74b-4af9-b585-61f2423720f0%
>> 40googlegroups.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/
> topic/django-users/UB1iqDXjy3g/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/django-users/CAD6-5Ch7%3DSTQGPdPg3iU%3Dvy2H1GMqcFnycBqb5bquXGDDV6ZB
> A%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2BtE7VRQvg2_fir6merUXc1dzzMnupdnbBypTQyguwErLycuFA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Message from a django beginner user

2018-05-15 Thread Francis F. Massaquoi, Jr.
Hi, I'm Francis F. Massaquoi, Jr. with great interest in learning django 
2.0, which is the latest version, I have been searching on youtube for a 
channel that have the latest version tutorial, I have not really find one, 
can someone please help me with a pdf or website, where I can learn django 
to the best, I have been reading some pdf, I have the basic knowledge, but 
I need to advance my knowledge. Or if you can connect with me on skype, 
this is my skype username: francisfmassaquoijr, or if you have a skype 
group, you can please add me, or give me your skype username...

Your urgent response will highly be appreciated. 

Thanks to the admin for accepting me..

We do it the django way, because it's the best way to web app 
development.

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/e22ff629-023d-41dc-bb08-7d0d0f87fd42%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Not Found "/lobby/" django-channels routing error

2018-04-03 Thread Mike Johnson Jr
routing.py

from channels import include, route
from chat import consumers
from . import game_consumers

channel_routing = [
#game routing
route('websocket.connect', game_consumers.ws_connect_lobby, 
path=r"^/lobby/$"),
route('websocket.receive', game_consumers.ws_receive_lobby, 
path=r"^/lobby/$"),
route('websocket.disconnect', game_consumers.ws_disconnect_lobby, 
path=r"^/lobby/$"),

app.js

Websocket = {
lobby_socket: null,
setup_ws_lobby : function(){
Websocket.lobby_socket = new ReconnectingWebSocket(Websocket.ws_scheme 
+ '://' + window.location.host + '/lobby/');
Websocket.lobby_socket.onmessage = function(message) {
//nothing yet
};
},
}
Websocket.setup_ws_lobby();

The url is `127.0.0.1:8000/game`. `Websocket.setup_ws_lobby()` is executed 
on page load. I don't see what I'm doing wrong. I get the error `Not Found: 
/lobby/` in my `python manage.py runserver` console when I load the page. 
My routes are clearly set and my js setup seems to route to those routes. 
Can anyone help? Thanks in advance.

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/003d30eb-b81a-4c7a-8b93-aeece642ff79%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Websocket, an existing connection was forcibly closed by the remote host. django-channels

2017-06-25 Thread Mike Johnson Jr


So I'm getting the error as described in the title of this post.

I'm following this tutorial: 
https://gearheart.io/blog/creating-a-chat-with-django-channels/

Here's the full traceback:

In [1]: import websocket
In [2]: ws = websocket.WebSocket()
In [3]: 
ws.connect("ws://localhost:8000")---
error Traceback (most recent call 
last) in ()> 1 
ws.connect("ws://localhost:8000")

c:\Python27\lib\site-packages\websocket\_core.pyc in connect(self, url, 
**options)
212
213 try:--> 214 self.handshake_response = 
handshake(self.sock, *addrs, **options)
215 self.connected = True
216 except:

c:\Python27\lib\site-packages\websocket\_handshake.pyc in handshake(sock, 
hostname, por
t, resource, **options)
 67 dump("request header", header_str)
 68---> 69 status, resp = _get_resp_headers(sock)
 70 success, subproto = _validate(resp, key, 
options.get("subprotocols"))
 71 if not success:

c:\Python27\lib\site-packages\websocket\_handshake.pyc in 
_get_resp_headers(sock, succe
ss_status)
125
126 def _get_resp_headers(sock, success_status=101):--> 127 status, 
resp_headers = read_headers(sock)
128 if status != success_status:
129 raise WebSocketBadStatusException("Handshake status %d", status)

c:\Python27\lib\site-packages\websocket\_http.pyc in read_headers(sock)
224
225 while True:--> 226 line = recv_line(sock)
227 line = line.decode('utf-8').strip()
228 if not line:

c:\Python27\lib\site-packages\websocket\_socket.pyc in recv_line(sock)
 99 line = []
100 while True:--> 101 c = recv(sock, 1)
102 line.append(c)
103 if c == six.b("\n"):

c:\Python27\lib\site-packages\websocket\_socket.pyc in recv(sock, bufsize)
 78
 79 try:---> 80 bytes_ = sock.recv(bufsize)
 81 except socket.timeout as e:
 82 message = extract_err_message(e)

error: [Errno 10054] An existing connection was forcibly closed by the remote 
host

I have redis running, manage.py runserver running, and I'm using 
django-channels. This is my first time working with websockets. Can anyone 
help out and let me know what's wrong?
python  django 
 websocket 
 redis 
 django-channels 


-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/878e70cd-4e39-4b1f-87bd-da7ddb03605b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Installing Django

2017-01-30 Thread Danny Jr Chu
Ok, thanks.

On Monday, January 30, 2017 at 8:39:29 PM UTC+8, Antonis Christofides wrote:
>
> If you want to build something like Upwork, then Django is definitely a 
> good option, but of course, as you have guessed, you have really much 
> learning to do.
>
> Regards,
>
> Antonis
>
> Antonis Christofideshttp://djangodeployment.com
>
>
> On 01/30/2017 02:27 PM, Danny Jr Chu wrote:
>
> I will consider your professional advise Antonis. However, what I would 
> like to build is a (1st) freelancer website (upwork or like), I know that 
> there are hundreds of these right now, but with a subtle twist and to offer 
> both client and contractor something more, it may be feasible. (2nd) I fail 
> to find Angel Investor so I have to cut cost everything to the rock bottom, 
> I have a lot of time available to study and (plus motivation of course) and 
> (3nd) I've done number of websites with blogspot (but plugins are paid 
> monthly). So, I was thinking to do it myself the backbone with Django. 
> Please tell me more what I should have know to bring this project to life. 
>
> Thanks for your support,
> Danny
>
> On Monday, January 30, 2017 at 6:54:58 PM UTC+8, Antonis Christofides 
> wrote: 
>>
>> If you want to just make a web site, Django is the wrong thing for you. 
>> Django is not for building web sites, it's for building web applications. 
>> You might instead want to look at Mezzanine or Django-CMS or Wagtail (these 
>> are all software for building web sites and they're based on Django), or, 
>> if being based on Django is not a requirement, you can use Wordpress or 
>> Drupal. There are really many more, there must be tens. I believe the most 
>> popular is Wordpress.
>>
>> If you use any of these and install it on a server, you will only need to 
>> pay for the domain and hosting (and spend considerable time setting it up).
>>
>> If you use wordpress.com, they set it up for you, so you don't need to 
>> install it yourself, and the cost is probably less than getting a virtual 
>> server to install stuff yourself.
>>
>> I don't want to discourage you from using Django if it's for you. I just 
>> don't want you to get the impression that "Django is 
>> bad/complicated/painful" when you just might be using it for the wrong 
>> purpose.
>>
>> Regards,
>>
>> Antonis
>>
>> Antonis Christofideshttp://djangodeployment.com
>>
>>
>> On 01/30/2017 12:33 PM, Danny Jr Chu wrote:
>>
>> Hi Antonis,  
>>
>> No I have not yet tried wordpress, but the answer is budget wise. I would 
>> think that after these exercises, I am just going to pay (I think) the 
>> domain and hosting only.
>>
>> Regards,
>> Danny
>>
>> On Monday, January 30, 2017 at 6:16:27 PM UTC+8, Antonis Christofides 
>> wrote: 
>>>
>>> I wish I could build a website out of my imaginary
>>>
>>> Hello,
>>>
>>> depending on what you mean with "build a website", you may be looking at 
>>> the wrong thing. Have you tried, for example, to build a web site at 
>>> wordpress.com? If yes, why is this not sufficient for you and you want 
>>> to learn Django?
>>>
>>> Regards,
>>>
>>> Antonis
>>>
>>> Antonis Christofideshttp://djangodeployment.com
>>>
>>>
>>> On 01/30/2017 05:05 AM, Danny Jr Chu wrote:
>>>
>>> Guys, please help. I am new with Python and Django, I mean I don't have 
>>> any clue what's going on (don't even know how to encode), but I wish I 
>>> could build a website out of my imaginary. I know this will goes miles and 
>>> miles... I am trying to install Django but couple of errors occur :  
>>>
>>> PS C:\Users\Luv> easy_install django
>>> Searching for django
>>> Reading https://pypi.python.org/simple/django/
>>> Downloading 
>>> https://pypi.python.org/packages/c3/c2/6096bf5d0caa4e3d5b985ac72e3a0c795e37fa7407d6c85460b2a105b467/Django-1
>>> .10.5.tar.gz#md5=3fce02f1e6461fec21f1f15ea7489924
>>> Best match: Django 1.10.5
>>> Processing Django-1.10.5.tar.gz
>>> Writing 
>>> C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10.5\setup.cfg
>>> Running Django-1.10.5\setup.py -q bdist_egg --dist-dir 
>>> C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10
>>> .5\egg-dist-tmp-k4dzxio3
>>> no previously-included directories found matching 
>>> 'django\contrib\admin\bin'
>>> warning: no previously-included files matching '__pycache

Re: Installing Django

2017-01-30 Thread Danny Jr Chu
I will consider your professional advise Antonis. However, what I would 
like to build is a (1st) freelancer website (upwork or like), I know that 
there are hundreds of these right now, but with a subtle twist and to offer 
both client and contractor something more, it may be feasible. (2nd) I fail 
to find Angel Investor so I have to cut cost everything to the rock bottom, 
I have a lot of time available to study and (plus motivation of course) and 
(3nd) I've done number of websites with blogspot (but plugins are paid 
monthly). So, I was thinking to do it myself the backbone with Django. 
Please tell me more what I should have know to bring this project to life. 

Thanks for your support,
Danny

On Monday, January 30, 2017 at 6:54:58 PM UTC+8, Antonis Christofides wrote:
>
> If you want to just make a web site, Django is the wrong thing for you. 
> Django is not for building web sites, it's for building web applications. 
> You might instead want to look at Mezzanine or Django-CMS or Wagtail (these 
> are all software for building web sites and they're based on Django), or, 
> if being based on Django is not a requirement, you can use Wordpress or 
> Drupal. There are really many more, there must be tens. I believe the most 
> popular is Wordpress.
>
> If you use any of these and install it on a server, you will only need to 
> pay for the domain and hosting (and spend considerable time setting it up).
>
> If you use wordpress.com, they set it up for you, so you don't need to 
> install it yourself, and the cost is probably less than getting a virtual 
> server to install stuff yourself.
>
> I don't want to discourage you from using Django if it's for you. I just 
> don't want you to get the impression that "Django is 
> bad/complicated/painful" when you just might be using it for the wrong 
> purpose.
>
> Regards,
>
> Antonis
>
> Antonis Christofideshttp://djangodeployment.com
>
>
> On 01/30/2017 12:33 PM, Danny Jr Chu wrote:
>
> Hi Antonis,  
>
> No I have not yet tried wordpress, but the answer is budget wise. I would 
> think that after these exercises, I am just going to pay (I think) the 
> domain and hosting only.
>
> Regards,
> Danny
>
> On Monday, January 30, 2017 at 6:16:27 PM UTC+8, Antonis Christofides 
> wrote: 
>>
>> I wish I could build a website out of my imaginary
>>
>> Hello,
>>
>> depending on what you mean with "build a website", you may be looking at 
>> the wrong thing. Have you tried, for example, to build a web site at 
>> wordpress.com? If yes, why is this not sufficient for you and you want 
>> to learn Django?
>>
>> Regards,
>>
>> Antonis
>>
>> Antonis Christofideshttp://djangodeployment.com
>>
>>
>> On 01/30/2017 05:05 AM, Danny Jr Chu wrote:
>>
>> Guys, please help. I am new with Python and Django, I mean I don't have 
>> any clue what's going on (don't even know how to encode), but I wish I 
>> could build a website out of my imaginary. I know this will goes miles and 
>> miles... I am trying to install Django but couple of errors occur :  
>>
>> PS C:\Users\Luv> easy_install django
>> Searching for django
>> Reading https://pypi.python.org/simple/django/
>> Downloading 
>> https://pypi.python.org/packages/c3/c2/6096bf5d0caa4e3d5b985ac72e3a0c795e37fa7407d6c85460b2a105b467/Django-1
>> .10.5.tar.gz#md5=3fce02f1e6461fec21f1f15ea7489924
>> Best match: Django 1.10.5
>> Processing Django-1.10.5.tar.gz
>> Writing 
>> C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10.5\setup.cfg
>> Running Django-1.10.5\setup.py -q bdist_egg --dist-dir 
>> C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10
>> .5\egg-dist-tmp-k4dzxio3
>> no previously-included directories found matching 
>> 'django\contrib\admin\bin'
>> warning: no previously-included files matching '__pycache__' found 
>> anywhere in distribution
>> creating c:\program files (x86)\lib\site-packages\django-1.10.5-py3.6.egg
>> Extracting django-1.10.5-py3.6.egg to c:\program files 
>> (x86)\lib\site-packages
>> Adding django 1.10.5 to easy-install.pth file
>> Installing django-admin.py script to c:\program files (x86)\Scripts
>> error: [Errno 13] Permission denied: 'c:\\program files 
>> (x86)\\Scripts\\django-admin.py'
>>
>> -- 
>> 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...@googlegroups.com.
>> To post to this group, send email to django...@googlegroups.com

Re: Installing Django

2017-01-30 Thread Danny Jr Chu
Hi Antonis, 

No I have not yet tried wordpress, but the answer is budget wise. I would 
think that after these exercises, I am just going to pay (I think) the 
domain and hosting only.

Regards,
Danny

On Monday, January 30, 2017 at 6:16:27 PM UTC+8, Antonis Christofides wrote:
>
> I wish I could build a website out of my imaginary
>
> Hello,
>
> depending on what you mean with "build a website", you may be looking at 
> the wrong thing. Have you tried, for example, to build a web site at 
> wordpress.com? If yes, why is this not sufficient for you and you want to 
> learn Django?
>
> Regards,
>
> Antonis
>
> Antonis Christofideshttp://djangodeployment.com
>
>
> On 01/30/2017 05:05 AM, Danny Jr Chu wrote:
>
> Guys, please help. I am new with Python and Django, I mean I don't have 
> any clue what's going on (don't even know how to encode), but I wish I 
> could build a website out of my imaginary. I know this will goes miles and 
> miles... I am trying to install Django but couple of errors occur :  
>
> PS C:\Users\Luv> easy_install django
> Searching for django
> Reading https://pypi.python.org/simple/django/
> Downloading 
> https://pypi.python.org/packages/c3/c2/6096bf5d0caa4e3d5b985ac72e3a0c795e37fa7407d6c85460b2a105b467/Django-1
> .10.5.tar.gz#md5=3fce02f1e6461fec21f1f15ea7489924
> Best match: Django 1.10.5
> Processing Django-1.10.5.tar.gz
> Writing 
> C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10.5\setup.cfg
> Running Django-1.10.5\setup.py -q bdist_egg --dist-dir 
> C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10
> .5\egg-dist-tmp-k4dzxio3
> no previously-included directories found matching 
> 'django\contrib\admin\bin'
> warning: no previously-included files matching '__pycache__' found 
> anywhere in distribution
> creating c:\program files (x86)\lib\site-packages\django-1.10.5-py3.6.egg
> Extracting django-1.10.5-py3.6.egg to c:\program files 
> (x86)\lib\site-packages
> Adding django 1.10.5 to easy-install.pth file
> Installing django-admin.py script to c:\program files (x86)\Scripts
> error: [Errno 13] Permission denied: 'c:\\program files 
> (x86)\\Scripts\\django-admin.py'
>
> -- 
> 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...@googlegroups.com .
> To post to this group, send email to django...@googlegroups.com 
> .
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/86091d59-6578-4e85-9be0-d24beb1f5b84%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/django-users/86091d59-6578-4e85-9be0-d24beb1f5b84%40googlegroups.com?utm_medium=email_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/6cafee05-1c3f-40cf-aeab-00f98493cf6b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Installing Django

2017-01-30 Thread Danny Jr Chu
Hello Jani, you are an angel :) 

I have un-installed it and re-install to the right folder.. thanks a lot. 

On Monday, January 30, 2017 at 4:34:27 PM UTC+8, Jani Tiainen wrote:
>
> Hi,
>
> First you seem to be installing Django to Windows, it adds certain 
> complexity all together, it's not impossible though.
>
> By given paths for some strange reason easy_install seems to thing that 
> you have installed your Python to "C:\program files (x86)\" directory (not 
> subdirectory there or anything, to root of that folder), that is quite 
> wrong, first it requires allways adminstrative access to install anything 
> there, and second it's not standard place, which would be something like 
> C:\PythonXX\ (to avoid permission problems). 
>
> First thing to you is now to figure out did you managed to mess up Python 
> installation by putting it to incorrect path and fix by removing all 
> components and then installing it to more proper location. 
>
> Depending on Python modules you want to use some may require compiling 
> which is not simple under Windows, so if you can use some Linux (or some 
> other unix variant) box or something like virtual machine setting up 
> environment is much easier.
>
> On 30.01.2017 05:05, Danny Jr Chu wrote:
>
> Guys, please help. I am new with Python and Django, I mean I don't have 
> any clue what's going on (don't even know how to encode), but I wish I 
> could build a website out of my imaginary. I know this will goes miles and 
> miles... I am trying to install Django but couple of errors occur :  
>
> PS C:\Users\Luv> easy_install django
> Searching for django
> Reading https://pypi.python.org/simple/django/
> Downloading 
> https://pypi.python.org/packages/c3/c2/6096bf5d0caa4e3d5b985ac72e3a0c795e37fa7407d6c85460b2a105b467/Django-1
> .10.5.tar.gz#md5=3fce02f1e6461fec21f1f15ea7489924
> Best match: Django 1.10.5
> Processing Django-1.10.5.tar.gz
> Writing 
> C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10.5\setup.cfg
> Running Django-1.10.5\setup.py -q bdist_egg --dist-dir 
> C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10
> .5\egg-dist-tmp-k4dzxio3
> no previously-included directories found matching 
> 'django\contrib\admin\bin'
> warning: no previously-included files matching '__pycache__' found 
> anywhere in distribution
> creating c:\program files (x86)\lib\site-packages\django-1.10.5-py3.6.egg
> Extracting django-1.10.5-py3.6.egg to c:\program files 
> (x86)\lib\site-packages
> Adding django 1.10.5 to easy-install.pth file
> Installing django-admin.py script to c:\program files (x86)\Scripts
> error: [Errno 13] Permission denied: 'c:\\program files 
> (x86)\\Scripts\\django-admin.py'
>
> -- 
> 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...@googlegroups.com .
> To post to this group, send email to django...@googlegroups.com 
> .
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit 
> <https://groups.google.com/d/msgid/django-users/86091d59-6578-4e85-9be0-d24beb1f5b84%40googlegroups.com?utm_medium=email_source=footer>
> https://groups.google.com/d/msgid/django-users/86091d59-6578-4e85-9be0-d24beb1f5b84%40googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>
>
> -- 
> Jani Tiainen
>
>

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/d0938a27-8246-4b9d-9a16-b5c7919349f4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Installing Django

2017-01-29 Thread Danny Jr Chu
Guys, please help. I am new with Python and Django, I mean I don't have any 
clue what's going on (don't even know how to encode), but I wish I could 
build a website out of my imaginary. I know this will goes miles and 
miles... I am trying to install Django but couple of errors occur : 

PS C:\Users\Luv> easy_install django
Searching for django
Reading https://pypi.python.org/simple/django/
Downloading 
https://pypi.python.org/packages/c3/c2/6096bf5d0caa4e3d5b985ac72e3a0c795e37fa7407d6c85460b2a105b467/Django-1
.10.5.tar.gz#md5=3fce02f1e6461fec21f1f15ea7489924
Best match: Django 1.10.5
Processing Django-1.10.5.tar.gz
Writing 
C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10.5\setup.cfg
Running Django-1.10.5\setup.py -q bdist_egg --dist-dir 
C:\Users\Luv\AppData\Local\Temp\easy_install-5dcbu64l\Django-1.10
.5\egg-dist-tmp-k4dzxio3
no previously-included directories found matching 'django\contrib\admin\bin'
warning: no previously-included files matching '__pycache__' found anywhere 
in distribution
creating c:\program files (x86)\lib\site-packages\django-1.10.5-py3.6.egg
Extracting django-1.10.5-py3.6.egg to c:\program files 
(x86)\lib\site-packages
Adding django 1.10.5 to easy-install.pth file
Installing django-admin.py script to c:\program files (x86)\Scripts
error: [Errno 13] Permission denied: 'c:\\program files 
(x86)\\Scripts\\django-admin.py'

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/86091d59-6578-4e85-9be0-d24beb1f5b84%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Django Suit admin panel - Static files configuration Django 1.6 not working

2016-06-02 Thread Roger Lanoue jr
I am rebuilding a new server from scratch now. 

New IP: Same setup with new IP from Digital Ocean 1click install - 

http://162.243.58.204/

I am going to try and setup the Static files directory again. 

Since they are using Django 1.6 and the command makemigration and migrate 
are not in 1.6
Should i start using Django 1.8 or 1.9 before configuring the server?

On Thursday, June 2, 2016 at 10:35:20 AM UTC-4, luisza14 wrote:
>
> Where is  STATIC_ROOT ?
>
> static_root path needs to match with nginx /static location.
>
>
>
> El miércoles, 1 de junio de 2016, Roger Lanoue jr <ro...@rljmedia.com 
> > escribió:
> > Hi Django users group.
> > I am test and learning django out. I have a testing server and got my 
> test page up. 
> > Started to play with the Django suit control panel and ran in to some 
> problems with my setup.
> > Server: Digital Ocean one click install.
> > Ubuntu 14.04
> > Nginx
> > Postgres
> > python 2.7
> > django 1.6
> > Test server
> > http://162.243.201.237/
> >
> > Admin panel: http://django-suit.readthedocs.io/en/develop/
> > http://162.243.201.237/admin/
> > user: demo
> > pasword: demo
> > Static file command I ran
> > python manage.py collectstatic
> >
> > results: 0 static files copied, 116 unmodified.
> > Setting.py: Basics 
> > DEBUG = False 
> > TEMPLATE_DEBUG = False
> > ALLOWED_HOSTS = ['*']
> >
> > STATIC_URL = '/static/'
> > STATICFILES_DIRS = [
> > os.path.join(BASE_DIR, "static"),
> > '/home/django/django_project/static/',
> > Nginx setting:
> >  # Your Django project's media files - amend as required
> > location /media  {
> > alias /home/django/django_project/django_project/media;
> > }
> > # your Django project's static files - amend as required
> > location /static {
> > alias /home/django/django_project/django_project/static; 
> > }
> > # Proxy the static assests for the Django Admin panel
> > location /static/admin {
> >alias 
> /usr/lib/python2.7/dist-packages/django/contrib/admin/static/admin/;
> > }
> > location / {
> > proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
> > proxy_set_header Host $http_host;
> > proxy_redirect off;
> > proxy_pass http://app_server;
> > }
> >  My goal is to get the Django suit working. I do not see anything in my 
> static files directory for the admin suit so the css can be applied. 
> > I am missing something very simple to get this working.
> > Thank you for taking time to look at this and wish to get some clues.
> > Roger
> >
> > --
> > 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...@googlegroups.com .
> > To post to this group, send email to django...@googlegroups.com 
> .
> > Visit this group at https://groups.google.com/group/django-users.
> > To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/f0c19816-b477-43ba-9953-d4793bdfac80%40googlegroups.com
> .
> > For more options, visit https://groups.google.com/d/optout.
> >
>
> -- 
> "La utopía sirve para caminar" Fernando Birri
>
>
>
>

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/b3a7b96a-d6c9-4595-b989-a987ada38fe9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Django suit and Static files not working in Django 1.6

2016-06-02 Thread Roger Lanoue jr
Hello All.

I learning my first Django experience and I am making some headway. I am 
stuck on my test server and Django suit admin. 

I my goal is to get the new admin from Django suit to work.

*Server setup*
Ubuntu 14.04 ( A Digital Ocean VPS with one click install ) 
Django Version 1.6
Python: 2.7
Nginx
Postgres

*Test server *
http://162.243.201.237/

*Admin (with django suit installed ) *
http://django-suit.readthedocs.io/en/develop/
http://162.243.201.237/admin/

User: Demo
password: Demo

The css is being applied to the djando suit .

*Ran command:*
python manage.py collectstatic

Results: 0 static files copied, 116 unmodified.


*My setting.py basics*

DEBUG = False 

TEMPLATE_DEBUG = False

STATIC_URL = '/static/'

STATICFILES_DIRS = [
os.path.join(BASE_DIR, "static"),
'/home/django/django_project/static/',

When I look in to the static directory. nothing had been copied. 

Thank your for taking time to look at this and also sharing with me any 
clues on how to fix this.

Roger




-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/ee2b40b1-0716-4f5b-b4f1-8f35a60d54f6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Django Suit admin panel - Static files configuration Django 1.6 not working

2016-06-02 Thread Roger Lanoue jr
Hi Django users group.

I am test and learning django out. I have a testing server and got my test 
page up. 

Started to play with the Django suit control panel and ran in to some 
problems with my setup.

*Server: Digital Ocean one click install.*
Ubuntu 14.04
Nginx
Postgres
python 2.7
django 1.6

*Test server*
http://162.243.201.237/

*Admin panel: *http://django-suit.readthedocs.io/en/develop/
http://162.243.201.237/admin/
user: demo
pasword: demo

*Static file command I ran*
python manage.py collectstatic

results: 0 static files copied, 116 unmodified.

*Setting.py: Basics *
DEBUG = False 

TEMPLATE_DEBUG = False

ALLOWED_HOSTS = ['*']

STATIC_URL = '/static/'

STATICFILES_DIRS = [
os.path.join(BASE_DIR, "static"),
'/home/django/django_project/static/',

*Nginx setting:*

 # Your Django project's media files - amend as required
location /media  {
alias /home/django/django_project/django_project/media;
}

# your Django project's static files - amend as required
location /static {
alias /home/django/django_project/django_project/static; 
}

# Proxy the static assests for the Django Admin panel
location /static/admin {
   alias 
/usr/lib/python2.7/dist-packages/django/contrib/admin/static/admin/;
}

location / {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_pass http://app_server;
}

 My goal is to get the Django suit working. I do not see anything in my 
static files directory for the admin suit so the css can be applied. 
I am missing something very simple to get this working.

Thank you for taking time to look at this and wish to get some clues.

Roger

-- 
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 post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/f0c19816-b477-43ba-9953-d4793bdfac80%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Major Trouble Understanding Sessions Documentation

2012-08-02 Thread Gregory Thompson Jr.
Thanks a load!  You've cleared up a lot!

Yes, I have read through the tutorial.  I even wrote a shortened version of 
it to act as notes as I learn:  http://polydoo.com/code/?p=48  (my blog)

Thanks again!

On Thursday, August 2, 2012 10:42:59 AM UTC-4, Kurtis wrote:
>
> Hey Gregory,
>
> On Thu, Aug 2, 2012 at 9:06 AM, Gregory Thompson Jr. <
> spockthompso...@gmail.com> wrote:
>
>> I'd like to pass form data from one view to another.  
>>
>> Here's my attempt: 
>>
>> *#Models.py*
>> from django import forms
>> class Textizer(forms.Form):
>> to_textize = forms.CharField(max_length=100)
>> 
>> def __unicode__(self):
>> return self.to_textize
>> *#views.py*
>> from textize.models import Textizer
>> from django.http import HttpResponseRedirect
>> from django.shortcuts import render_to_response
>> from django.core.context_processors import csrf
>> def index(request):
>> if request.method == 'POST':
>> form = Textizer(request.POST)
>> 
>> if form.is_valid():
>> request.session['text'] = form.cleaned_data['to_textize']
>> return HttpResponseRedirect('/results')
>> 
>> else:
>> form = Textizer()
>> 
>> c = {'form': form}
>> c.update(csrf(request))
>> return render_to_response('C:/Documents and 
>> Settings/quansai/projects/textsite/templates/index.html', c)
>> def results(request):
>> text = request.session.get('text', None)
>> c = {'text' : text}
>> return render_to_response('C:/Documents and 
>> Settings/quansai/projects/textsite/templates/results.html', c)
>>
>>
>> I really don't understand the following, and I've read the documentation 
>> over and over.  I've been on this for two days:
>>
>>
> No problem! I'll try to clear things up for you.
>  
>
>>
>>- How to initiate a session
>>
>> Sessions are initiated automatically in Django using the "Session 
> Middleware". Basically, on each request, a session is either started or 
> continued (in simple terms, there's probably more to it than that but I 
> haven't inspected Django's session code too deeply)
>
> The only thing you need to do to make sure the session middleware is 
> properly configure it. It needs some sort of a storage (such as database, 
> file, cookies which are limited, etc...). You'll also need to make sure the 
> session middleware is included in your middleware configuration. This 
> configuration would exist under your settings.py and I believe is enabled 
> by default when creating new projects; at least that's been my experience 
> with Django 1.3+.
>
> Keep in mind that these do use cookies, no matter what, so you will need 
> them enabled in whatever HTTP Client (browser, or what-not) you use.
>
> Two links for enabling and configuring sessions (both on the same page, 
> these are anchor links).
>
> Enabling Sessions: 
> https://docs.djangoproject.com/en/dev/topics/http/sessions/?from=olddocs/#enabling-sessions
> Configuring Sessions: 
> https://docs.djangoproject.com/en/dev/topics/http/sessions/?from=olddocs/#configuring-the-session-engine
>
>
>>- How sessions are checked
>>
>> I'm not quite sure what you mean, here. Sessions are checked to be valid 
> by Django by signing them, but this is done by the middleware. If you want 
> to check whether a session exists, you might be asking more along the lines 
> of checking to see whether a user is authenticated. Or, you may be asking 
> how to check whether a certain variable is available from the session. 
> Since I'm not sure which part your looking for information on, I'll give 
> you information on both:
>
> To check if a particular object exists within the current session, follow 
> the example under __contains__(key) which actually does not call "contains" 
> but instead uses "if x in request.session": 
> https://docs.djangoproject.com/en/dev/topics/http/sessions/?from=olddocs/#using-sessions-in-views
>
> To check whether a current user is authenticated (logged in), you could 
> use this example: 
> https://docs.djangoproject.com/en/dev/topics/auth/#authentication-in-web-requests
>  
>
>>
>>- How to retrieve form data from one page to handle the data on another.
>>
>>
> Retrieving Form Data is actually one of Django's extremely strong points 
> (in my opinion) although it does require a bit of a learning curve. Once 
> you get it down, it takes off a huge burden; especially when coming from 
> other frameworks that don't offer as much vali

Re: Major Trouble Understanding Sessions Documentation

2012-08-02 Thread Gregory Thompson Jr.
Then how do I use the session to pass data between views?  What's wrong 
with my code?

If it counts for anything, *'text'* returns *'None'* in my debug statements 
(in the results() view).  

On Thursday, August 2, 2012 10:38:40 AM UTC-4, Marcin wrote:
>
> What's confusing about this? You don't explicitly create sessions, and 
> they last as long as they are configured to last, which by default is until 
> the session cookie is cleared.
>
> On Thu, Aug 2, 2012 at 10:31 AM, Gregory Thompson Jr. <
> spockthompso...@gmail.com> wrote:
>
>>
>>1. def login(request):
>>2. m = Member.objects.get(username=request.POST['username'])
>>3. if m.password == request.POST['password']:
>>4. request.session['member_id'] = m.id
>>5. return HttpResponse("You're logged in.")
>>6. else:
>>7. return HttpResponse("Your username and password didn't 
>>match.")
>>
>> How about that for starters?
>>
>> The documentation goes from that to explaining how to set cookies.  How 
>> do they expect me to understand what's going on?
>> There's absolutely NO explanation of what's going on in that code.  
>>
>> request.session['member_id'] = m.id 
>>
>> How the hell does that work?  
>>
>> They don't tell you where the session is started, how, what the scope of 
>> the session declaration is, etc...  
>>
>>
>> http://www.youtube.com/watch?v=YFd9NLZFmvo=1=PL6CB0A9FA1D9C736A=results_video
>>   
>>  
>>
>> See that video?  The video shows you how to use sessions very quickly. 
>>  How did the person in the video get ALL of that code from just the 
>> documentation? 
>>
>> If all readers in this thread and kindly tackle each point I made, I 
>> promise you your own KFC when I start my empire.  Until then, I really just 
>> need someone to give me the step-by-step on this one.  I'm completely new 
>> to the framework and the documentation thus far has not been helpful.  I've 
>> mainly gotten by with the help of StackOverflow, IRC, and random code 
>> snippets online -- and occasionally, some outdated books.  
>>
>> If you don't want to explain or aren't going to ask me progressive 
>> questions with regards to my confusion, please just skip over my plight.
>>
>> Thank you all.
>>
>> On Thursday, August 2, 2012 9:54:21 AM UTC-4, Daniel Roseman wrote:
>>>
>>> On Thursday, 2 August 2012 14:06:04 UTC+1, Gregory Thompson Jr. wrote:
>>>>
>>>> 
>>>>
>>>> I really don't understand the following, and I've read the documentation 
>>>> over and over.  I've been on this for two days:
>>>>
>>>>
>>>>- How to initiate a session
>>>>- How sessions are checked
>>>>- How to retrieve form data from one page to handle the data on another.
>>>>
>>>> Again, I've read through the documentation.  I've asked on IRC but 
>>>> everyone pretty much just says "RTFM" even when I tell them I have.  This 
>>>> is absolutely frustrating as an extreme beginner.
>>>>
>>>> I'd also like to add that I DO understand the core Python language.  
>>>> Please, unless it's absolutely necessary, don't try explaining to me what 
>>>> a dictionary, tuple, list, etc... is.  I've already had my intelligence 
>>>> insulted by the users on IRC in this regard.  I really just don't 
>>>> understand the sessions documentation. 
>>>>
>>>>
>>>
>>> So, you didn't understand the documentation, but you also don't want to 
>>> be told what dictionaries/lists/tuples are.  How about you tell us which 
>>> bit of the examples under "Using sessions in views" (which I'm not linking 
>>> to because you've said you've read it) you didn't understand?
>>> --
>>> DR.
>>>
>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Django users" group.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msg/django-users/-/0czW05_b8q8J.
>>
>> To post to this group, send email to django-users@googlegroups.com.
>> To unsubscribe from this group, send email to 
>> django-users+unsubscr...@googlegroups.com.
>> For more options, visit this group at 
>> http://groups.google.com/group/django-users?hl=en.
>>
>
>
>
> -- 
> Marcin Tustin
> Tel: 07773 787 105
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/django-users/-/GIPMRuHoti8J.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Major Trouble Understanding Sessions Documentation

2012-08-02 Thread Gregory Thompson Jr.

   
   1. def login(request):
   2. m = Member.objects.get(username=request.POST['username'])
   3. if m.password == request.POST['password']:
   4. request.session['member_id'] = m.id
   5. return HttpResponse("You're logged in.")
   6. else:
   7. return HttpResponse("Your username and password didn't match."
   )
   
How about that for starters?

The documentation goes from that to explaining how to set cookies.  How do 
they expect me to understand what's going on?
There's absolutely NO explanation of what's going on in that code.  

request.session['member_id'] = m.id 

How the hell does that work?  

They don't tell you where the session is started, how, what the scope of 
the session declaration is, etc...  

http://www.youtube.com/watch?v=YFd9NLZFmvo=1=PL6CB0A9FA1D9C736A=results_video
  
 

See that video?  The video shows you how to use sessions very quickly.  How 
did the person in the video get ALL of that code from just the 
documentation? 

If all readers in this thread and kindly tackle each point I made, I 
promise you your own KFC when I start my empire.  Until then, I really just 
need someone to give me the step-by-step on this one.  I'm completely new 
to the framework and the documentation thus far has not been helpful.  I've 
mainly gotten by with the help of StackOverflow, IRC, and random code 
snippets online -- and occasionally, some outdated books.  

If you don't want to explain or aren't going to ask me progressive 
questions with regards to my confusion, please just skip over my plight.

Thank you all.

On Thursday, August 2, 2012 9:54:21 AM UTC-4, Daniel Roseman wrote:
>
> On Thursday, 2 August 2012 14:06:04 UTC+1, Gregory Thompson Jr. wrote:
>>
>> 
>>
>> I really don't understand the following, and I've read the documentation 
>> over and over.  I've been on this for two days:
>>
>>
>>- How to initiate a session
>>- How sessions are checked
>>- How to retrieve form data from one page to handle the data on another.
>>
>> Again, I've read through the documentation.  I've asked on IRC but everyone 
>> pretty much just says "RTFM" even when I tell them I have.  This is 
>> absolutely frustrating as an extreme beginner.
>>
>> I'd also like to add that I DO understand the core Python language.  Please, 
>> unless it's absolutely necessary, don't try explaining to me what a 
>> dictionary, tuple, list, etc... is.  I've already had my intelligence 
>> insulted by the users on IRC in this regard.  I really just don't understand 
>> the sessions documentation. 
>>
>>
>
> So, you didn't understand the documentation, but you also don't want to be 
> told what dictionaries/lists/tuples are.  How about you tell us which bit 
> of the examples under "Using sessions in views" (which I'm not linking to 
> because you've said you've read it) you didn't understand?
> --
> DR.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/django-users/-/0czW05_b8q8J.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Major Trouble Understanding Sessions Documentation

2012-08-02 Thread Gregory Thompson Jr.
Okay. What?

Can you explain any of the key points I was trying to understand?  I don't 
know what I'm doing.  

On Thursday, August 2, 2012 9:22:40 AM UTC-4, larry@gmail.com wrote:
>
> On Thu, Aug 2, 2012 at 7:06 AM, Gregory Thompson Jr. 
> <spockthompso...@gmail.com> wrote: 
> > I'd like to pass form data from one view to another. 
> > 
> > Here's my attempt: 
> > 
> > #Models.py 
> > from django import forms 
> > 
> > class Textizer(forms.Form): 
> > to_textize = forms.CharField(max_length=100) 
> > 
> > def __unicode__(self): 
> > return self.to_textize 
> > 
> > #views.py 
> > from textize.models import Textizer 
> > from django.http import HttpResponseRedirect 
> > from django.shortcuts import render_to_response 
> > from django.core.context_processors import csrf 
> > 
> > def index(request): 
> > if request.method == 'POST': 
> > form = Textizer(request.POST) 
> > 
> > if form.is_valid(): 
> > request.session['text'] = form.cleaned_data['to_textize'] 
> > return HttpResponseRedirect('/results') 
> > 
> > else: 
> > form = Textizer() 
> > 
> > c = {'form': form} 
> > c.update(csrf(request)) 
> > return render_to_response('C:/Documents and 
> > Settings/quansai/projects/textsite/templates/index.html', c) 
> > 
> > def results(request): 
> > text = request.session.get('text', None) 
> > c = {'text' : text} 
> > return render_to_response('C:/Documents and 
> > Settings/quansai/projects/textsite/templates/results.html', c) 
> > 
> > 
> > I really don't understand the following, and I've read the documentation 
> > over and over.  I've been on this for two days: 
> > 
> > How to initiate a session 
> > How sessions are checked 
> > How to retrieve form data from one page to handle the data on another. 
>
> In your template you can access the session variables as 
> request.session.text. 
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/django-users/-/Mmx185GY9X4J.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Major Trouble Understanding Sessions Documentation

2012-08-02 Thread Gregory Thompson Jr.
I'd like to pass form data from one view to another.  

Here's my attempt: 

*#Models.py*from django import forms
class Textizer(forms.Form):
to_textize = forms.CharField(max_length=100)

def __unicode__(self):
return self.to_textize
*#views.py*from textize.models import Textizerfrom django.http import 
HttpResponseRedirectfrom django.shortcuts import render_to_responsefrom 
django.core.context_processors import csrf
def index(request):
if request.method == 'POST':
form = Textizer(request.POST)

if form.is_valid():
request.session['text'] = form.cleaned_data['to_textize']
return HttpResponseRedirect('/results')

else:
form = Textizer()

c = {'form': form}
c.update(csrf(request))
return render_to_response('C:/Documents and 
Settings/quansai/projects/textsite/templates/index.html', c)
def results(request):
text = request.session.get('text', None)
c = {'text' : text}
return render_to_response('C:/Documents and 
Settings/quansai/projects/textsite/templates/results.html', c)


I really don't understand the following, and I've read the documentation over 
and over.  I've been on this for two days:


   - How to initiate a session
   - How sessions are checked
   - How to retrieve form data from one page to handle the data on another.

Again, I've read through the documentation.  I've asked on IRC but everyone 
pretty much just says "RTFM" even when I tell them I have.  This is absolutely 
frustrating as an extreme beginner.

I'd also like to add that I DO understand the core Python language.  Please, 
unless it's absolutely necessary, don't try explaining to me what a dictionary, 
tuple, list, etc... is.  I've already had my intelligence insulted by the users 
on IRC in this regard.  I really just don't understand the sessions 
documentation. 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/django-users/-/1xFNBaS1eogJ.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Handling millions of rows + large bulk processing (now 700+ mil rows)

2012-07-01 Thread Davinir F Campos Jr
+1
Em 01/07/2012 08:06, "Alec Taylor"  escreveu:

> +! :]
>
> On Sun, Jul 1, 2012 at 5:52 PM, ionic drive  wrote:
> > +1 great!
> >
> >
> > On Sat, 2012-06-30 at 16:10 +0100, Cal Leeming [Simplicity Media Ltd]
> wrote:
> >
> > Hi all,
> >
> >
> >
> > As some of you know, I did a live webcast last year (July 2011) on our
> LLG
> > project, which explained how we overcome some of the problems associated
> > with large data processing.
> >
> >
> >
> > After reviewing the video, I found that the sound quality was very poor,
> the
> > slides weren't very well structured, and some of the information is now
> out
> > of date (at the time it was 40mil rows, now we're dealing with 700+mil
> > rows).
> >
> >
> >
> > Therefore, I'm considering doing another live webcast (except this time
> > it'll be recorded+posted the next day, the stream will be available in
> > 1080p, it'll be far better structured, and will only last 50 minutes).
> >
> >
> >
> > The topics I'd like to cover are:
> >
> >
> >
> > * Bulk data processing where bulk_insert() is still not viable (we went
> from
> > 30 rows/sec to 8000 rows/sec on bulk data processing, whilst still using
> the
> > ORM - no raw sql here!!)
> >
> > * Applying faux child/parent relationship when standard ORM is too
> expensive
> > (allows for ORM approach without the cost)
> >
> > * Applying faux ORM read-only structure to legacy applications (allows
> ORM
> > usage on schemas that weren't properly designed, and cannot be changed -
> for
> > example, vendor software with no source code).
> >
> > * New Relic is beautiful, but expensive. Hear more about our plans to
> make
> > an open source version.
> >
> > * Appropriate use cases for IAAS vs colo with SSDs.
> >
> > * Percona is amazing, some of the tips/tricks we've learned over.
> >
> >
> >
> > If you'd like to see this happen, please leave a reply in the thread - if
> > enough people want this, then we'll do public vote for the scheduled
> date.
> >
> >
> >
> > Cheers
> >
> >
> >
> > Cal
> >
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Django users" group.
> > To post to this group, send email to django-users@googlegroups.com.
> > To unsubscribe from this group, send email to
> > django-users+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> > http://groups.google.com/group/django-users?hl=en.
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Django users" group.
> > To post to this group, send email to django-users@googlegroups.com.
> > To unsubscribe from this group, send email to
> > django-users+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> > http://groups.google.com/group/django-users?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Adding context data to a TemplateView?

2012-04-22 Thread Buddy Lindsey, Jr.

This should help you out with adding extra context to TemplateView

http://godjango.com/15-class-based-views-part-1-templateview-and-redirectview/

Roy Smith wrote:


I'm using a generic TemplateView (django-1.4), but I want to be able
to add something to the context. Is that possible?

The docs at
https://docs.djangoproject.com/en/1.4/topics/generic-views/#adding-extra-context 


talk about "an extra optional parameter, extra_context", but I don't
get what they're trying to explain. I tried the obvious:

url(r'^about$',
TemplateView.as_view(template_name='legal_ipsum/about.html',
extra_context={'pagename': 'about'})
),

in my urls.py file, but that just raises: "TemplateView() received an
invalid keyword 'extra_context'". What am I missing here?

--
Roy Smith
r...@panix.com 



--
You received this message because you are subscribed to the Google
Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en.


--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Missing manage.py

2012-04-16 Thread Buddy Lindsey, Jr.
If you are using Django 1.4 check in the application folder of your 
project below your project folder. It should be in there.


Faeez Abd Rahman wrote:


Hi,

I have a problem whenever I create a new project using the start
project command, no manage.py file is created.

I'm using Mac OS X. Thank you in advance

--
You received this message because you are subscribed to the Google
Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en.


--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Accessing MEDIA_ROOT in templates, always blank/missing

2012-03-22 Thread Davinir F Campos Jr
Stoge, you DO need MEDIA_URL in turn to build the URL in which script src
is based on.

MEDIA_ROOT is the (complete) physical path to the file. Do you want to
expose your filesystem?

[ ]s
Davinir

2012/3/22 Stodge 

> No I need MEDIA_ROOT, I want to experiment with:
>
> 
>
> Thanks
>
> On Mar 22, 7:22 am, kenneth gonsalves  wrote:
> > On Thu, 2012-03-22 at 05:11 -0700, Stodge wrote:
> > > In my template:
> >
> > > MEDIA_ROOT: {{MEDIA_ROOT}}
> >
> > > But all I see is:
> >
> > > MEDIA_ROOT:
> >
> > > So MEDIA_ROOT is blank or doesn't exist. Did I miss something?
> >
> > https://docs.djangoproject.com/en/1.0/ref/templates/api/#django-core-...
> >
> > you need MEDIA_URL
> > --
> > regards
> > Kenneth Gonsalves
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: [pinax-users] Learning Django+Pinax - Recommend books and/or tutorials?

2012-01-27 Thread Steven Elliott Jr
> 
> What would you recommend?
> 
To get started with Python:
http://pragprog.com/book/gwpy/practical-programming
http://www.amazon.com/gp/product/1590599829/ref=pd_lpo_k2_dp_sr_3/182-5610174-4840816?pf_rd_m=ATVPDKIKX0DER_rd_s=lpo-top-stripe-1_rd_r=1YTG71HMBVWK64HZ2TP2_rd_t=201_rd_p=486539851_rd_i=0764596543

To get started with Django:
http://www.amazon.com/Django-Website-Development-Ayman-Hourieh/dp/1847196780/ref=sr_1_2?s=books=UTF8=1327587925=1-2
http://www.amazon.com/Practical-Django-Projects-Experts-Development/dp/1430219386/ref=sr_1_2?s=books=UTF8=1327587948=1-2

There is no reason why you could not learn both things at the same time. 
Contrary to previous statements, Django and Python are not hard to get started 
with but are hard to master (as is anything). I like both of the Django books 
because they actually focus on building something meaningful and not just 
giving you an overview of the framework. The Django book is also a great 
reference book but I have never read it through cover-to-cover. I use it more 
as a reference when I am stuck on something and need some clarity. Also, I 
would really recommend going through the documentation for both Python and 
Django extensively, both are excellent.

Cheers,
Steven

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: I need help with Python Tools for Visual Studio 2010 and Django

2012-01-27 Thread Steven Elliott Jr

On Jan 25, 2012, at 9:14 PM, JJ Zolper wrote:

> > The keywords were 'in production'. The development server (i.e. python
> > manage.py runserver) works fine under Windows. But when you want to
> > make the website accessible to your audience (the internet, company
> > etc.), you should host that on Linux. 
> 
> I still don't quite understand. Can you explain more? I would think this 
> means that my Django files should be on a Linux portion of my web server? I 
> am with Bluehost.com

It means when you actually go to deploy your app on an actual web server in 
production you're going to be deploying on Linux. I've never seen a Python host 
on Windows, but then again I've never looked because, to be honest most Django 
devs use some Unix variant for development.

> I have installed ActiveState and will give it a try. I have my VS up and 
> running with Python Tools for VS so that should be okay.
> 
> Hey Sam you've been a great help. Would you by chance mind giving me your 
> e-mail address? That way in the future I could work with you? I won't bother 
> you too much don't worry! lol. Just since I am trying your advice it could be 
> a great help to me.
> 
> What Virtual Machine did you pick? What Linux version are you running?

Most people use Ubuntu running in VirtualBox
> 
> If you prefer e-mailing/want to give me your address my next inquery would 
> just go to your e-mail.
> 
> Thanks so much!
> 
> JJ Zolper
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To view this discussion on the web visit 
> https://groups.google.com/d/msg/django-users/-/nMqg8xOLXRcJ.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django for a large social networking or photo sharing site?

2011-11-22 Thread Steven Elliott Jr
Yes

> Hello,
> 
> [This is the first time I am using Google Groups and/or mailing lists,
> so please bear with me if I do something wrong initially.]
> 
> Is Django web framework apt for a large social networking or photo
> sharing site? (Think one that has to easily and seamlessly scale to
> the size of Facebook or Flickr. Yes, I know I want too much, but
> that's for an estimate.)
> 
> thanks.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: installing django

2011-09-13 Thread Steven Elliott Jr
What exactly is the problem? Can you provide more detail? Platform, error 
messages, python version? What have you tried already?


On Sep 13, 2011, at 1:21 PM, re64  wrote:

> I am having trouble installing django.  I cant seem to do it any
> suggestions
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django Development environment

2011-08-27 Thread Steven Elliott Jr

On Aug 27, 2011, at 11:17 AM, Simon Connah <simon.connah...@gmail.com> wrote:

> 
> On 27 Aug 2011, at 04:44, Steven Elliott Jr wrote:
> 
>>> On Fri, 2011-08-26 at 15:07 +0100, Simon Connah wrote:
>>>> Mercurial or Git (depends on whether the project is open source or not)
>> 
>> Kenneth,
>> 
>> I think he means whether or not the repository will be public or private. 
>> Github (git) does not offer private repos unless you pay whereas bitbucket 
>> (mercurial) gives you 5 private ones for free as well as the option for 
>> creating public ones. I personally am a big BitBucket fan as I find it much 
>> much easier to manage and also a bit faster. 
>> 
>> Best,
>> Steve
> 
> Correct. Although Bitbucket offers unlimited private repos. It just limits 
> you to 5 users...
 
Right, sorry that's what I was going for but I brain spasm'd on the iPhone. 
Bitbucket has gotten a lot better since Atlassian took it over. 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django Development environment

2011-08-27 Thread Steven Elliott Jr
> On Fri, 2011-08-26 at 15:07 +0100, Simon Connah wrote:
>> Mercurial or Git (depends on whether the project is open source or not)

Kenneth,

I think he means whether or not the repository will be public or private. 
Github (git) does not offer private repos unless you pay whereas bitbucket 
(mercurial) gives you 5 private ones for free as well as the option for 
creating public ones. I personally am a big BitBucket fan as I find it much 
much easier to manage and also a bit faster. 

Best,
Steve

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django Development environment

2011-08-25 Thread Steven Elliott Jr

> Am 23.08.2011 00:07, schrieb Stephen Jackson:
>> I am new to the world of Django. I would like to hear from other django
>> developers describe their dev environment (tools, os, editors, etc.).

Mac OS X Lion
PyCharm and TextMate with Python competion and Django bundles
Mysql & MongoDB
South
Pygments
Also using Sphinx for help docs.


-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Question about Displaying a Table

2011-06-27 Thread Steven Elliott Jr
Django has about the best documentation out there foe getting started. Walk 
through the tutorial and see how it goes. 

Sent from my iPhone

On Jun 27, 2011, at 2:25 PM, "Cal Leeming [Simplicity Media 
Ltd]" wrote:

> Forgive me but, the tone of this email sounds like you are asking us to do 
> this research for you :X
> 
> On Mon, Jun 27, 2011 at 7:18 PM, Kyle Latham  wrote:
> Hello,
> 
> I am pretty new to Django and Python.
> 
> I'm wanting to create a Django app that displays different tables in
> my MySQL database, and the user can search through the tables for info
> they want.
> 
> I haven't written any code yet, I'm doing research on the approach I
> have to take.  Is the only way I am able to display a table from the
> MySQL database in Django by creating a template and importing the data
> to the template? Is there a another/better approach towards displaying
> a MySQL table in the Django app?
> 
> Thank you,
> 
> Kyle
> 
> --
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Clueless Monk

2011-03-22 Thread Fernando Torres Jr.
Hi I was wondering how you start up with Python? Python is a language
that you use on what platform? Like C++ can be used on Microsoft
Visual Studios. What is the equivalent for Python. Sorry I am a
begineer programmer

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: django-registration - Activate view not works

2011-03-15 Thread Sergio Berlotto Jr
Did not work.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: django-registration - Activate view not works

2011-03-14 Thread Sergio Berlotto Jr
I´ll try it..

In my template I wrote the URL manually ! Oh god.. heheh

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: django-registration - Activate view not works

2011-03-13 Thread Sergio Berlotto Jr
Well, I'll try the http://django-userena.org becouse django-registration is 
stoped development since March/2010.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: django-registration - Activate view not works

2011-03-13 Thread Sergio Berlotto Jr
The variable "activation_key" is blank, with no value, and the result os 
activation redirect always to activation_failed view.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



django-registration - Activate view not works

2011-03-13 Thread Sergio Berlotto Jr
I'm using django-registration.
The activation email is generated correctly, but when i'm trying to activate 
the new user with generated key sent by e-mail, in url 
http://server.com/accounts/activate/ee3ad866abca8bf0d29d71870a79a3b84cd9c965/ 
this only returns failure, and not activate the account.

Anyone here have same problem ?

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django - Verfication of runserver vs browser

2011-01-24 Thread Steven Elliott Jr
Have you tried running it on a different port? Can you post the actual error 
message you get?

-Steven Elliott Jr

On Jan 24, 2011, at 2:05 PM, Kimberly Harvey <kharve...@gmail.com> wrote:

> I ran the browser in the linux.
> 
> On Mon, Jan 24, 2011 at 12:57 PM, Javier Guerra Giraldez <jav...@guerrag.com> 
> wrote:
> On Mon, Jan 24, 2011 at 1:43 PM, Kimberly Harvey <kharve...@gmail.com> wrote:
> > I am using the Django inside the Linux-Debian on my windows 7 machine.
> 
> do you run your browser in Windows or Linux?
> 
> if it's on windows, then accessing the dev-server on the Linux virtual
> machine is just like going to any other machine; you can't use
> 127.0.0.1
> 
> ah, and remember that your VM can't use the same IP# as your windows host
> 
> --
> Javier
> 
> --
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django Improper Configuration

2011-01-23 Thread Steven Elliott Jr
Just curious if you've done a python tutorial yet? It's hard to really 
understand Django well unless you have at least some working knowledge of 
python. You will most definitely struggle later on when things become more 
complicated with your app. The framework is great for repetitive tasks but 
you're going to need to know how to write python code if you're to get 
anywhere. 

It's definitely possible to learn both at the same time but I'd read through, 
and work through a few python tutorials first then come back to Django. 

I know this is probably not what you'd like to hear and it's just my two cents 
so... 

Anyway, keep posting and we will try to help. 

-Steven

On Jan 23, 2011, at 10:40 PM, Graham Dumpleton <graham.dumple...@gmail.com> 
wrote:

> That is two underscores, followed by 'file' followed by two underscores. Not 
> just a single underscore.
> 
> Please try and cut and paste out we give to use and vice versa. In other 
> words, provide complete output showing full errors and tracebacks. Such 
> information may be meaningful to use even if you think it isn't.
> 
> Graham
> 
> On Monday, January 24, 2011 2:35:06 PM UTC+11, Kimberly wrote:
> it says that the _file_ is not defined. 
> 
> On Sun, Jan 23, 2011 at 9:28 PM, Graham Dumpleton <graham.d...@gmail.com> 
> wrote:
> 
> 
> On Monday, January 24, 2011 2:19:09 PM UTC+11, Steven Elliott Jr wrote:
> Copy and Paste the following to replace your entire DATABASES tuple:
> DATABASES = {
> 'default': {
> 'ENGINE': 'django.db.backends.sqlite3', 
> 'NAME': 'database.db', 
> 'USER': '',   
> 'PASSWORD': '',   
> 'HOST': '',   
> 'PORT': '',   
> }
> }
> 
> it looks like in your configuration you are also missing a comma after the 
> name of the database. Remember you must include that comma because this is a 
> tuple.
> 
> 
> That was already pointed out to them.
> 
> The lack of a comma should have resulted in a syntax error, which makes me 
> believe, unless they modified the content before posting, that they may be 
> modifying a different file to what is being read.
> 
> I would like to see them, instead of changing DATABASES yet again, is to add 
> at the very end of their settings.py file, the lines:
> 
>   print __file__
>   print 'DATABASES', DATABASES
> 
> This will prove two things. First that the file is being read as the output 
> from this should show on stdout when running runserver or syncdb. Second, 
> will show what Python is seeing DATABASES as being set to.
> 
> if it doesn't show, then wrong file. If shows, but is different to what they 
> believe they are setting it to, they could have multiple DATABASES entries in 
> file.
> 
> Graham
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django Improper Configuration

2011-01-23 Thread Steven Elliott Jr
I remember that the one time I tried sqlite it complained until I put a .db 
suffix on the name of my database. If you do not specify the full path and just 
specify a name, then it will just create the database file in your project's 
root directory. 

So, under name just put:

'NAME' : 'database.db',

And see if that works. 

-Steve
Sent from my iPhone 


On Jan 23, 2011, at 9:48 PM, Graham Dumpleton  
wrote:

> 
> 
> On Monday, January 24, 2011 1:36:10 PM UTC+11, Kimberly wrote:
> username@debian:~/wikicamps$ python manage.py runserver
> Validating models
> 0 errors found
> 
> Django version 1.2.4, using settings 'wikicamp.settings'
> Development server is running at http://127.0.0.1:8000/
> Quit the server with CONTROL-C.
> 
> It runs fine, but yet I faced problem with the database ENGINE. 
> 
> Where are you seeing that error because it isn't in what you quote above?
> 
> If it is in the browser, paste the Python exception details and traceback 
> from the browser. Not everything, just the exception message and traceback 
> will do.
> 
> In other words, we need to see the actual context in which the real error 
> message is displayed and the exact wording of the error message and the 
> location.
> 
> Graham
>  
> On Sun, Jan 23, 2011 at 8:19 PM, Graham Dumpleton  
> wrote:
> Provide  the full error including any Python traceback so we can see where 
> the error is occurring. If running manage.py runserver, easiest thing to do 
> is to provide the whole output from running the command.
> 
> Graham
> 
> On Monday, January 24, 2011 1:11:47 PM UTC+11, Kimberly wrote:
> Still doesn't work. But thank you for trying to help me. It keep giving me 
> the same ENGINE configuration that it is not set.
> 
> On Sun, Jan 23, 2011 at 8:05 PM, Graham Dumpleton  wrote:
> 
> 
> On Monday, January 24, 2011 12:42:57 PM UTC+11, Kimberly wrote:
> Sorry about that... here is what I have in the settings.py ( similiar to what 
> you showed, but mine is abit different in the NAME section):
> 
> DATABASES = {
> 'default': {
> 'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 
> 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
> 'NAME':  'home/username/directory/database'  # Or 
> path to database file if using sqlite3.
> 
> You deleted the comma after the string and missing leading slash on path. Try:
> 
> 'NAME':  '/home/username/directory/database',  # Or 
> path to database file if using sqlite3.
> 
> Not sure how you didn't just get a syntax error.
> 
> Graham
>  
> 'USER': '',  # Not used with sqlite3.
> 'PASSWORD': '',  # Not used with sqlite3.
> 'HOST': '',  # Set to empty string for localhost. 
> Not used with sqlite3.
> 'PORT': '',  # Set to empty string for default. 
> Not used with sqlite3.
> }
> }
> 
> Inside the settings.py file, in the template_dirs section, there's a line 
> says os.path.join(os.path.dirname(_file_), 'templates')
> 
> If I comment that, then there's a error saying it doesn't recognize _file_. I 
> commented that line, then it says that the setting ENGINE has not been set.
> 
> 
> On Sun, Jan 23, 2011 at 7:32 PM, Graham Dumpleton  wrote:
> Rather than have us guess what is in your settings file, post that whole 
> section. For example:
> 
> DATABASES = {
> 'default': {
> 'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 
> 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
> 'NAME': os.path.join(ENVIRON_ROOT, 'db', 'database.db'),  
> # Or path to database file if using sqlite3.
> 'USER': '',  # Not used with sqlite3.
> 'PASSWORD': '',  # Not used with sqlite3.
> 'HOST': '',  # Set to empty string for localhost. 
> Not used with sqlite3.
> 'PORT': '',  # Set to empty string for default. 
> Not used with sqlite3.
> }
> }
> 
> This will allow everyone to see if you have mucked up some other part of the 
> settings.
> 
> Graham
> 
> On Monday, January 24, 2011 11:39:02 AM UTC+11, Kimberly wrote:
> I've used the tutorials and it doesn't work. I've done exactly what the 
> tutorial says, and it keeps saying that the ENGINE has not been set in the 
> setting. I am also using Django 1.2 or higher version.
> 
> On Sun, Jan 23, 2011 at 6:29 PM, Karen Tracey  wrote:
> On Sun, Jan 23, 2011 at 6:47 PM, Kimberly Harvey  wrote:
> it still doesn't work. I typed it like you've suggested and it keeps saying 
> that the database ENGINE has not been set.
> 
> 
> If you are using ENGINE by itself, you need to be using Django 1.2 or higher 
> and ENGINE is a key in the dictionary of settings for the default database, 
> not a single ENGINE 

Re: Expert help needed --LINUX on virtualBox using Windows 7 machine

2011-01-21 Thread Steven Elliott Jr
> 
> 
> While I am sure we can all sympathize with confronting  a technical problem 
> that we don't understand, this OP has the flavor of trolling perhaps.  At any 
> rate this is the wrong list for these pleadings.  I don't even see a question

You're so right; I don't know why I am wasting my time with this question 
already. Check out http://www.debian.org/MailingLists/subscribe if you need 
help with Debian

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Expert help needed --LINUX on virtualBox using Windows 7 machine

2011-01-21 Thread Steven Elliott Jr

> he is not doing dual boot - he is running linux under windows!
   
   Right, which I think is horrible and usually very slow as well; it might be 
better to 
   install the Linux OS on a separate partition on the computer. I personally 
hate running
   anything in a virtual machine. I'd rather triple-boot a system than run in a 
VM.

   Best,
   Steven Elliott
   steve...@me.com

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Expert help needed --LINUX on virtualBox using Windows 7 machine

2011-01-20 Thread Steven Elliott Jr
Why don't you try partitioning your hard drive instead and doing a dual boot 
installation? 

Also, it's Debian not Derbian. 

-Steve 

On Jan 20, 2011, at 4:59 PM, Kimberly  wrote:

> This is now a LINUX-Derbian problem I am experiencing. I open the
> virtualbox and clicked on the Linux-Windows that I wanted, and clicked
> on "start" to run it. Once it run, it is black screen. I already mount
> the Derbian iso to the program, so I am lost for words on what is
> going on. This is a struggle and I am frustrated because I just don't
> know where else to turn or what to do ( yes, read the tutorial and
> doesn't help much).
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Installing Django on Linux-Derbian using virtualBox on Windows 7 Machine

2011-01-20 Thread Steven Elliott Jr
> Ubuntu IS Debian for all intents and purposes. Why does your boss insist that 
> you use a particular distro? It shouldn't really matter what your development 
> OS is (at least with *nix systems). Is there an existing Django application 
> that needs to be supported or is this a new project?
> 
> On Thu, Jan 20, 2011 at 3:58 PM, Ivo Brodien  wrote:
> 
> 
> > But in order to do that, don't I need to have the Django source file 
> > somewhere in my  computer/ or in my case.
> 
> apt-get gets packages from the internet.
> 
> And btw. Ubuntu is based on Debian.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django's documention is horrible

2011-01-10 Thread Steven Elliott Jr
Ummm... I think thats the first time I've ever heard anyone say that django's 
documentation sucks. 

Sent from my iPhone

On Jan 10, 2011, at 4:25 PM, Simon W  wrote:

> Hey,
> For such a good web framework it's a shame that the documention is not 
> structured well .. at all. It consists of massive text put on a page with 
> some random examples. But examples is all there is. In other languages and 
> frameworks I'm used to have at least a well structed API documention listing 
> all methods and members of classes with some comment attached to them. They 
> also show the class heirachy, quick and simple. I spend more time searching 
> for minor stuff in the documention than writing code. The django project 
> should look into doxygen or some similar doc generator.
> 
> And this mailing list? It's so hard to find any existing answers quick, 
> google doesn't find none. I mean comon .. look at jQuery, you find what 
> you're looking in less than 2 sec using google. Why isn't there a proper 
> forum?
> 
> Am I the only one who frown upon this?
> 
> Cheers
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: how can i define a decimal_separator and a thousand_separator

2010-12-29 Thread Sergio Berlotto Jr
Use the DECIMAL_SEPARATOR, THOUSAND_SEPARATOR and NUMBER_GROUPING settings.
See: http://docs.djangoproject.com/en/1.2/ref/settings/ 


-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django on Apache

2010-09-25 Thread Steven Elliott Jr
MAMP can be a bit of a pain I think sometimes to modify, though I haven't used 
it much in the past few years. You can use the Mac's built-in apache server 
though with mod_python. Check out 
http://www.google.com/search?q=mod_python+mac+os+x=UTF-8=UTF-8=en=safari

Sent from my iPhone

On Sep 25, 2010, at 11:07 AM, Derek  wrote:

> I am about a week into learning Django, having developed with PHP and
> the CodeIgniter framework for the past 3 years.  That said, I'm used
> to making a change to a file, refreshing my browser and seeing the
> results.
> 
> Django's "syncdb" aside, it's been pretty weird having to restart the
> Django webserver manually on certain occasions.  Is this also the case
> when running Django on Apache?  If not, can I set up Django to run
> with MAMP locally?
> 
> Thanks!
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Recommend a book

2010-09-23 Thread Steven Elliott Jr
I have found beginning django e-commere as practical django projects to be 
great. Both from apress. I prefer to use books that go through building real 
world solutions. The definitive guide to django is a must read though. 

On Sep 23, 2010, at 9:57 PM, Tim Johnson  wrote:

> FYI: I'm an experienced python programmer, experienced web
> programmer, work mostly on linux platforms. And I like to
> start slow and get it down thoroughly. 
> 
> I'm soliciting recommendations for books on learning django. 
> E-book or paper. Paper is preferred.
> 
> I would prefer to avoid anything geared to a particular IDE.
> (I roll my own with either vim or emacs)
> 
> TIA
> -- 
> Tim 
> tim at johnsons-web.com or akwebsoft.com
> http://www.akwebsoft.com
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Pylons vs. Django

2010-09-05 Thread Steven Elliott Jr
You can use sqlalchemy with django too

Sent from my iPad

On Sep 5, 2010, at 2:37 PM, Juan Hernandez  wrote:

> Well, just by using SQLAlchemy makes this framework worth a try
> 
> On 9/5/10, Feross  wrote:
>> Hey everyone,
>> 
>> I'm a new Python user and I'm looking for a web development framework to
>> build a database-driven website. I've looked at the various Python web
>> frameworks out there and I've settled on either Django or Pylons, but I'm
>> not sure which to choose.
>> 
>> Things I've heard about Django that I like:
>> - All the Django documentation is in one place.
>> - The community is larger = more help for newbies.
>> - It has a handy admin interface for adding content quickly.
>> 
>> Things I've heard about Pylons that I like:
>> - It's easier to customize and swap components in and out.
>> - It uses SQLAlchemy out of the box. (I've never used it, but I hear that
>> it's better than Django's ORM)
>> - It uses Mako out of the box. (Again, I've never used it, but I hear that
>> it's better than Django's templating system).
>> 
>> I'm not sure how important SQLAlchemy and Mako support is, so I'd like to
>> hear opinions from some more experienced Python and Django users.
>> 
>> Thanks,
>> Feross
>> 
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To post to this group, send email to django-us...@googlegroups.com.
>> To unsubscribe from this group, send email to
>> django-users+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/django-users?hl=en.
>> 
>> 
> 
> -- 
> Sent from my mobile device
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: LIMITATIONS of django

2010-09-04 Thread Steven Elliott Jr
This is not really an appropriate question. Django, like many frameworks is a 
collection of libraries written in some language. Django happens to be written 
in Python; as such, your proficiency with Python will have an effect on what 
you can and can't do with Django. Django provides a lot of useful tools to 
assist you along the way but it doesn't replace the need for solid coding 
skills in Python, HTML, JavaScript, and (at least some) knowledge of databases. 

So in short, you're limited only by your own knowledge. I'm sure a ruby or perl 
developer would say the same of their respective frameworks. 

Good luck
Steve

Sent from my iPhone

On Sep 4, 2010, at 12:45 PM, samie  wrote:

> sir what are the shortcomings and limitations of Django. i am newbie
> and got to develop my own cms using python.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: how do you build an html website in python?

2010-04-17 Thread Steven Elliott Jr
@codecub

If you are interested in just building an HTML website why not just
write it in HTML? Why do you think you need to use Python? What are
the requirements of the website? Do you need a database and
middleware? If so I would recommend following the django tutorial
first:

http://docs.djangoproject.com/en/dev/intro/tutorial01/

then read the django book

http://www.djangobook.com/

Of course it would be very helpful if you also know how to program in
Python and know about relational databases and webserver, and
yaddayadda but I'm sure you do since you know that you want to use
Django for your site.

On Apr 17, 9:06 am, codecub  wrote:
> i want to create a website like whalesalad.com and ive read through
> the python documentation but it doesnt explain building a website out
> of scratch in python
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group 
> athttp://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Giving up PHP. ...Can't decide between Django & Rails

2010-04-17 Thread Steven Elliott Jr
I came from java (spring mostly) then asp.net then php, rails and  
finally to django. While django is my favorite I can still use all the  
others just fine. Don't box yourself in and become a zealot of any one  
language/framework. Learn many and keep exploring.  It will only make  
you a better developer even if you only work professionally with one  
stack, learning and playing with other things will open up your mind.  
For me yes I love python and django but I also play with erlang, lua,  
haskell, xyz framework... you name it. It's good for yer noggin.


-Steven Elliott Jr

On Apr 17, 2010, at 6:29 AM, Massimiliano della Rovere <massimiliano.dellarov...@gmail.com 
> wrote:



Grok + zope3 could be a choice too.

On Sat, Apr 17, 2010 at 05:39, hcarvalhoalves <hcarvalhoal...@gmail.com 
> wrote:

Why do you have to "make a choice"? Learn both. They can be useful in
many different ways.

I learned Rails (and Ruby) before Django, because I saw some material
for Ruby that got me interested in hacking on it. Some time later,
Rails got really popular. Then lately I learned Python and Django, and
I've been working with it professionally for 2 years now.

Now I don't have much more interest in Rails anymore, because Django
seems to cover all you can do with Rails, plus the benefits of Python
(you have a faster language, with more libraries and in a more mature
state). Syntax and all for more is close to irrelevant - what matters
is productivity. Some people will get you into religious wars about
blocks, or test driven frameworks, or whatever is the trend... skip
over those.

I would recommend learning other frameworks too. Python got a big
share of web frameworks, that have their own focus on a particular
structure - some can be better for REST APIs than Django, for example.
[1] Ruby also got other frameworks than Rails, but they shine a little
less.

Also, I would recommend you to learn *the language* first, and using
the framework to play with it. Make sure you don't use this mindset of
"I'm sick of PHP - let me find a magic framework", otherwise you won't
get much further the 15 minutes blog tutorials. Real web applications
will still require a lot of your own components and glue code for the
framework, in addition to your domain logic.

Having said that, Rails is quite limiting, but still a good choice.

[1] http://wiki.python.org/moin/WebFrameworks

On 9 abr, 13:06, UnclaimedBaggage <baynej...@gmail.com> wrote:
> Hi folks,
>
> I'm a long-term (8 years) PHP developer who's recently started
> dabbling with Rails & Django. I REALLY like what I've seen from both
> frameworks and quite frankly, am a little miffed I didn't jump on  
the

> bandwagon earlier.
>
> I'm trying to decide between the two frameworks, but I'm
> struggling to get out of stalemate. If anyone can offer advice,  
I'd be

> very appreciative. Here are my current thoughts:
>
> WHAT I LIKE ABOUT DJANGO
> * I LOVE django-admin . For the sort of work I do, which is a lot of
> customised cart/cms stuff, this would save a lot of time.
> * Code reusability seems superior. Opinions?
> * Better perfomance?
> * I've half-built a shopping cart app in Django that I'm happy  
with. A

> quick dabble in Rails made this task seem a little more time-
> consuming, and I'm not comfortable with drop-in solutions
> * Server seems more stable. Using the rails dev server on a local
> linux box twice threw errors I couldn't trace, then worked fine  
again
> the next time I restarted my computer (having previously restarted  
the

> server with no result). Is this a common problem?
>
> WHAT I LIKE ABOUT RAILS
> * I prefer the syntax
> * There seems to be a lot more work for rails...with better pay
> * "Agile Rails" is a damn fantastic book. I haven't found much  
Django

> documentation I've enjoyed as much
> * Seems to be a little simpler
> * Seems to have a greater depth of features
> * Better AJAX integration from what I've seen
>
> Obviously I expect some django-tilted opinions here, but if anyone
> with
> experience in both can offer a balanced perspective on pros-n-cons  
of

> each it would be a big help.
>
> Cheers.

--
You received this message because you are subscribed to the Google  
Groups "Django users" group.

To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com 
.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en 
.



--
You received this message because you are subscribed to the Google  
Groups "Django users" group.

To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com 
.
For more options, visit this group at http://gr

Re: how do you build an html website in python?

2010-04-17 Thread Steven Elliott Jr
Python won't build a site for you by itself. Do you already know  
python, HTML, JavaScript, relational databases and the like? All of  
these things are still important. Python is only one piece of the  
overall puzzle.


-Steven Elliott Jr

On Apr 17, 2010, at 9:13 AM, "ge...@aquarianhouse.com" <ge...@aquarianhouse.com 
> wrote:



http://www.djangoproject.com/

On Apr 17, 3:06 pm, codecub <groilin...@gmail.com> wrote:

i want to create a website like whalesalad.com and ive read through
the python documentation but it doesnt explain building a website out
of scratch in python

--
You received this message because you are subscribed to the Google  
Groups "Django users" group.

To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com 
.
For more options, visit this group athttp://groups.google.com/group/ 
django-users?hl=en.


--
You received this message because you are subscribed to the Google  
Groups "Django users" group.

To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com 
.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en 
.




--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: OS X Server upgrade (10.6.3) can't load psycopg2 from apache2/modpython

2010-04-14 Thread Steven Elliott Jr

Righty. Glad you got it sorted.

Cheers mate

-Steven Elliott Jr

On Apr 14, 2010, at 5:39 PM, John Abraham <jabra...@ucalgary.ca> wrote:


It's definitely a system path / python path problem.  I did the brute
force method of linking psycopg to the django project directories,
twice, just to be sure:

  cd /Website/Django/times
  ln -s /opt/local/Library/Frameworks/Python.framework/Versions/2.6/
lib/python2.6/site-packages/psycopg2 psycopg2
  ln -s /opt/local/Library/Frameworks/Python.framework/Versions/2.6/
lib/python2.6/site-packages/psycopg2 times/psycopg2

now things work again.

On Apr 14, 3:31 pm, Steven Elliott Jr <steven.elliot...@me.com> wrote:
Just curious -- my python version is 2.6.1 and I never upgraded it  
yours says 2.6.4 -- was it always that version or is that something  
new?


When I first got it working a few months ago I somehow managed to get
apache2/mod_python to use the python that I installed with macports,
which is the 2.6.4 version in the /opt/local directory.

Anyway I'll let you know what I find out after upgrading -- I am  
using one server for the app and one for the postgres db so I'll  
update both and see which one shats the sheets.


Thanks, please let me know.

--
You received this message because you are subscribed to the Google  
Groups "Django users" group.

To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com 
.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en 
.




--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: OS X Server upgrade (10.6.3) can't load psycopg2 from apache2/modpython

2010-04-14 Thread Steven Elliott Jr
Hey John,

I am running Mac OS X Server(s) as well but have not yet updated to 10.6.3 - I 
am going to do this now and see if it breaks anything. My apps are all running 
using the preinstalled version so I'm curious to see if anything breaks. 

Just curious -- my python version is 2.6.1 and I never upgraded it yours says 
2.6.4 -- was it always that version or is that something new?

Anyway I'll let you know what I find out after upgrading -- I am using one 
server for the app and one for the postgres db so I'll update both and see 
which one shats the sheets.


On Apr 14, 2010, at 5:02 PM, John Abraham wrote:

> Is anyone familiar with configuration on OS X Server?
> 
> I had a nice app working, but now it broke, I think it broke when I
> upgraded the server from 10.6.2 to 10.6.3.
> 
> I know I have two python's installed, apple's and the macports one.
> It looks like my mod_python is using the macports one in /opt/local/
> Library/Frameworks/Python.framework/Versions/2.6.  That's probably the
> same python that my system shell uses:
> 
>   192:~ jabraham$ which python
>   /opt/local/bin/python
>   192:~ jabraham$ ls -l /opt/local/bin/python
>   lrwxr-xr-x  1 root  admin  9 Jan 11 08:41 /opt/local/bin/python ->
> python2.6
>   192:~ jabraham$ ls -l /opt/local/bin/python2.6
>   lrwxr-xr-x  1 root  wheel  73 Jan 11 00:32 /opt/local/bin/python2.6
> -> /opt/local/Library/Frameworks/Python.framework/Versions/2.6/bin/
> python2.6
> 
> and I can import psycopg2 from command line
> 
>   192:~ jabraham$ python
>   Python 2.6.4 (r264:75706, Jan 11 2010, 00:30:55)
>   [GCC 4.2.1 (Apple Inc. build 5646) (dot 1)] on darwin
>   Type "help", "copyright", "credits" or "license" for more
> information.
 import psycopg2
 
> 
> but when I try to load my django app it can't load psycopg2.  I expect
> my site-packages or system path got messed up or something but I'm
> really having trouble fixing it, since everything works when I invoke
> python manually (i.e. not from apache2/modpython).
> 
> I'm using Apple's default apache2 installation, and the full error
> message is below my signature.
> 
> --
> John Abraham
> 
> MOD_PYTHON ERROR
> 
> ProcessId:  75005
> Interpreter:'admin.hbaspecto.com'
> 
> ServerName: 'admin.hbaspecto.com'
> DocumentRoot:   '/Website/Django/'
> 
> URI:'/times/timesheets/jea'
> Location:   '/times'
> Directory:  None
> Filename:   '/Website/Django/times/timesheets/jea'
> PathInfo:   ''
> 
> Phase:  'PythonHandler'
> Handler:'django.core.handlers.modpython'
> 
> Traceback (most recent call last):
> 
>  File "/Library/Python/2.6/site-packages/mod_python/importer.py",
> line 1537, in HandlerDispatch
> 
>  File "/Library/Python/2.6/site-packages/mod_python/importer.py",
> line 1229, in _process_target
> 
>  File "/Library/Python/2.6/site-packages/mod_python/importer.py",
> line 1128, in _execute_target
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/core/handlers/modpython.py", line
> 228, in handler
>return ModPythonHandler()(req)
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/core/handlers/modpython.py", line
> 201, in __call__
>response = self.get_response(request)
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/core/handlers/base.py", line 73, in
> get_response
>response = middleware_method(request)
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/middleware/common.py", line 56, in
> process_request
>if (not _is_valid_path(request.path_info) and
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/middleware/common.py", line 142, in
> _is_valid_path
>urlresolvers.resolve(path)
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/core/urlresolvers.py", line 303, in
> resolve
>return get_resolver(urlconf).resolve(path)
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/core/urlresolvers.py", line 216, in
> resolve
>for pattern in self.url_patterns:
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/core/urlresolvers.py", line 245, in
> _get_url_patterns
>patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/core/urlresolvers.py", line 240, in
> _get_urlconf_module
>self._urlconf_module = import_module(self.urlconf_name)
> 
>  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/django/utils/importlib.py", line 35, in
> import_module
>__import__(name)
> 

Re: MySQLdb setup on snow leopard help

2010-04-12 Thread Steven Elliott Jr

Did you run the install as sudo?

-Steven Elliott Jr

On Apr 12, 2010, at 3:09 AM, Bdidi <bdi...@gmail.com> wrote:


I reinstalled XCode to include 10.4 support and tried again, and
MySQLdb is now installed, but now I get this:

File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/django/db/backends/mysql/base.py", line 13, in 
   raise ImproperlyConfigured("Error loading MySQLdb module: %s" % e)
django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb
module: dlopen(/Users/bduncan/.python-eggs/MySQL_python-1.2.3c1-py2.6-
macosx-10.3-fat.egg-tmp/_mysql.so, 2): Symbol not found:
_mysql_affected_rows

Can anyone point in the right direction on this?

--  
You received this message because you are subscribed to the Google  
Groups "Django users" group.

To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com 
.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en 
.




--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Admin issues

2010-04-09 Thread Steven Elliott Jr
Have you looked at your db? are the tables there that you wrote in your models. 
Did you run 

python manage.py syncdb and did you see verification that your tables were 
created?

If you want to see that the sql is being created run

python manage.py sqlall app_name to make sure its generating the sql you want. 
If everything is correct the only explanation is that you don't actually have 
any tables set up in the database.

On Apr 9, 2010, at 1:23 PM, Sheena wrote:

> I uncommented 'django.contrib.sessions' to no avail, and everything
> else is correct.
> 
> I'm not getting any error messages at all, I'm just not given the
> option to do anything with my tables from the admin site. I've gone
> through three different tutorials on it and they all say the same
> thing so it doesn't look like I've left anything out. I'm not sure if
> this is a stoopid question or not but could Windows XP be screwing
> with it? I was warned by an aquaintance that it does strange things to
> Django but I wasn't given any specifics and everything has been
> behaving beautifully until now. I'm using Djanga v1.1.1
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Giving up PHP. ...Can't decide between Django & Rails

2010-04-09 Thread Steven Elliott Jr
I think it largely boils down (as many have said) to a python vs ruby debate.

I personally hate Ruby... I think its perl with a nice syntax, its very obtuse 
and just downright hard to maintain as projects get bigger (IMHO, others I;m 
sure disagree).

As far was what is better about Django for me is the lack of "Magic" that rails 
developers love. I just find the whole monolithic approach very confusing and 
ugly in Rails. ALso I hate the way it handles views but thats just my opinion. 
I love that in django I can store my templates anywhere and reuse them from 
other apps if need be... anyway, at the end of the day the best thing you can 
do is try both and just make a decision. THe more time you spend deliberating 
about these things is more wasted time that you could have been writing an app. 
I came from PHP and never looked back... oh yeah and the Python and Django 
communities are just friendlier and more helpful (again IMHO).

CHeck this out if you want to see a great talk about Django.
http://blog.fluther.com/going-for-a-trot-on-the-django-pony/


On Apr 9, 2010, at 12:06 PM, UnclaimedBaggage wrote:

> Hi folks,
> 
> I'm a long-term (8 years) PHP developer who's recently started
> dabbling with Rails & Django. I REALLY like what I've seen from both
> frameworks and quite frankly, am a little miffed I didn't jump on the
> bandwagon earlier.
> 
> I'm trying to decide between the two frameworks, but I'm
> struggling to get out of stalemate. If anyone can offer advice, I'd be
> very appreciative. Here are my current thoughts:
> 
> WHAT I LIKE ABOUT DJANGO
> * I LOVE django-admin . For the sort of work I do, which is a lot of
> customised cart/cms stuff, this would save a lot of time.
> * Code reusability seems superior. Opinions?
> * Better perfomance?
> * I've half-built a shopping cart app in Django that I'm happy with. A
> quick dabble in Rails made this task seem a little more time-
> consuming, and I'm not comfortable with drop-in solutions
> * Server seems more stable. Using the rails dev server on a local
> linux box twice threw errors I couldn't trace, then worked fine again
> the next time I restarted my computer (having previously restarted the
> server with no result). Is this a common problem?
> 
> WHAT I LIKE ABOUT RAILS
> * I prefer the syntax
> * There seems to be a lot more work for rails...with better pay
> * "Agile Rails" is a damn fantastic book. I haven't found much Django
> documentation I've enjoyed as much
> * Seems to be a little simpler
> * Seems to have a greater depth of features
> * Better AJAX integration from what I've seen
> 
> 
> Obviously I expect some django-tilted opinions here, but if anyone
> with
> experience in both can offer a balanced perspective on pros-n-cons of
> each it would be a big help.
> 
> Cheers.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Setting up Django on snow leopard

2010-04-09 Thread Steven Elliott Jr
Its also a good idea to install the Developer Tools ... You should check which 
version of Python you are using too. I think be default OS X uses 2.6.1

This is what I get when I type "python" into the terminal:
Python 2.6.1 (r261:67515, Feb 11 2010, 00:51:29) 


On Apr 9, 2010, at 11:38 AM, Lee Hinde wrote:

> 
> 
> On Apr 8, 1:50 pm, CG  wrote:
>> I have successfully setup django, although I am not sure how I did
>> it.  Now I am trying to setup MySQLdb  but keep getting the error
>>   File "setup.py", line 5, in 
>> from setuptools import setup, Extension
>> ImportError: No module named setuptools
>> 
>> On Apr 8, 12:45 pm, CG  wrote:
>> 
>>> Nothing happens, I just get a >
>> 
>>> On Apr 8, 12:39 pm, Tim Shaffer  wrote:
>> 
 Very strange. What happens if you open a new Terminal window and run
 the following?
>> 
 python -c "import sys; print sys.path"
> 
> Google is your friend. There are a bunch of posts that will take you
> through the process.
> 
> Django & mysql are actually the easy steps. You should google 'django
> and snow leopard' for support with those and other topics.
> 
> I'm not suggesting you shouldn't ask questions here, just saying there
> are resources out there to help get you started.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Setting up Django on snow leopard

2010-04-09 Thread Steven Elliott Jr
Are you running the install as superuser?

I am running leopard too and ran into the same problem but once you run it as:

sudo python setup.py install it should work..

Also, dumb question but do you have mysql installed? Its also a good idea to 
put this:

# mysql path
PATH=${PATH}:/usr/local/mysql/bin

in your .bash_profile as well... for later use.

On Apr 9, 2010, at 11:38 AM, Lee Hinde wrote:

> 
> 
> On Apr 8, 1:50 pm, CG  wrote:
>> I have successfully setup django, although I am not sure how I did
>> it.  Now I am trying to setup MySQLdb  but keep getting the error
>>   File "setup.py", line 5, in 
>> from setuptools import setup, Extension
>> ImportError: No module named setuptools
>> 
>> On Apr 8, 12:45 pm, CG  wrote:
>> 
>>> Nothing happens, I just get a >
>> 
>>> On Apr 8, 12:39 pm, Tim Shaffer  wrote:
>> 
 Very strange. What happens if you open a new Terminal window and run
 the following?
>> 
 python -c "import sys; print sys.path"
> 
> Google is your friend. There are a bunch of posts that will take you
> through the process.
> 
> Django & mysql are actually the easy steps. You should google 'django
> and snow leopard' for support with those and other topics.
> 
> I'm not suggesting you shouldn't ask questions here, just saying there
> are resources out there to help get you started.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Admin issues

2010-04-09 Thread Steven Elliott Jr
Uncomment:  #'django.contrib.sessions',

make sure to import admin from django.contrib and turn admin.autodiscover()

and yes, error messages would be helpful... if any.


On Apr 9, 2010, at 10:32 AM, Stuart wrote:

> What you have looks about right. What result are you getting? An error
> message?
> 
> 
> --Stuart
> 
> On Apr 9, 7:44 am, Sheena  wrote:
>> Hey hey. I'm a little new to Django so I've been following through the
>> Django Book v2 and I'm having trouble adding my models to the admin
>> site. I'm pretty sure I've followed instructions correctly, I've also
>> tried following some random advice I found to no avail. Any help would
>> be greatly appreciated. Below are some code snippets:
>> 
>> from models.py:
>> class Publisher(models.Model):
>> name = models.CharField(max_length=30)
>> address = models.CharField(max_length=50)
>> city = models.CharField(max_length=60)
>> state_province = models.CharField(max_length=30)
>> country = models.CharField(max_length=50)
>> website = models.URLField()
>> 
>> def __unicode__(self):
>> return self.name
>> 
>> class admin:
>> pass
>> the last two lines don't seem to change anything.
>> 
>> form settings.py
>> INSTALLED_APPS = (
>> 'django.contrib.auth',
>> 'django.contrib.contenttypes',
>> #'django.contrib.sessions',
>> 'django.contrib.admin',
>> #'django.contrib.comments',
>> #'django.contrib.sites',
>> 'newProj.books',
>> )
>> MIDDLEWARE_CLASSES = (
>> 'django.middleware.common.CommonMiddleware',
>> 'django.contrib.sessions.middleware.SessionMiddleware',
>> 'django.contrib.auth.middleware.AuthenticationMiddleware',
>> )
>> 
>> DATABASE_ENGINE = 'sqlite3'
>> DATABASE_NAME =
>> os.path.join(os.path.dirname(__file__),'testDB').replace('\\','/')
>> DATABASE_USER = '' # Not used with sqlite3.
>> DATABASE_PASSWORD = '' # Not used with sqlite3.
>> DATABASE_HOST = '' # Not used with sqlite3.
>> DATABASE_PORT = '' # Set to empty string for default. Not
>> used
>> 
>> And finally from admin.py
>> class AuthorAdmin(admin.ModelAdmin):
>> pass
>> admin.site.register(Author, AuthorAdmin)
>> admin.site.register(Publisher)
>> admin.site.register(Book)
>> 
>> Any help would be greatly appreciated
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Admin issues

2010-04-09 Thread Steven Elliott Jr
@Sheena,

sorry -- I didnt read all of your email -- I think if you've got it all in 
admin.py make sure you're importing admin from django.contrib.

To activate the admin interface though you need to do:

1. Add 'django.contrib.admin' to the INSTALLED_APPS setting (which you did)
2. Make sure INSTALLED_APPS contains 'django.contrib.auth, contettypes, and 
sessions  (I see sessions is commented out on yours.
3. Middle ware classes needs to contain 
'django.middleware.common.CommomMiddleware, 
'django.contrib.sessions.middlewarae.SessionMiddleWare, and 
django.contrib.auth.middleware.AuthenticationMiddleware.

run python manage.py syncdb

then make sure that you have this in urls.py file:

from django.contrib import admin
admin.autodiscover()

#include this URLPattern...
urlpatterns = patterns(' ',
# ...
(r'^admin/', include(admin.site.urls)),
# ...
)

Hope this helps!



but you will still need to make sure that you have
On Apr 9, 2010, at 9:13 AM, Steven Elliott Jr wrote:

> In your urls. py make sure you have:
> 
> from django.contrib import admin
> admin.autodiscover()
> 
> and
> 
> that you've uncommented the (r'^admin/', include(admin.site.urls)), 
> 
> in the tuple: urlpatterns = patterns.
> 
> On Apr 9, 2010, at 8:44 AM, Sheena wrote:
> 
>> Hey hey. I'm a little new to Django so I've been following through the
>> Django Book v2 and I'm having trouble adding my models to the admin
>> site. I'm pretty sure I've followed instructions correctly, I've also
>> tried following some random advice I found to no avail. Any help would
>> be greatly appreciated. Below are some code snippets:
>> 
>> from models.py:
>> class Publisher(models.Model):
>>name = models.CharField(max_length=30)
>>address = models.CharField(max_length=50)
>>city = models.CharField(max_length=60)
>>state_province = models.CharField(max_length=30)
>>country = models.CharField(max_length=50)
>>website = models.URLField()
>> 
>>def __unicode__(self):
>>return self.name
>> 
>>class admin:
>>pass
>> the last two lines don't seem to change anything.
>> 
>> form settings.py
>> INSTALLED_APPS = (
>>'django.contrib.auth',
>>'django.contrib.contenttypes',
>>#'django.contrib.sessions',
>>'django.contrib.admin',
>>#'django.contrib.comments',
>>#'django.contrib.sites',
>>'newProj.books',
>> )
>> MIDDLEWARE_CLASSES = (
>>'django.middleware.common.CommonMiddleware',
>>'django.contrib.sessions.middleware.SessionMiddleware',
>>'django.contrib.auth.middleware.AuthenticationMiddleware',
>> )
>> 
>> DATABASE_ENGINE = 'sqlite3'
>> DATABASE_NAME =
>> os.path.join(os.path.dirname(__file__),'testDB').replace('\\','/')
>> DATABASE_USER = '' # Not used with sqlite3.
>> DATABASE_PASSWORD = '' # Not used with sqlite3.
>> DATABASE_HOST = '' # Not used with sqlite3.
>> DATABASE_PORT = '' # Set to empty string for default. Not
>> used
>> 
>> And finally from admin.py
>> class AuthorAdmin(admin.ModelAdmin):
>>pass
>> admin.site.register(Author, AuthorAdmin)
>> admin.site.register(Publisher)
>> admin.site.register(Book)
>> 
>> Any help would be greatly appreciated
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Django users" group.
>> To post to this group, send email to django-us...@googlegroups.com.
>> To unsubscribe from this group, send email to 
>> django-users+unsubscr...@googlegroups.com.
>> For more options, visit this group at 
>> http://groups.google.com/group/django-users?hl=en.
>> 
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Admin issues

2010-04-09 Thread Steven Elliott Jr
In your urls. py make sure you have:

from django.contrib import admin
admin.autodiscover()

and

that you've uncommented the (r'^admin/', include(admin.site.urls)), 

in the tuple: urlpatterns = patterns.

On Apr 9, 2010, at 8:44 AM, Sheena wrote:

> Hey hey. I'm a little new to Django so I've been following through the
> Django Book v2 and I'm having trouble adding my models to the admin
> site. I'm pretty sure I've followed instructions correctly, I've also
> tried following some random advice I found to no avail. Any help would
> be greatly appreciated. Below are some code snippets:
> 
> from models.py:
> class Publisher(models.Model):
>name = models.CharField(max_length=30)
>address = models.CharField(max_length=50)
>city = models.CharField(max_length=60)
>state_province = models.CharField(max_length=30)
>country = models.CharField(max_length=50)
>website = models.URLField()
> 
>def __unicode__(self):
>return self.name
> 
>class admin:
>pass
> the last two lines don't seem to change anything.
> 
> form settings.py
> INSTALLED_APPS = (
>'django.contrib.auth',
>'django.contrib.contenttypes',
>#'django.contrib.sessions',
>'django.contrib.admin',
>#'django.contrib.comments',
>#'django.contrib.sites',
>'newProj.books',
> )
> MIDDLEWARE_CLASSES = (
>'django.middleware.common.CommonMiddleware',
>'django.contrib.sessions.middleware.SessionMiddleware',
>'django.contrib.auth.middleware.AuthenticationMiddleware',
> )
> 
> DATABASE_ENGINE = 'sqlite3'
> DATABASE_NAME =
> os.path.join(os.path.dirname(__file__),'testDB').replace('\\','/')
> DATABASE_USER = '' # Not used with sqlite3.
> DATABASE_PASSWORD = '' # Not used with sqlite3.
> DATABASE_HOST = '' # Not used with sqlite3.
> DATABASE_PORT = '' # Set to empty string for default. Not
> used
> 
> And finally from admin.py
> class AuthorAdmin(admin.ModelAdmin):
>pass
> admin.site.register(Author, AuthorAdmin)
> admin.site.register(Publisher)
> admin.site.register(Book)
> 
> Any help would be greatly appreciated
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Stuck going through tutorial (with def __unicode__(self): bit)

2010-03-20 Thread Steven R. Elliott Jr
Right. 9 times out of ten its the server not restarting which someone
already mentioned. If you're new to python try using ecli

On Mar 20, 2010 10:22 AM, "Daniel Roseman"  wrote:

On Mar 20, 1:56 pm, Ed57  wrote:
> Hi
>
> I'm just trying to learn abou...
You haven't shown us your code, but my guess would be one of two
issues - either the server hasn't restarted itself, in which case hit
ctrl-c and do it manually; or it's an indentation issue, so that the
method is being parsed as a standalone function rather than a member
of the Poll class.
--
DR.


-- 
You received this message because you are subscribed to the Google Groups
"Django users" group

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: "ImportError: No module named django" with MacPorts

2010-03-03 Thread Steven R. Elliott Jr
Hello Tim,

I'm a fellow Mac user but I don't quite understand the problem that you are
having installing Django on OS X 10.6.

I installed Django today on a new Mac and it took all of 5 minutes and I
downloaded the tarball, extracted it and threw it in my home directory.

I believe that 10.6 comes comes with Python 2.6.1 out of the box so there
shouldn't have been a need to install 2.5 unless you are married to 2.5 for
some reason. Also, when you ran the python setup.py install command did you
run it as superuser? so, you need to plop sudo in front of your command...
if not, it won't have all the permissions it needs to install into your
system properly. Lastly, do you have the Apple Developer tools installed?

Not sure if any of this helps but I know that when I ran the install command
and didn't use:
*sudo* python setup.py install it crapped itself and complained that it
didn't have permission.

Good luck,
Steve

On Wed, Mar 3, 2010 at 2:15 PM, Tones  wrote:

> Hi --
>
> I'm attempting to run Django on OSX 10.6. I've installed Python2.5 and
> Py25-Django (Django v1.1) via MacPorts. But I am receiving the famed
> "ImportError: No module named django" error.
>
> Django is installed in this directory:
> /opt/local/lib/python2.5/site-packages/django/
>
> To check my $PYTHONPATH, I went to the Python shell and tried "print
> sys.path". The site-packages path is indeed included in my PYTHONPATH.
>
> However, when I try "print sys.modules" in the same Python shell,
> Django is not included.
>
> I can't figure out what's going on. Django's INSTALL.TXT says all
> that's needed to install Django is to copy it into the site-packages
> directory. But in this case that hasn't worked. Is something else
> needed to give Python access to Django?
>
> I suppose I could forget MacPorts and attempt to install from SVN or a
> tarball. But I would really prefer to work through the package
> manager, especially since it's so unclear what has gone wrong.
>
> Any thoughts appreciated. Thanks.
>
> =Tim=
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



SQL Server 2008

2010-03-03 Thread Steven R. Elliott Jr
Hello,

I have been asked to write a front-end for an accounting system that will
allow business participating in certain benefits plans the ability to
receive and pay their bill online, reconcile bills, and add/delete members.
The problem is that the database is an existing SQL Server 2008 system and I
have not found any decent ways to connect to this database. The db itself
contains over 200 tables but I am only interested in 7 of them. I would love
to be able to use Django to develop the front end rather than ASP.NET but I
don't see a great deal of support out there for SQL Server '08 (I am using a
Mac right now... not real keen on having to bootcamp windows onto my Mac).
Has anyone had this type of project before? If so, I'd love to hear how you
got started.

Thanks in advance,

Steven Elliott

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django in the enterprise?

2010-02-24 Thread Steven Elliott Jr
@Eric Chapman

I know the term "enterprise" is pretty crappy but I didn't know how else to 
describe and I was hesitant to even throw it out there. I agree there are some 
seriously crappy "enterprise apps" out there, hell when i started working I 
inherited a ton! Anyway, thanks for the insight; I appreciate it.

Steve

On Feb 24, 2010, at 2:31 PM, Eric Chamberlain wrote:

> 
> On Feb 24, 2010, at 6:23 AM, Steven Elliott Jr wrote:
> 
>> Dear friends,
>> I apologize for writing this type of question to the community but I would 
>> appreciate any information you could pass on considering the breadth of 
>> knowledge within this group. 
>> I know that the word “enterprise” gives some people the creeps, but I am 
>> curious to know if anyone has experience creating enterprise applications, 
>> similar to something like say… Java EE applications, which are highly 
>> concurrent, distributed applications with Django? I know Java has its own 
>> issues but its kind of viewed as THE enterprise framework and I think that’s 
>> unfortunate.
>> Some people say that Rails is a good replacement for Java EE but what about 
>> Django? Has anyone ever used it in this context? You only ever see pretty 
>> standard websites on djangosites.org and it seems like its capable of so 
>> much more. I am planning on scrapping some of our old systems which are 
>> written mostly on ASP.NET and some Java for something more easily 
>> maintainable. I started using Django for some other applications and find it 
>> to be fantastic for what I am using it for (Corporate news, intranet, etc.) 
>> internally but what about something like… an accounts receivable system, or 
>> a billing system, etc. 
>> I would hate to see a framework such as this pigeon-holed into a category it 
>> doesn't need to be. It seems to be used for social media/networking, 
>> content-heavy sites, not so much data processing, etc. I feel that it has 
>> all the elements needed to start down this path. Anyone have any thoughts?
>> 
> 
> 
> The term "enterprise", is pretty loaded.  I've managed some really shitty 
> "enterprise" apps, like Peoplesoft and Siebel CRM.
> 
> Django can definitely do more than serve up websites.  We use django to run 
> our call routing infrastructure.  
> 
> Our main app does have a mobile web interface for making calls, but the 
> backend telephony servers also communicate with Django via web services.  
> Django does all the call routing logic.
> 
> --
> Eric Chamberlain, Founder
> RF.com - http://RF.com/
> 
> 
> 
> 
> 
> 
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django in the enterprise?

2010-02-24 Thread Steven Elliott Jr
@Philip

Thanks for information -- very good advice. I appreciate all the input from 
everyone else as well. I intend to start using Django for almost everything 
going forward.

Thanks,
Steve

On Feb 24, 2010, at 2:06 PM, Phlip wrote:

> Steven Elliott Jr wrote:
> 
>> Right now we have Java and ASP.NET doing most of the work for us but the 
>> systems are old and need updating. Not to mention budgetary constraints are 
>> big thing now. I used Django to write an intranet application and it was 
>> very nice and I think I can probably handle the other stuff, just wanted to 
>> draw on other's experience.
> 
> Those tools are clunky and hard to program, driving up the cost of
> maintenance. Consider this pattern:
> 
>  http://martinfowler.com/bliki/StranglerApplication.html
> 
> Each time someone requests a new feature, do it in Django instead, and
> link it to the old system. (And use TDD to write it all.)
> 
> Eventually a new system will emerge, completely obscuring the old one.
> 
> And, yes, Django can do webservices and such, just like platforms with
> much bigger advertising budgets.
> 
> --
>  Phlip
>  http://c2.com/cgi/wiki?ZeekLand
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django in the enterprise?

2010-02-24 Thread Steven Elliott Jr
Thank you to all for your comments. It has been most helpful.

On Feb 24, 2010, at 11:05 AM, Andy McKay wrote:

> 
> On 2010-02-24, at 6:40 AM, Steven Elliott Jr wrote:
>> Right now we have Java and ASP.NET doing most of the work for us but the 
>> systems are old and need updating. Not to mention budgetary constraints are 
>> big thing now. I used Django to write an intranet application and it was 
>> very nice and I think I can probably handle the other stuff, just wanted to 
>> draw on other's experience.
> 
> Yes there are many large scale (in terms of data and complexity) running on 
> Django. We've just completed a large "enterprise" project converting classic 
> ASP to Django and its gone extremely well. It's not on djangosites because 
> the NDA denies it.
> 
> What you might need to consider if you are pitching to management is making 
> sure that training, consulting and support is available from companies (which 
> it is).
> --
>  Andy McKay, @clearwind
>  http://clearwind.ca/djangoski
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django in the enterprise?

2010-02-24 Thread Steven Elliott Jr
@Shawn

Sorry if I was not clear with my question. It seems like a lot of sites that I 
have seen on djangosites are news sites, or content-driven sites like blogs, 
personal web pages, social networking-type sites like fluther.com, etc. I was 
just curious if anyone has every sat down and wrote a distributed application 
to handle the internal workings of a business. For instance in my company we 
administer a range of benefits to over a million participants. We have to do 
claims processing for health insurance claims, perform EDI transactions that 
are HIPAA compliant, administer 401(k) benefits, administer Pension benefits, 
etc. All of these things require system for the internal staff and for users 
from the outside to access. Employers need to pay for their employee's 
benefits, reconcile bills, participants need to check account balances, 
reallocate investments, etc. I was just wondering if anyone has used Django to 
do this (we host everything ourselves, btw).

Right now we have Java and ASP.NET doing most of the work for us but the 
systems are old and need updating. Not to mention budgetary constraints are big 
thing now. I used Django to write an intranet application and it was very nice 
and I think I can probably handle the other stuff, just wanted to draw on 
other's experience.

Thanks,
Steve

On Feb 24, 2010, at 9:33 AM, Shawn Milochik wrote:

> What do you mean by '...a good replacement for Java EE..."? Python is a 
> language. Django is a framework written in Python. You can make any kind of 
> site at all with them.
> 
> My company's Web applications do things like fund debit cards, communicate 
> with bank APIs, calculate driving reimbursement amounts by distance and make 
> the appropriate deposit, etc. 
> 
> I'm probably just missing the point of your question. What I don't understand 
> is the distinction you make between 'pretty standard' sites and sites that 
> deal with accounts receivable. The only difference I see is that in one case 
> someone wrote some accounts receivable functionality. I don't see that as any 
> different from a site adding tags or comments. It's all just code.
> 
> Shawn
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Django in the enterprise?

2010-02-24 Thread Steven Elliott Jr
Dear friends,
I apologize for writing this type of question to the community but I would 
appreciate any information you could pass on considering the breadth of 
knowledge within this group. 
I know that the word “enterprise” gives some people the creeps, but I am 
curious to know if anyone has experience creating enterprise applications, 
similar to something like say… Java EE applications, which are highly 
concurrent, distributed applications with Django? I know Java has its own 
issues but its kind of viewed as THE enterprise framework and I think that’s 
unfortunate.
Some people say that Rails is a good replacement for Java EE but what about 
Django? Has anyone ever used it in this context? You only ever see pretty 
standard websites on djangosites.org and it seems like its capable of so much 
more. I am planning on scrapping some of our old systems which are written 
mostly on ASP.NET and some Java for something more easily maintainable. I 
started using Django for some other applications and find it to be fantastic 
for what I am using it for (Corporate news, intranet, etc.) internally but what 
about something like… an accounts receivable system, or a billing system, etc. 
I would hate to see a framework such as this pigeon-holed into a category it 
doesn't need to be. It seems to be used for social media/networking, 
content-heavy sites, not so much data processing, etc. I feel that it has all 
the elements needed to start down this path. Anyone have any thoughts?

Thank you very much for your time.

Best,
Steven Elliott

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Passenger 57 - a Django query problem

2010-02-20 Thread Steven Elliott Jr
I've always found both the Django and Python communities to be among  
the friendliest and most helpful. Please be kind to one another and  
respectful of everyones comments. We are here to support one another  
in our efforts to better our django skills and to better the community  
and project as a whole. Let's not start bickering amongst ourselves...


Best,
Steven Elliott

Sent from my iPhone

On Feb 20, 2010, at 7:19 PM, Russell Keith-Magee  
 wrote:



On Sun, Feb 21, 2010 at 4:11 AM, Sithembewena Lloyd Dube
 wrote:
I wonder what Atamert the peacemaker has to say now, since the  
person to
whose defense he came admitted he was wrong. Amazing to note that  
Atamert
noticed my directness to Bruno, but did not notice how nasty Bruno  
was to

other respondents (namely Emily and Derek).

What have you to say, o' wise Atamert?


Ok, I'm stepping in here.

Emily is right - this sort of tone is *exactly* what we don't want on
Django users. Django-users has historically been a very friendly
place. I don't want that to change.

Bruno; Lloyd; Atamert -  at this point, I don't care who started it.
When you wrestle in mud, everyone gets dirty - even the bystanders. So
Stop. Now.

If you want to have some petty name calling argument, take it  
somewhere else.


If you persist in posting to django-users with anything other than
helpful responses to the original question, I will start banning
accounts.

Yours,
Russ Magee %-)

--
You received this message because you are subscribed to the Google  
Groups "Django users" group.

To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com 
.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en 
.




--
You received this message because you are subscribed to the Google Groups "Django 
users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django IDE

2010-02-15 Thread Steven Elliott Jr
TextMate! 

On Feb 15, 2010, at 5:45 AM, Anton Bessonov wrote:

> http://www.vim.org/
> 
> dj_vishal schrieb:
>> Hello
>> 
>>   Hi to all am new to the Django Framework.am learning django
>>   Which IDE is suitable for Django ..plz help me in right way
>> 
>>   Thanks in Advance
>>   vishal
>>   2009vis...@gmail.com
>>  
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to 
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/django-users?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: widget=forms.HiddenInput doesn't work

2009-04-02 Thread Michael Rose Jr.

This was fixed by upgrading to the latest version in SVN.

Thanks for your help B

On Apr 1, 8:57 pm, "Michael Rose Jr." <michaelros...@gmail.com> wrote:
> On Apr 1, 8:40 pm, Brian Neal <bgn...@gmail.com> wrote:
>
>
>
> > On Apr 1, 10:19 pm, "Michael Rose Jr." <michaelros...@gmail.com>
> > wrote:
>
> > > Brian. Thanks for responding. I mean to post "name". I've been
> > > experimenting with other field types, which why I accidentally pasted
> > > "last". Here is the HTML for "name".
> > > Name: > > type="text" name="name" maxlength="45" />
>
> > > Here's the model.http://dpaste.com/22453/
> > > Thanks again for your help.
>
> > > Riz
>
> > Oh, one more thing. How are you displaying your form in your template?
> > Can you post that part of your template?
>
> > BN
>
> Hi Brian,
>
> Here's the template:http://dpaste.com/22457/
>
> Here's the "view source" (Line 5)http://dpaste.com/22458/
>
> I am seeing this issue in the development server and in production/
> Apache. I restarted both and cleared my cache in my browsers just to
> be sure that wasn't the issue.
>
> Python 2.5.2 (r252:60911, Jan  4 2009, 21:59:32)
> [GCC 4.3.2] on linux2
> Type "help", "copyright", "credits" or "license" for more information.>>> 
> import django
> >>> django.VERSION
>
> (1, 0, 2, 'final', 0)
>
>
>
> Thanks,
>
>  Riz
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: widget=forms.HiddenInput doesn't work

2009-04-01 Thread Michael Rose Jr.

On Apr 1, 8:40 pm, Brian Neal <bgn...@gmail.com> wrote:
> On Apr 1, 10:19 pm, "Michael Rose Jr." <michaelros...@gmail.com>
> wrote:
>
>
>
> > Brian. Thanks for responding. I mean to post "name". I've been
> > experimenting with other field types, which why I accidentally pasted
> > "last". Here is the HTML for "name".
> > Name: > type="text" name="name" maxlength="45" />
>
> > Here's the model.http://dpaste.com/22453/
> > Thanks again for your help.
>
> > Riz
>
> Oh, one more thing. How are you displaying your form in your template?
> Can you post that part of your template?
>
> BN

Hi Brian,

Here's the template:
http://dpaste.com/22457/

Here's the "view source" (Line 5)
http://dpaste.com/22458/

I am seeing this issue in the development server and in production/
Apache. I restarted both and cleared my cache in my browsers just to
be sure that wasn't the issue.

Python 2.5.2 (r252:60911, Jan  4 2009, 21:59:32)
[GCC 4.3.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import django
>>> django.VERSION
(1, 0, 2, 'final', 0)
>>>

Thanks,

 Riz


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: widget=forms.HiddenInput doesn't work

2009-04-01 Thread Michael Rose Jr.

On Apr 1, 6:53 pm, Brian Neal  wrote:
> On Apr 1, 8:16 pm, rizzoo  wrote:
>
> > How do I make a field hidden when using ModelForm?  I tried
> > HiddenInput but it appears to be ignored.
>
> > code:http://dpaste.com/22290/
> > Line 9
>
> > Here's what View Source shows for that line in the browners:
> > Last: > name="last" maxlength="45">
>
> Well it looks like you are trying to hide the field "name". So why are
> you showing us the HTML for the field named "last"?
>
> I just did this the other day and it worked for me.
>
> Can you post your model code too?
>
> BN

Brian. Thanks for responding. I mean to post "name". I've been
experimenting with other field types, which why I accidentally pasted
"last". Here is the HTML for "name".
Name:

Here's the model. http://dpaste.com/22453/
Thanks again for your help.

Riz

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: FormWizard: Setting up a ChoiceField.choices based on previous forms,

2008-12-31 Thread David Durham, Jr.

On Tue, Dec 30, 2008 at 3:16 PM, Ariel Mauricio Nunez Gomez
 wrote:
> Hello list,
> Today I started using FormWizard and could not find a clean way to populate
> a choices field based on previously submitted forms, I ended up overriding
> the render method like this(The only changed line is the one highlited):



If you're doing a lot of FormWizard work, maybe take a look at the
Session-based FormWizard I wrote and give me some feedback.

   http://code.djangoproject.com/ticket/9200

It sounds like you have a reasonable solution to your issue, but I
thought I'd go ahead and solicit some feedback anyway, and maybe this
class I wrote could benefit you some.

Thanks,
Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: How to avoid out of sync sequence for primary key using Postgresql?

2008-10-16 Thread David Durham, Jr.

On Thu, Oct 16, 2008 at 2:38 PM, cfobel <[EMAIL PROTECTED]> wrote:
> I recently encountered a situation where the sequence for the primary
> key of one of my models became out of sync, which caused the following
> error when trying to save a new model instance:
>
> IntegrityError ...  'duplicate key violates unique constraint
> "myapp_mymodel_pkey"'

Like you said, if you inserted a record with a manual ID greater than
the current sequence value, assuming you're moving forward through a
sequence of numbers from lower numbers to greater ones, then you could
see this.  Or if you actually changed the sequence.  You might have
ran an 'alter sequence' statement.

Switching to MySQL is not going to help you out here.

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: django-jython-postgres driver

2008-10-13 Thread David Durham, Jr.

On 10/13/08, dusans <[EMAIL PROTECTED]> wrote:
>  I have writen a Test.java with:
>  Class.forName("org.postgresql.Driver");
>
>  It works, so that means it should work.
>
>  But jython tells me: DatabaseError: driver [org.postgresql.Driver] not
>  found
>
>  What am i doing wrong
>  I have been reading documentation and googled to long, kinda giving up
>  on jython :X

Nothing in your message is really Django specific, so far as I know,
and you might have better luck in a purely Jython forum.  My initial
thinking is that perhaps the classpath for your test environment is
not the same as your Jython/Django one.  With that said, I don't
really know much about what it takes to use JDBC drivers with
Django/Jython.

HTH,
-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: using request.POST as keyword args

2008-10-09 Thread David Durham, Jr.

> I do not understand why you want to do this.  Why not just pass request.POST
> without the **, and declare your function to take a single argument which
> you expect to be a dictionary-like object (as request.POST, a QueryDict,
> is)?.  That is:
>
> result = ab.perform(request.POST)
> where:
> def perform(self, datadict):
>
> What could you do with 'kwargs' in your syntax that you cannot do with
> 'datadict' in this alternative?

What if he wanted to do something like:

   ab.perform(name='x', y=12) or whatever, but also have the option to use
   ab.perform(**a_dict) or
   ab.perform(a_dict)

Can you do something like:

def perform(self, datadict=None, **kwargs):
  if datadict is None:
  datadict = kwargs
  elif kwargs is not None:
  datadict.update(kwargs)

I'm not sure that this would work; just kind of thinking out loud.

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



djangosnippets.org list navigation

2008-10-08 Thread David Durham, Jr.

The list navigation on djangosnippets is not so good.  Take this page
for instance:

 http://www.djangosnippets.org/users/

I happened to stumble across the following jquery plugin which might
be a quick fix for some of the issues (though searching should be
added to):

   http://www.ihwy.com/labs/jquery-listnav-plugin.aspx

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: displaying list from dictionnary -django 1.0

2008-10-03 Thread David Durham, Jr.

On Fri, Oct 3, 2008 at 12:13 PM, tsmets <[EMAIL PROTECTED]> wrote:
> I have an application that records the status of an applications.
> Basically something like :
>  _ started-request
>  _ started
>  _ stop-requested
>  _ stopped
> + some technical informations (version, host, URL, ...)
>
> I thought having a page that display per environment : dev, test,
> acceptance, prod the status for one application.
> I can easilly build a dictionnary where the keys is for that specific
> environment the last 5 status change (named in my code :
> app_deployed_status_lst).

If I have you correctly, your data looks something like:

env_history = { dev : [
{'started' : 'x', 'stopped' : 'y', 'version' : 'z'},
 ... ],
   test : [
   ],
   ..
}

so you can do something like:

{% for env, statuses in env_history.items() %}
  {{ env }}
  {% for status in statuses %}
 {{ status.version }} {{ status.started }} to {{ status.stopped  }}
  {% endfor %}
{% endfor %}


-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: Form controls for choosing from long lists

2008-09-26 Thread David Durham, Jr.

On Fri, Sep 26, 2008 at 12:12 PM, Donn <[EMAIL PROTECTED]> wrote:
>
> Hi,
> I thought I'd ask before rolling my own (at tedious pace) widget/whatever:
>
> If you have a foreign key field to a table of thousands of, say, author names,
> the drop-down control becomes a real problem:
> 1. It's not paged so all the items have to be stuffed into the html.
> 2. It's damn hard to use.
>
> What are the alternatives? Any working solutions out there? How does one offer
> a choice out of thousands?

You could use something like an auto completing combo box.  I don't
have any examples of how this is done with Django.

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: amd64 vs x86 hosting

2008-09-25 Thread David Durham, Jr.

>> I think the primary difference is the amount of RAM that is supported
>> and whether or not you have compatible software.  With that said, all
>> modern processors are x64 so you probably want to default with an x64
>> OS unless you need x86 for software compatibility reasons.
>
> That's not what our tests tells. Just swaping operating system build
> for amd64 gives some 10% ~ 15% gain. It's a gain that enables
> inserting a small site into the same box.

I hope you end up running amd64 on Intel(R) Core(TM) 2 Duo because you
can get another 10 to 15 percent improvement that way.  :)

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: Multiple instances using mod_python

2008-09-24 Thread David Durham, Jr.

> I see on this thread
> 
> from last year that there is suspicion that Apache can at times misdirect
> mod_python requests to the wrong mod_python instance.

You could try mod_wsgi.

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: amd64 vs x86 hosting

2008-09-24 Thread David Durham, Jr.

On Wed, Sep 24, 2008 at 11:07 AM, David Durham, Jr.
<[EMAIL PROTECTED]> wrote:
> On Wed, Sep 24, 2008 at 6:14 AM, mcosta <[EMAIL PROTECTED]> wrote:
>> One question: ¿amd64 or x86? we've got some bechmark claiming superior
>> performance for amd64, both with python and mysql, but then we can not
>> tune with psyco. We've taken a look at pyrex but we do not know even
>> if we are shooting in our foot with any of these. ¿are these
>> technologies useful for actual web app tuning?
>
> I think the primary difference is the amount of RAM that is supported
> and whether or not you have compatible software.  With that said, all
> modern processors are x64 so you probably want to default with an x64
> OS unless you need x86 for software compatibility reasons.

Actually I don't know that all modern processors are x64, but it seems
to me that the server ones are.

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: amd64 vs x86 hosting

2008-09-24 Thread David Durham, Jr.

On Wed, Sep 24, 2008 at 6:14 AM, mcosta <[EMAIL PROTECTED]> wrote:
> One question: ¿amd64 or x86? we've got some bechmark claiming superior
> performance for amd64, both with python and mysql, but then we can not
> tune with psyco. We've taken a look at pyrex but we do not know even
> if we are shooting in our foot with any of these. ¿are these
> technologies useful for actual web app tuning?

I think the primary difference is the amount of RAM that is supported
and whether or not you have compatible software.  With that said, all
modern processors are x64 so you probably want to default with an x64
OS unless you need x86 for software compatibility reasons.

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: Two Django visions running at once.

2008-09-23 Thread David Durham, Jr.

On Wed, Sep 17, 2008 at 3:21 PM, KillaBee
<[EMAIL PROTECTED]> wrote:
>
> Is it possible to have two versions of django running at the same time
> on an Ubuntu server(9.0 and 1.0)?
> It is taking to long to recode, and until I do I wanted It up and
> running with the old version.
> I got the tar.gz from the web site, but do I have to get rid of the
> new version?

This is the kind of thing that 'virtualenv' deals with.  On ubuntu you
can set that up with:

$ sudo apt-get install python-setuptools
$ sudo easy_install virtualenv
$ virtualenv --no-site-packages /path/to/sandbox1
$ virtualenv --no-site-packages /path/to/sandbox2

then, checkout or download the different django version and place/link them in:

/path/to/sandbox1/lib/pythonX.X/site-packages/
/path/to/sandbox2/lib/pythonX.X/site-packages/

you can test with

/path/to/sandbox1/bin/python manage.py runserver
/path/to/sandbox2/bin/python manage.py runserver

As far as apache configuration goes, this kind of thing is pretty
easily configured with mod_wsgi.

-Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: How to simulate recursive inlines in admin?

2008-09-22 Thread David Durham, Jr.

2008/9/22 Steve Holden <[EMAIL PROTECTED]>:
> This all seems rather ambitious for the admin. Isn't it supposed to be a
> simple application, and aren't those kind of functions supposed to be
> implemented by other views? There's no point trying to make the admin
> all things to all people - that would just complicate it so much as to
> make it unusable by anyone other than a guru.

I'm not writing this SessionWizard thing specifically for the admin,
though I wouldn't necessarily rule it out.  The point of it is to walk
ordinary, non-DB savvy, users through the creation of multiple
entities without these users having to know specifically the
relationships between entities (a programmer worries about that).  For
instance, creating a complete questionaire with the current admin
would involve, creating a questionaire, then creating questions and
answers and associating the questions with the questionaire and the
answers with the questions (basically select the same things
repeatedly from drop-downs).  This is resolved if you allow arbitrary
nesting of inlines and know how to map the relationships without the
user having to repeated select the same things from drop-downs, but it
could lead to one really long form.  Taking a multiple forms/requests
approach allows people to 1- pick up where they left off (say a
machine crashes or they just want save and pick up where they left off
and 2- quickly navigate to specific parts of the workflow in order to
add, change or remove or whatever.

I'm still a django newb, though, so please correct me if I stated
anything incorrectly.

Thanks,
Dave

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



  1   2   >