Toon posts:

Email.pl website email probleem !!

Pagina: 1
Acties:
  • 35 views sinds 30-01-2008

Verwijderd

Topicstarter
ik probeer via onder staand code een email te verzenden via website.
maar als ik op de verstuur knop druk krijg ik een Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.


code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
<TABLE width="100%" border=0>
                      <TBODY>
                        <TR> 
                          <TD align=middle width="92%"> <TABLE width="100%" border=0>
                              <TBODY>
                                <TR> 
                                  <TD class=titre_paragraphe bgColor=#000066><FONT 
                  color=#ffffff><B><A name=identite></A></B><B>Uw identiteit </B></FONT></TD>
                                </TR>
                              </TBODY>
                            </TABLE>
                            <TABLE borderColor=#6699CC cellSpacing=0 width="100%" border=1>
                              <TBODY>
                                <TR> 
                                  <TD>Aanspreekvorm</TD>
                                  <TD><SELECT size=1 name=akcivilite>
                                      <option value="M" selected>Meneer</option>
                                      <option value="MME">Mevrouw</option>
                                    </SELECT> &nbsp;</TD>
                                </TR>
                                <TR> 
                                  <TD>Naam*</TD>
                                  <TD><INPUT size=29 name=aanom></TD>
                                </TR>
                                <TR> 
                                  <TD>Voornaam*</TD>
                                  <TD><INPUT size=29 name=abprenom></TD>
                                </TR>
                                <TR> 
                                  <TD>Adres*</TD>
                                  <TD><INPUT size=29 name=acadresse1> <BR>
                                    <INPUT size=29 
                  name=acadresse2></TD>
                                </TR>
                                <TR> 
                                  <TD>Postcode* </TD>
                                  <TD><INPUT size=7 name=aecodepostal></TD>
                                </TR>
                                <TR> 
                                  <TD>Stad*</TD>
                                  <TD><INPUT size=29 name=afville></TD>
                                </TR>
                                <TR> 
                                  <TD> Land </TD>
                                  <TD><INPUT size=29 name=agpays></TD>
                                </TR>
                                <TR> 
                                  <TD>Telefoon*</TD>
                                  <TD><INPUT size=15 name=ahtelephone></TD>
                                </TR>
                                <TR> 
                                  <TD>Fax </TD>
                                  <TD><INPUT size=15 name=aitelecopie></TD>
                                </TR>
                                <TR> 
                                  <TD>E-Mail</TD>
                                  <TD><INPUT size=42 name=ajemail></TD>
                                </TR>
                                <TR> 
                                  <TD> Taal (voor email)</TD>
                                  <TD><SELECT size=1 name=allangue>
                                      <option value="Nederlands">Nederlands</option>
                                    </SELECT></TD>
                                </TR>
                              </TBODY>
                            </TABLE>
                            <TABLE borderColor=#6699CC cellSpacing=0 width="100%" border=1>
                              <TBODY>
                                <TR> 
                                  <TD width="38%"> <P> Opmerking </P></TD>
                                  <TD width="62%"> <DIV align=center>
                                      <TEXTAREA name=amremarque rows=5 cols=40></TEXTAREA>
                                    </DIV></TD>
                                </TR>
                              </TBODY>
                            </TABLE>
                            <FORM ACTION="cgi-bin/email.pl"
                              <INPUT TYPE="hidden" NAME=".email_target" VALUE="michael_s97@ChateaudeBarbencon">
                              <INPUT type=hidden 
      value=camping name=_controle_form>
                              <INPUT type=hidden value=1 
      name=_environment>
                              <INPUT type=hidden value=1 name=_remove_indexing>
                              <INPUT type=hidden value=demandeinfounicamp name=_mail_subject>
                              <INPUT 
      type=hidden value="Tet Mess" name=_mail_intro>
                              <CENTER>
                                <INPUT type=submit value="Versturen" name=_BtEnvoie>
                                &nbsp;&nbsp;&nbsp;
                                <INPUT type=reset value="Wissen" name=_BtEfface>
                              </CENTER>
                            </form></TR>
                      </TBODY>
                    </TABLE>



zie E-Mail.pl code wat die ik verkeerd ???

code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
!/usr/bin/perl -w

use CGI qw(:standard); 
use Net::SMTP; 

# Address to say this E-mail is from 
my $address = 'mysite@chateaudebarbencon.com'; 

# Our E-mail server 
my $server = 'mail.chateaudebarbencon.com'; 

# If we have an address that means we need to send 
# the E-mail, otherwise we need to prompt the 
# user for an E-mail address to send this note 
# to as well as some other information
if( param('address') ) { 

    my $to_address = param('address'); 
    my $from_address = param('from_address') || $address; 
    my $from_name = param('name'); 
    my $subject = param('subject'); 
    my $comment = param('comment'); 
    my $page = param('url'); 

    my $smtp = Net::SMTP->new($server) or 
        die "Error making connection to $server: $!\n"; 

    # Address this E-mail is from 
    $smtp->mail($from_address); 

    # Address this E-mail it to 
    $smtp->to($to_address); 

    # Start sending this message
    $smtp->data(); 

    $smtp->datasend("From: $from_address\n"); 
    $smtp->datasend("To: $to_address\n"); 
    $smtp->datasend("Subject: $subject\n"); 
    $smtp->datasend("\n"); 

    $smtp->datasend(" $from_name has suggested that you visit:\n\n"); 
    $smtp->datasend(" $page\n\n"); 

    $smtp->datasend(" Here is what they had to say about this");
    $smtp->datasend(" page:\n\n $comment\n\n");
    
    $smtp->dataend(); 
    $smtp->quit; 

    print   header; 

    print   start_html(-bgcolor=>'white'), 
            h1("Your recommendation has been sent to $to_address"), 
            end_html; 

}
else { 

    # Display our form for the user to give us some 
    # information to send in our E-mail message 
    print   header; 

    print   start_html(-bgcolor=>'white'),
            h1('Recommend this page to a friend'), 
            start_form, 
            hidden('url', $ENV{HTTP_REFERER}), 
            h3("Recipient's Information"), 
            b('E-mail Address:'), 
            br, 
            textfield(-name=>'address'), 
            br, 
            h3('Your information'), 
            b('Name:'), 
            br, 
            textfield(-name=>'name'),
            br, 
            b('E-mail address:'), 
            br, 
            textfield(-name=>'from_address'), 
            br,
            b('Subject:'), 
            br, 
            textfield(-name=>'subject'), 
            br,
            b('Comments to include in this E-mail:'),
            br, 
            textarea(   -name=>'comment', 
                        -rows=>8, 
                        -columns=>40, 
                        -wrap=>'virtual'),
            br,
            br,
            submit(-name=>'Send Recommendation'); 

    print   end_form, 
            end_html;   
}

  • ralfbosz
  • Registratie: December 2000
  • Laatst online: 16-04 22:04

ralfbosz

xm create bosz -c

* Mag je webserver wel executables uitvoeren in deze directory? (ExecCGI)

* Is je script wel executable? (chmod +x)

* Kan je webserver user het bestand wel uitvoeren?

More info...

rm -r *


Verwijderd

Topicstarter
ralfbosz schreef op vrijdag 02 december 2005 @ 18:14:
* Mag je webserver wel executables uitvoeren in deze directory? (ExecCGI)

* Is je script wel executable? (chmod +x)

* Kan je webserver user het bestand wel uitvoeren?

More info...
Provider is www.deheeg.nl

Op vraag

1 hoe kan ik dat zien in me instellingen

2 Ja

3 ja

[ Voor 4% gewijzigd door Verwijderd op 02-12-2005 18:29 ]


  • Salandur
  • Registratie: Mei 2003
  • Laatst online: 16:06

Salandur

Software Engineer

zet als tweede regel in je Email.pl:
Perl:
1
open (STDERR, "> Email.err.txt");

Als je geluk hebt en de fout ergens na dit commando optreedt dan zie je dat in het opgegeven bestand.

Assumptions are the mother of all fuck ups | iRacing Profiel


  • Klaus_1250
  • Registratie: December 2000
  • Laatst online: 21:10
Dat script is nou niet echt bepaald veilig te noemen. Ik neem aan dat je weet dat er redelijk veel pogingen op internet worden ondernomen om dit soort scripts te misbruiken????

Verwijderd

Topicstarter
Salandur schreef op vrijdag 02 december 2005 @ 22:18:
zet als tweede regel in je Email.pl:
Perl:
1
open (STDERR, "> Email.err.txt");

Als je geluk hebt en de fout ergens na dit commando optreedt dan zie je dat in het opgegeven bestand.
heb het gedaan maar zie helemaal niks ??

  • XangadiX
  • Registratie: Oktober 2000
  • Laatst online: 25-03 10:55

XangadiX

trepanatie is zóó kinderachtig

Hmja, het is niet de bedoeling dat je zulke lange lappen code post, daarbij geef je nergens aan wat je zelf al geprobeerd hebt om het probleem op te lossen. Lees de FAQ even door voor je dingen post :)

Stoer; Marduq

Pagina: 1

Dit topic is gesloten.