I have mail() function that sends email and seems to me the problem is not in the mail headers but stil I got 2 positions in the mail SPAM assignation that makes some email providers to classify my emails as spam. This is : 0.0 URIBL_BLOCKED          ADMINISTRATOR NOTICE: The query to URIBL was                          blocked.  See                          http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block                           for more information.                          [URIs: shoppingbulgaria.com]   0.8 BAYES_50               BODY: Bayes spam probability is 40 to 60%                          [score: 0.5000]  -0.0 SPF_PASS               SPF: sender matches SPF record  -0.0 SPF_HELO_PASS          SPF: HELO matches SPF record   0.1 MIME_HTML_ONLY         BODY: Message only has text/html MIME parts   0.0 HTML_FONT_LOW_CONTRAST BODY: HTML font color similar or                          identical to background   0.0 HTML_MESSAGE           BODY: HTML included in message   0.0 HTML_IMAGE_ONLY_32     BODY: HTML: images with 2800-3200 bytes of                          words   0.1 DKIM_SIGNED            Message has a DKIM or DK signature, not necessarily                          valid  -0.1 DKIM_VALID_EF          Message has a valid DKIM or DK signature from                          envelope-from domain  -0.1 DKIM_VALID_AU          Message has a valid DKIM or DK signature from                          author's domain  -0.1 DKIM_VALID             Message has at least one valid DKIM or DK signature   2.5 PHP_SCRIPT             Sent by PHP script   2.2 HAS_X_OUTGOING_SPAM_STAT Has header claiming outbound spam scan                          - why trust the results?  As you can see last 2 positions make the difference of being marked as SPAM or not: 2.5 PHP_SCRIPT             Sent by PHP script 2.2 HAS_X_OUTGOING_SPAM_STAT  Unfortunately I could not find any information and explanation for this: 2.5 PHP_SCRIPT             Sent by PHP script  Why the fact its been sent by php script could be a reason for being marked as SPAM? And what this means: 2.2 HAS_X_OUTGOING_SPAM_STAT Has header claiming outbound spam scan                      - why trust the results?  $headers =''; if(isset($p['from_name'])) $headers .= &quot;From: &quot;.official_site_name.&quot; &lt;&quot;.$p['from_email'].&quot;&gt;\r\n&quot;; if(isset($p['from_email'])) $headers .= &quot;Reply-To: &quot;.official_site_name.&quot; &lt;&quot;.strip_tags($p['from_email']).&quot;&gt;\r\n&quot;; else $headers .= &quot;Reply-To: &quot;.official_site_name.&quot; &lt;&quot;.official_mail_sender.&quot;&gt;\r\n&quot;; $headers .= &quot;Return-Path: &lt;&quot;.official_mail_sender.&quot;&gt;\r\n&quot;; if(!empty($p['cc'])) $headers .= &quot;CC: &lt;&quot;.strip_tags($p['cc']).&quot;&gt;\r\n&quot;; if(!empty($p['bcc'])) $headers .= &quot;BCC: &lt;&quot;.strip_tags($p['bcc']).&quot;&gt;\r\n&quot;; $headers .= &quot;Content-Type: text/html; charset=UTF-8\r\n&quot;; $headers .= &quot;Content-Transfer-Encoding: 8bit\r\n&quot;; $headers .= &quot;X-Mailer: PHP/&quot;. phpversion() .&quot;\r\n&quot; ; $headers .= &quot;MIME-Version: 1.0\r\n&quot;; $random_hash = md5(date('r')); $body='&lt;html&gt; &lt;head&gt; &lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=UTF-8&quot;/&gt; &lt;title&gt;'.$p['subject'].'&lt;/title&gt; &lt;/head&gt; &lt;body bgcolor=&quot;White&quot;&gt;Body text&lt;/body&gt;&lt;/html&gt;';  mail(&quot;&lt;&quot;.$p['to'].&quot;&gt;&quot;, '=?utf-8?B?'.base64_encode(strip_tags($p['subject'])).'?=', $body, $headers, &quot;-f &quot;.official_mail_sender.&quot;&quot;);  The body has normal registration welcome text.. Thanks for any help
This is a tricky one and I've always relied on techniques, such as permission-based emails (i.e. only sending to people you have permission to send to) and not using blatantly spamish terminology.  Of late, some of the emails I send out programmatically have started being shuffled into people's spam folder automatically and I'm wondering what I can do about it.  This is despite the fact that these particular emails are not ones that humans would mark as spam, specifically, they are emails that contain license keys that people have paid good money for, so I don't think they're going to consider them spam  I figure this is a big topic in which I am essentially an ignorant simpleton.
How to show that for all k, $k! \ge (k/2)^{k/2}$ Variable wavelength IR Diode? I was thinking of building a DIY IR Spectroscope but for this, I need to find an IR diode that can do variable wavelengths. So far I have looked at Farnell and Mouser but all the diodes I have looked at seem to be fixed on a wavelength.   Is this possible? or would I need some sort of filters and optical equipment, if so which parts would I need?  Thanks. Passing data between view controllers How does negation affect the use and understanding of "or" and "and" I'm trying to make more sense of how negation effects how a sentence is parsed and understood if and's and or's are used within them.  Pop quiz: You are trapped on a bus with a bomb going 50 MPH. You have a radio... (okay enough Keanu Reeves references) :-)  Let's say the bomb expert says "Don't cut the red or green wires." I think that means "Do not cut the wires colored red. Do not cut the wires colored green."  Now, let's say the bomb expert said on the radio "Do not cut the red and green wires", instead. Do I take that to mean:     "Do not cut the wires colored red. Do not cut the wires colored green."   OR     "Do not cut the wires whose insulation has red and green stripes." ?   OR     "It's okay to cut the wires colored red or the wires colored green, as long I don't cut one of each color."   Which meaning should I take if the radio breaks and I can't ask follow up questions? Proving bessel identity $[J_0(x)]^2 + 2[J_1(x)]^2 + 2[J_2(x)]^2 + \cdots = 1$ and $|J_0(x)|\le 1$ The generating function for a Bessel equation is:      $$g(x,t) = e^{(x/2)(t-1/t))}$$      Using the product $g(x,t)\cdot g(x,-t)$ show that:      a) $$[J_0(x)]^2 + 2[J_1(x)]^2 + 2[J_2(x)]^2 + \cdots = 1$$      and consequently:      b)      $$|J_0(x)|\le 1, \forall x$$      c) $$|J_n(x)| \le \frac{1}{\sqrt{2}}; n=1,2,3,\cdots$$   For a) I tried the product:  $$e^{(x/2)(t-1/t))}\cdot e^{(x/2)(-t+1/t))} = 1$$  I at least arrived at the right side of the equation. Since this generates the bessel functions, I should arrive at something related to $J_n$ in the left side. I know that  $$e^{(x/2)(t-1/t))} = \sum_{n=0\infty}^{\infty} J_n(x)t^n$$  $$e^{(x/2)(-t+1/t))} = \sum_{n=0\infty}^{\infty} J_n(x)(-t)^n$$  but it's not just a matter of multiplying coefficients from the two infinite series, right?  For $b$, I tried to use  but it's not as obvious  I have no idea how to deal with $c$, could somebody help me? How to center an element horizontally and vertically Best way to hide a window from the Alt-Tab program switcher? I've been a .NET developer for several years now and this is still one of those things I don't know how to do properly. It's easy to hide a window from the taskbar via a property in both Windows Forms and WPF, but as far as I can tell, this doesn't guarantee (or necessarily even affect) it being hidden from the Alt+↹Tab dialog. I've seen invisible windows show up in Alt+↹Tab, and I'm just wondering what is the best way to guarantee a window will never appear (visible or not) in the Alt+↹Tab dialog.  Update: Please see my posted solution below. I'm not allowed to mark my own answers as the solution, but so far it's the only one that works.  Update 2: There's now a proper solution by Franci Penov that looks pretty good, but haven't tried it out myself. Involves some Win32, but avoids the lame creation of off-screen windows. My script (should) acts differently, depending on the presence of the data in the input stream. So I can invoke it like this:  $ my-script.sh   or:  $ my-script.sh &lt;&lt;-MARK     Data comes...     ...data goes. MARK   or:  $ some-command | my-script.sh   where two last cases should read the data, while first case should notice the data is missing and act accordingly.  The crucial part (excerpt) of the script is:  #!/bin/bash local myData; read -d '' -t 0 myData;  [ -z "${myData}" ] &amp;&amp; {     # Notice the lack of the data. } || {     # Process the data. }   I use read to read input data, then option -d '' to read multiple lines, as this is expected, and the -t 0 to set timeout to zero. Why the timeout? According to  (typing left unchanged; bold is mine):     -t timeout time out and return failure if a complete line of input is               not read withint TIMEOUT seconds.  The value of the TMOUT               variable is the default timeout.  TIMEOUT may be a               fractional number.  If TIMEOUT is 0, read returns success only               if input is available on the specified file descriptor.  The               exit status is greater than 128 if the timeout is exceeded   So I in case 2 and 3 it should read the data immediately, as I understand it. Unfortunately it doesn't. As -t can take fractional values (according to above man page), changing read line to:  read -d '' -t 0.01 myData;   actually reads the data when data is present and skips it (after 10ms timeout) if it is not. But it should also work when TIMEOUT is set to real 0.  Why it actually doesn't? How can this be fixed? And is there, perhaps, alternative solution to the problem of "act differently depending on the presence of the data"?  UPDATE  Thanks to @Isaac I found a misleading discrepancy between quoted on-line version and my local one (normally I do not have locale set to en_US, so help read gave me translation which I couldn't paste here, and looking up for on-line translation was faster than setting new env---but that caused the whole problem).  So for 4.4.12 version of Bash it says:     If TIMEOUT is 0, read returns               immediately, without trying to read any data, returning               success only if input is available on the specified               file descriptor.   This gives a little bit different impression than "If TIMEOUT is 0, read returns success only if input is available on the specified file descriptor"---for me it implied actually an attempt to read the data.  So finally I tested this and it worked perfectly:  read -t 0 &amp;&amp; read -d '' myData;   The meaning: see if there's anything to read and if it succeed, just read it.  So as to base question, the correct answer was provided by Isaac. And as to alternative solution I prefer the above "read &amp;&amp; read" method. Should I follow what was mentioned in the “duration of stay” or in the "validity of the visa"? I'm from Tunisia and I got a Schengen visa from the Austrian Embassy for  28 days, the “duration of stay”, and the number of entries is 1. But the validity of the visa is from 02/08/2015 to 13/09/2015.  Do I have to stay only 28 days, for example from 02/08/2015 to 29/08/2015 or can I stay there until 12/09/2015 ?  And if I have got to stay only 28 days, then can I choose the days of stay, that's mean can I stay in Austria for example from 09/08/2015 to 05/09/2015? How do I install Skype? Mutineers force captain to record instructions to spaceship's computer but he leaves out "please" The crew mutinies on a spaceship whose captain controls it with verbal orders. They test whether they can control the ship with recordings of the captain's voice with an order to increase orbital speed (currently orbiting a planet). It works, so they force the captain to record all the possible orders they may need, and execute him. Only then do they realize that the ship obeys only orders couched in polite language, and only the test recording was like this, but the other recordings are not. They will die once the ship's faster orbit somehow causes it to run out of fuel, or something like that. I seem to remember the ship's &quot;computer&quot; following the captain around on robotic legs. I read the story circa 1980, but it might have been published much earlier. Israel visa stamp issue I am an Indian national living in London. I need to travel to Israel for work. I will need to apply for a visa but I have been told that it will be stamped in my passport. I have read that Israel knows of the problems travellers face in other Arab countries so they issue a paper visa but the embassy in London told me that it will be stamped in. I travel often in Middle East for work and I do not want any issues in the future. Please advise.  Thanks. Shorter proof for some equvalences Let $(G,\cdot)$ be a group show that  A) $G$ is abelian  B) For all $x,y\in G: (xy)^{-1}=x^{-1}y^{-1}$  C) For all $x,y\in G: (xy)^{2}=x^{2}y^{2}$  D) There existst an $n\in \mathbb{Z}$ such that for all $x,y\in G$  $\displaystyle (xy)^{n-1}=x^{n-1}y^{n-1}$ and $\displaystyle (xy)^{n}=x^{n}y^{n}$ and $\displaystyle (xy)^{n+1}=x^{n+1}y^{n+1}$  are equivalent.    I showed $A\iff B,A\iff C$ and $A\iff D$. That was not really hard, except maybe $D\Rightarrow A$. I would like to do a circular argument, but i have no idea how.  Any hints?  Thanks in advance! I can't seem to get Python to import a module in a subfolder. I get the error when I try to create an instance of the class from the imported module, but the import itself succeeds. Here is my directory structure:  Server     -server.py     -Models         --user.py   Here's the contents of server.py:  from sys import path from os import getcwd path.append(getcwd() + "\\models") #Yes, i'm on windows print path import user  u=user.User() #error on this line   And user.py:  class User(Entity):     using_options(tablename='users')      username = Field(String(15))     password = Field(String(64))     email    = Field(String(50))     status   = Field(Integer)     created  = Field(DateTime)   The error is: AttributeError: 'module' object has no attribute 'User' I think the single dashes (hyphens) should be placed between the numbers and units in this sentence:     ...in a cylinder of 3-inch radius and 24-inch length.   Is that correct and should hyphens be added to this second sentence?     ...making a trench nearly 15 feet wide and more than 30 feet long. "When people do make changes" - which tense is this? Which tense are sentences like:   "When people do make changes good things happen" "Even if monkeys can play an important role, their actions can pose risk to the general public" Can I deploy Juju on Eucalyptus? Please let me know if I can deploy juju on Eucalyptus, if yes please provide me the configuration details which i need to edit on environments.yaml file. Evaluating $\prod_{n=1}^{\infty}\left(1+\frac{1}{2^n}\right)$ Proving identities (mod $pq$) using Fermat's little theorem? How do you join on the same table, twice, in mysql? I have 2 tables. One (domains) has domain ids, and domain names (dom_id, dom_url).  the other contains actual data, 2 of which columns require a TO and FROM domain names. So I have 2 columns rev_dom_from and rev_dom_for, both of which store the domain name id, from the domains table.  Simple.  Now I need to actually display both domain names on the webpage. I know how to display one or the other, via the LEFT JOIN domains ON reviews.rev_dom_for = domains.dom_url query, and then you echo out the dom_url, which would echo out the domain name in the rev_dom_for column.  But how would I make it echo out the 2nd domain name, in the dom_rev_from column?