Hello,

Being having trouble with linestring().
I am posting values like this: (a,b), (c,d) so the format is
acceptable.
When i try:

*
polycoords = request.POST['polygcoords']
poly = LineString(polycoords )
insert_info = polylines(geometry = poly)
*
i get "Invalid initialization input for LineStrings error" or
"dimension errors".
i have also tried other stuff such as,

*
poly = LineString('%s' % polycoords)
poly = LineString('%s' % str(polycoords))
poly = GEOSGeometry(LineString()) # with the above combinations
poly = LineString(array([coordsa]))
poly = LineString([polycoords]) # and all the possible formats the
geodjango documentation suggest:
*

http://geodjango.org/docs/geos.html?highlight=linestring

My guess is that there is sth wrong with 'polycoords' value. Is there
any advice on this matter?
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-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
-~----------~----~----~----~------~----~------~--~---

Reply via email to