Hi guys. Im doing a simple CGI form to send data by email. They are for
some technicians on field so they can send daily reports about what
they made. The thing is, i dont know how to send images attached to the
email i generate with sendmail. I put the combos in the form, but i
dont know how to sa
You are the man!
--
http://mail.python.org/mailman/listinfo/python-list
Hey. I looked at the Sendmail help and did not find a property where i
can get an "ok" signal when the email is finally sent. I need something
like that to show a "Processing, please stand by" screen when the
server is sending an email, and when the email is out, another screen
appears with an "Ema
Can you help me a little bit more? Please check this out:
102 part.addheader('Content-Transfer-Encoding', 'base64')
103 body = part.startbody('image/jpeg; name=c:\check.jpg')
104 base64.encode(open('check.jpg', 'rb'), body)
105
106
base64 = ,
base64.encode = , builtin open = , body =
Check this piece of code:
#now add an image part
part = writer.nextpart()
part.addheader('Content-Transfer-Encoding', 'base64')
body = part.startbody('image/jpeg')
base64.encode(open('c:\check.jpg', 'rb'), body)
I get the following error:
IOError: [Errno 2] No such file or di
OSError: [Errno 2] No such file or directory: 'c:/'
args = (2, 'No such file or directory')
errno = 2
filename = 'c:/'
strerror = 'No such file or directory'
Crazy... and if i use c:\, i get a 500 error.
--
http://mail.python.org/mailman/listinfo/python-list
Im running it in my test site at F2o.org. Perhaps its server's fault
and not script's fault. I'll deal this issue at its forums.
:)
--
http://mail.python.org/mailman/listinfo/python-list
Aye, but the file is in MY drive, not the server. Perhaps thats the
issue? I bet it's so... how should i deal with it? Perhaps should be a
script that uploads the files to the server and then emails it... i
believed this was handled using the root in my PC, but now i see this
is not correct.
Now
@ Steven: LOL =P
@ Frederik: aye, i uploaded the script by FTP, but the idea of this
little program is to allow a technician on field to upload photos from
their laptops when they get into a hotel, along with some text, anywere
in the world. We need the reports to be daily. Email is not an option,
(the Input type = FILE is in the field)
please check this out
import ftplib
import os
...
def upload(ftp, file):
ext = os.path.splitext(file)[1]
if ext in (".txt", ".htm", ".html"):
ftp.storlines("STOR " + file, open(file))
else:
ftp.storbinar
Aye, but i dont need to run an FTP daemon every time i want to upload
an image to Imageshack or any other website.
About the topic name, yes, it's meaningless and its a shame. I fucked
it up when typing the title =P
--
http://mail.python.org/mailman/listinfo/python-list
Yeah, i did. Thank you, im analyzing the examples found. I'll post my
results :)
--
http://mail.python.org/mailman/listinfo/python-list
bambooforest ha escrito:
> Hi all,
>
> I'm from a Linguistics background and am new(er) to programming. Could
> someone recommend a book or resource that teaches programming aspects
> with Python? Python I hear is a very appropriate language for handling
> text and language processing.
>
> I'm se
Hi guys. I'm doing a simple strategy game in python, hex based, with
the PIL library. I'd like to know if there is a way to check the
pointer position within a frame, so i can figure out which hex is the
pointer on, but in a pythonesque way, not using Java or Flash. Sajax is
the way to go? I dont t
Michael Tobis ha escrito:
> www.pygame.org
>
> Yes but he obviously wants this to be delivered to the browser. (Also
> the site is broken today... )
>
> This comes up a lot, but I don't think there's an answer to it as yet.
>
> mt
Yeah, i want it playable on a browser.
--
http://mail.python.o
Yeah, probably i'll be ending doing the front end in Flash and the back
end in Python.
--
http://mail.python.org/mailman/listinfo/python-list
OP?
--
http://mail.python.org/mailman/listinfo/python-list
:)
Right now im trying to dl Jython (SF.net server down?), if it's
language sintaxis is just like Python and allows to use numpy and PIL,
im in! (i think :) )
--
http://mail.python.org/mailman/listinfo/python-list
Hi guys. I've been lookig for this in the numpy pdf manual, in this
group and on google, but i could not get an answer...
Is there a way to create a custom data type (eg: Name: string(30), Age:
int(2), married: boolean, etc) and then use that custom data in a
matrix? Actually, this is a two questi
BTW, i tried the "classe Thinge(): pass" but does not qualify as "data
type" for a numpy array.
--
http://mail.python.org/mailman/listinfo/python-list
And how im supposed to assign data to a specific hex?
--
http://mail.python.org/mailman/listinfo/python-list
Hi guys. I installed XAMPP, an easy to set up Apache, Mysql and PHP
server. But im trying to get Python work on it so i can test my
scripts. The addon for XAMPP is only for Linux, i wonder if you can
help me out in installing Python + PIL support.
Any tutorial or something? I searched here and in
22 matches
Mail list logo