WebProWorld Part of WebProNews.com
Page One Link To Us Edit Profile Private Messages Archives FAQ RSS Feeds  
 

Go Back   WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum
Subscribe to the Newsletter FREE!


Register FAQ Members List Calendar Arcade Chatbox Mark Forums Read

Web Programming Discussion Forum Working with an API? Developing a plugin? Writing a Mod or script for your favorite blog, Web 2.0 site or Forum? Welcome.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-27-2004, 01:39 PM
WebProWorld New Member
 

Join Date: Jan 2004
Location: USA
Posts: 2
djfox RepRank 0
Default E-Mail Forms

I`ve got a working e-mail form going where users can edit pictures they have already sent to the site. I currently use a free e-mail form service for them to send in pictures BUT it has a limitation, the users cna only fill out that form 10 times!

So I wanted to make a picture submission form myself but am having toruble getting the bloody thing to send me the picture. The code currently:

<FORM NAME=Tools3 ACTION="mailto:DJFox@comcast.net?subject=Upload Image" METHOD="post" ENCTYPE="text/plain">
<INPUT NAME=" " TYPE=TEXT VALUE="Your Name" SIZE="" MAXLENGTH="50">


E-mail Address to contact you by:

<INPUT NAME="E-mail" TYPE=TEXT VALUE="" SIZE="">


Picture:

<INPUT NAME="filename" SIZE=50 TYPE=FILE>



<INPUT NAME="Submit" TYPE=SUBMIT VALUE="Submit"><INPUT NAME="Cancel" TYPE=RESET VALUE="Cancel"></FORM>

All I get is either an e-mail message that says "filename=C:\A_Website\New\load\thumbnail_211. jpg" instead of an attached picture or an e-mail with an attachment POSTDATA.ATT that is totally unreadable.

Anyone how to fix this problem & make it so it send the picture as attachment along with the field info properly?
Reply With Quote
  #2 (permalink)  
Old 02-02-2004, 02:35 AM
southplatte's Avatar
WebProWorld Veteran
 

Join Date: Jul 2003
Location: Colorado
Posts: 380
southplatte RepRank 1
Default

I will try to help a little bit:

The first line catches my attention -- ENCTYPE="text/plain" yet the pictures will not be text, they will be a different mime type (jpg, gif etc).

When the form gets submitted, I would take a gander that the postdata.att is the picture converted to text which is unreadable.

You can try to take the ENCTYPE out or maybe specify more than one type and test it.

As far as getting the form to set the picture as an attachement, I am not aware of a way for a mailto for to perform this (anyone else know for sure?). You may need to look at a server side scripting language to help out with the form to accomplish this.
Reply With Quote
  #3 (permalink)  
Old 02-02-2004, 02:39 AM
WebProWorld New Member
 

Join Date: Jan 2004
Location: USA
Posts: 2
djfox RepRank 0
Default

With the SSS script you mentioned, are you referring to the file being saved as a shtml? I do have the file saved as shtml.

I`ll try your suggestion with the enctype & see how that goes. :)
Reply With Quote
  #4 (permalink)  
Old 02-02-2004, 03:13 AM
southplatte's Avatar
WebProWorld Veteran
 

Join Date: Jul 2003
Location: Colorado
Posts: 380
southplatte RepRank 1
Default

Right, the page itself is saved as a .shtml for the SSI that you use in the form, however I was thinking along the lines of a PHP or ASP script or possibly even javascript.

PHP has a built in mail() function that might be able to handle attachments - I can look into it if you want. I am sure ASP has something similar as well. JavaScript may be the better one because your host needs to be able to support the PHP/ASP languages and JavaScript is more client side.

PHP also can use the include() function to get the same results as the SSI include you are using.
Reply With Quote
Reply

  WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum
Tags: ,



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Search Engine Optimization by vBSEO 3.2.0