Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG, Page 212 of 796  Not logged in ELOG logo
ID Date Icon Author Author Email Category OS ELOG Version Subjectup
  1906   Sat Aug 19 18:45:22 2006 Reply Stefan Rittstefan.ritt@psi.chQuestionWindows Re: Conditional E-Mail Attributes

Grant Jeffcote wrote:

Stefan Ritt wrote:
If I try that little configuration file:
[global]
port = 8080
password file = passwd
smtp host = your.smpt.host

[demo]
Theme = default
Comment = General linux tips & tricks
Attributes = Author, Type, Category, Subject, Email Type
Options Type = Routine, Software Installation, Problem Fixed, Configuration, Other
Options Category = General, Hardware, Software, Network, Other
Options Email Type = plain{1}, html{2}

{1}Email encoding = 1
{2}Email encoding = 2

then the email encoding changes from plain to HTML depending on the conditional attribute Email Type. Maybe you misunderstood the concept of conditional attributes. In the above config the attribute Email Type determines the condition {1} or {2}, which leads then to different values of the email encoding. But it's important to have the line
Options Email Type = plain{1}, html{2}

in order to set a condition.


I use conditional attributes to select the fields I would like displayed on a form or page.
I understand how they work but wish to set the Email Encoding automatically depending on which item they choose from a drop down list (ie. which form they are using)

For example, if they choose 'Fred Bloggs' from the conditional drop down attribute 'Name' it will set the page so that only 'Fred Bloggs' required attributes are viewable. I wish to send this page in Plain text when submitted.

If 'Fred Jones' is chosen then only attributes applicable to 'Fred Jones' are shown. When he submits his entry then I need the email to be sent in HTML.

The email encoding option would have to be set under either Fred Bloggs{1} or Fred Jones{2} conditions.

Attributes = Name,

Options Name = Fred Bloggs{1}, Fred Jones{2}

{1}Email encoding = 1
{1}Email All = sed@frd.fg
{2}Email encoding = 2
{2}Email All = sdf@fgd.hg

I can get options like 'Email All = sed@frd.fg' to change to another email address when used as above but not Email formatting.

I have all the other conditional attributes working fine otherwise but would really like to be able to add this option.

Thanks for your help.


Can you please try the above configuration example, and can you please tell me exactly which version of elog you are using? If I try that example with ELOG V2.6.2-1714, it works fine (it DOES change the email encoding).
  1907   Sat Aug 19 20:12:42 2006 Reply Grant Jeffcotegrant@jeffcote.orgQuestionWindows Re: Conditional E-Mail Attributes

Stefan Ritt wrote:

Grant Jeffcote wrote:

Stefan Ritt wrote:
If I try that little configuration file:
[global]
port = 8080
password file = passwd
smtp host = your.smpt.host

[demo]
Theme = default
Comment = General linux tips & tricks
Attributes = Author, Type, Category, Subject, Email Type
Options Type = Routine, Software Installation, Problem Fixed, Configuration, Other
Options Category = General, Hardware, Software, Network, Other
Options Email Type = plain{1}, html{2}

{1}Email encoding = 1
{2}Email encoding = 2

then the email encoding changes from plain to HTML depending on the conditional attribute Email Type. Maybe you misunderstood the concept of conditional attributes. In the above config the attribute Email Type determines the condition {1} or {2}, which leads then to different values of the email encoding. But it's important to have the line
Options Email Type = plain{1}, html{2}

in order to set a condition.


I use conditional attributes to select the fields I would like displayed on a form or page.
I understand how they work but wish to set the Email Encoding automatically depending on which item they choose from a drop down list (ie. which form they are using)

For example, if they choose 'Fred Bloggs' from the conditional drop down attribute 'Name' it will set the page so that only 'Fred Bloggs' required attributes are viewable. I wish to send this page in Plain text when submitted.

If 'Fred Jones' is chosen then only attributes applicable to 'Fred Jones' are shown. When he submits his entry then I need the email to be sent in HTML.

The email encoding option would have to be set under either Fred Bloggs{1} or Fred Jones{2} conditions.

Attributes = Name,

Options Name = Fred Bloggs{1}, Fred Jones{2}

{1}Email encoding = 1
{1}Email All = sed@frd.fg
{2}Email encoding = 2
{2}Email All = sdf@fgd.hg

I can get options like 'Email All = sed@frd.fg' to change to another email address when used as above but not Email formatting.

I have all the other conditional attributes working fine otherwise but would really like to be able to add this option.

Thanks for your help.


Can you please try the above configuration example, and can you please tell me exactly which version of elog you are using? If I try that example with ELOG V2.6.2-1714, it works fine (it DOES change the email encoding).


My version shows V2.6.2-1699.
I noticed you have 1714, is that the latest binary or your compiled CVS release?

Thx
  1962   Tue Oct 10 08:52:50 2006 Reply Stefan Rittstefan.ritt@psi.chQuestionWindows Re: Conditional E-Mail Attributes

Grant Jeffcote wrote:
My version shows V2.6.2-1699.
I noticed you have 1714, is that the latest binary or your compiled CVS release?


Try this one: http://midas/elog/download/windows/elog262-3.exe which is the most recent.
  2035   Thu Nov 2 23:16:11 2006 Reply Steve Jonessteve.jones@freescale.comQuestionWindows2.6.2.1723Re: Conditional Email Notification by a text file

An Thai wrote:
Hello,

I try to email by using a email text file to reduce the admin work.
  • MOptions Team = EUROPE, ASIA, AFRICA, AMERICA
  • Email Team EUROPE = $shell(type C:\EuropeEmailList.txt)

but i get always Email sent to Shell execution not enabled via -x flag

Is this feature not supported by ELOG or did i use the wrong syntax?

Thank you in advance.




Quote:
You need to start elogd with the "-x" flag
  2037   Fri Nov 3 01:03:33 2006 Reply An Thaithaithan@gmx.deQuestionWindows2.6.2.1723Re: Conditional Email Notification by a text file

Steve Jones wrote:

An Thai wrote:
Hello,

I try to email by using a email text file to reduce the admin work.
  • MOptions Team = EUROPE, ASIA, AFRICA, AMERICA
  • Email Team EUROPE = $shell(type C:\EuropeEmailList.txt)

but i get always Email sent to Shell execution not enabled via -x flag

Is this feature not supported by ELOG or did i use the wrong syntax?

Thank you in advance.




Quote:
You need to start elogd with the "-x" flag


Yes, i did it. But the problem is still there.
I exactly tried 50 times by submit a new entry and got only 3 times passed. 47 another cases i got:
"Error sending Email via "192.168.2.20": 5.5.2 Need Rcpt command".
I run elogd -v and see:
"Email Team EUROPE to Shell execution not enable via -x flag"
  2038   Fri Nov 3 03:42:18 2006 Reply Steve Jonessteve.jones@freescale.comQuestionWindows2.6.2.1723Re: Conditional Email Notification by a text file

An Thai wrote:

Steve Jones wrote:

An Thai wrote:
Hello,

I try to email by using a email text file to reduce the admin work.
  • MOptions Team = EUROPE, ASIA, AFRICA, AMERICA
  • Email Team EUROPE = $shell(type C:\EuropeEmailList.txt)

but i get always Email sent to Shell execution not enabled via -x flag

Is this feature not supported by ELOG or did i use the wrong syntax?

Thank you in advance.




Quote:
You need to start elogd with the "-x" flag


Yes, i did it. But the problem is still there.
I exactly tried 50 times by submit a new entry and got only 3 times passed. 47 another cases i got:
"Error sending Email via "192.168.2.20": 5.5.2 Need Rcpt command".
I run elogd -v and see:
"Email Team EUROPE to Shell execution not enable via -x flag"



Steve Jones wrote:

Well, it looks like you are getting the text "Shell execution not enable via -x flag" put into the EUROPE attribute then the email server is attempting to send email to the email address "Shell execution not enable via -x flag", which is clearly not a valid address thus the "Error sending Email via "192.168.2.20": 5.5.2 Need Rcpt command".

You need to run run "elogd -v -x" then look for the errors. You also might try a more simpler test like "Preset Team EUROPE = = $shell(type C:\EuropeEmailList.txt)" and then see what is returned. It makes it simpler and removes the email error from the equation.
  2055   Thu Nov 9 20:45:32 2006 Reply Stefan Rittstefan.ritt@psi.chQuestionWindows2.6.2.1723Re: Conditional Email Notification by a text file

Steve Jones wrote:

An Thai wrote:

Steve Jones wrote:

An Thai wrote:
Hello,

I try to email by using a email text file to reduce the admin work.
  • MOptions Team = EUROPE, ASIA, AFRICA, AMERICA
  • Email Team EUROPE = $shell(type C:\EuropeEmailList.txt)

but i get always Email sent to Shell execution not enabled via -x flag

Is this feature not supported by ELOG or did i use the wrong syntax?

Thank you in advance.




Quote:
You need to start elogd with the "-x" flag


Yes, i did it. But the problem is still there.
I exactly tried 50 times by submit a new entry and got only 3 times passed. 47 another cases i got:
"Error sending Email via "192.168.2.20": 5.5.2 Need Rcpt command".
I run elogd -v and see:
"Email Team EUROPE to Shell execution not enable via -x flag"



Steve Jones wrote:

Well, it looks like you are getting the text "Shell execution not enable via -x flag" put into the EUROPE attribute then the email server is attempting to send email to the email address "Shell execution not enable via -x flag", which is clearly not a valid address thus the "Error sending Email via "192.168.2.20": 5.5.2 Need Rcpt command".

You need to run run "elogd -v -x" then look for the errors. You also might try a more simpler test like "Preset Team EUROPE = = $shell(type C:\EuropeEmailList.txt)" and then see what is returned. It makes it simpler and removes the email error from the equation.


That's a very interesting idea of setting up mailing lists I never thought about. I tried myself and it works fine. Just as Steve says run "elogd -v -x" to see what happens. Also make sure that EuropeEmailList.txt contains only a single line with comma-separated email addresses, just as you would enter them in the config file.
  2065   Thu Nov 9 23:25:15 2006 Reply An Thaithaithan@gmx.deQuestionWindows2.6.2.1723Re: Conditional Email Notification by a text file

Stefan Ritt wrote:

Steve Jones wrote:

An Thai wrote:

Steve Jones wrote:

An Thai wrote:
Hello,

I try to email by using a email text file to reduce the admin work.
  • MOptions Team = EUROPE, ASIA, AFRICA, AMERICA
  • Email Team EUROPE = $shell(type C:\EuropeEmailList.txt)

but i get always Email sent to Shell execution not enabled via -x flag

Is this feature not supported by ELOG or did i use the wrong syntax?

Thank you in advance.




Quote:
You need to start elogd with the "-x" flag


Yes, i did it. But the problem is still there.
I exactly tried 50 times by submit a new entry and got only 3 times passed. 47 another cases i got:
"Error sending Email via "192.168.2.20": 5.5.2 Need Rcpt command".
I run elogd -v and see:
"Email Team EUROPE to Shell execution not enable via -x flag"



Steve Jones wrote:

Well, it looks like you are getting the text "Shell execution not enable via -x flag" put into the EUROPE attribute then the email server is attempting to send email to the email address "Shell execution not enable via -x flag", which is clearly not a valid address thus the "Error sending Email via "192.168.2.20": 5.5.2 Need Rcpt command".

You need to run run "elogd -v -x" then look for the errors. You also might try a more simpler test like "Preset Team EUROPE = = $shell(type C:\EuropeEmailList.txt)" and then see what is returned. It makes it simpler and removes the email error from the equation.


That's a very interesting idea of setting up mailing lists I never thought about. I tried myself and it works fine. Just as Steve says run "elogd -v -x" to see what happens. Also make sure that EuropeEmailList.txt contains only a single line with comma-separated email addresses, just as you would enter them in the config file.


I tested many times and find out the problem.
The first opening CMD and running "elogd -v -x". It works perfektly.
Close the CMD: It stops to work.
From this time point it never works again even I try to re-open CMD and run "elogd -v -x"
The computer must be rebooted to get it works. (The CMD for running elogd -x must be always opened !!!)
ELOG V3.1.5-fe60aaf