I am developing an e-commerce system. My e-commerce system is up in my hosting called zoom. I am done in the part of ordering and right now, I'm having difficulty in sending the email.   It is working but it goes in the spam folder instead of inbox.   NOTE: I already created an email account in my hosting zoom and I used it in my code(you can see below)  Question: I want to send the email without being labeled as spam. Is there something missing or wrong in my code? Please point me towards right direction.  Controller    public function process()     {                  $id = $this-&gt;session-&gt;userdata('id');         $where = array('id' =&gt; $id);         $get_orders  = $this-&gt;Crud_model-&gt;join_orders_customer('*','orders',$id);         $get_invoice = $this-&gt;Crud_model-&gt;get_invoice('*','orders',$id);          $email = $this-&gt;Crud_model-&gt;get_email($id);          $config = array(                     'smtp_timeout' =&gt; '4',                     'charset' =&gt; 'utf-8',                     'mailtype'=&gt; 'html'                     );                     $this-&gt;load-&gt;initialize($config);                     $fromemail="zeesdelivery@zessdelivery.com";                     $to = $email-&gt;email_address;                     $subject = "Your Order is not Processing";                     foreach($get_orders as $row){                      $mesg = "&lt;h1&gt;Schedule Accepted!!!&lt;/h1&gt;                               &lt;h3&gt;Thank you for trusting and using Exclure Pest Control. $row-&gt;product_name&lt;/h3&gt;                              &lt;h3&gt;Your reserve inspection is accepted. We sure to call you as soon as possible&lt;/h3&gt;                             &lt;p&gt;--------------------------------------------------------------------------------------&lt;/p&gt;                             &lt;h4&gt;For more details contact us at,&lt;/h4&gt;                             &lt;h4&gt;Exclure Pest Control&lt;/h4&gt;                                 &lt;h4&gt;Email : exclure@exclure.com.ph&lt;/h4&gt;                             &lt;h4&gt;Contact Number: 525-5399/ 498-1626 &lt;/h4&gt;                                           &lt;h4&gt;Facebook : https://web.facebook.com/ExclurePestControl/&lt;/h4&gt;";                     }                     $this-&gt;load-&gt;library('email');                     $this-&gt;email-&gt;clear();                     $this-&gt;email-&gt;from($fromemail, 'Zees Delivery');                     $this-&gt;email-&gt;to($to);                     $this-&gt;email-&gt;set_header('Header1', 'Value1');                     $this-&gt;email-&gt;set_newline("\n");                     $this-&gt;email-&gt;subject($subject);                     $this-&gt;email-&gt;message($mesg);                     $this-&gt;email-&gt;set_mailtype('html');                     $this-&gt;email-&gt;send();                     $this-&gt;cart-&gt;destroy();                     echo json_encode("success");             }
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.
Variance of sum of $k$ randomly drawn numbers from $1,...,n$. Google spreadsheet sorting messes up cell comments I'm running into this weird problem with Google spreadsheets: if the cells have comments on them and I sort the spreadsheet, the rows sort but the comments stay in the same position, and don't move with the cells they're attached to.  In other words, the cells look like this:  A C  &lt;-- comment on this cell B   and then I sort by this column:  A B  &lt;-- comment remains on this cell (stays in position) C  &lt;-- comment should have remained attached to this cell   This means that sorting is completely broken and I can't use it at all, because I clearly need the cell comments to stay with the cell they're attached to.  Is this a bad bug in Google Spreadsheets, or am I missing something here? Is there a way to find out if I need a transit visa for a layover in the UK? Is there a website or some other way to find out if I need a transit visa for a short stop in the UK on my way somewhere else? Ideally this should give me the answer for all nationalities, and take into account any other visas I may have. How may I reference the script tag that loaded the currently-executing script? How to read such figures with % as "up (by) 120%" and "increased (by) 120%". Do they mean the same? As a student, I make mistakes all the time, and stealing my idea will not face heavy retaliation. I don't mind if someone comes up with concurrent works, but I do mind if my key idea is leaked. Many graduate students in my field therefore only use pre-print services if their papers are either publicly presented or conditionally accepted. I am looking for a website that can do most of what ArXiv does, with an additional private option or limited visibility, for example an option to make the paper unindexed by search engines. This way, my paper cannot be seen for at least a few months. By doing so, I can at least claim that I am one of the first few researchers who got the idea right. And most importantly, I can privately correct my mistakes, if any. Publishing mistakes is embarrassing and sometimes harms one's career. Many mistakes will be revealed during the peer-review processes and I have a chance to correct them before publicizing. Please kindly think twice before giving ethically and &quot;politically correct&quot; comments like no one will scoop me, everyone will cite me, and the scoopers will be punished. At least in my field, scooping and idea-stealing is commonly observable, and big-names don't care about publicizing pre-prints because they have resources to punish the scoopers. I do understand that keeping my work private might harm the community as the information becomes less transparent. However, it could also be possible that my un-reviewed flawed works misguide the community, and a paper reviewed will benefit the society more. I personally wasted six months because of someone else's mistake in a published work.  I heard that in molecular biology there is a widely-used service to upload your research data, like protein structure and sequencing, to get a timestamp. The uploaded materials can be set to be private for a period, and fully disclosed later. A lot of people do use this function. This is not exactly what I am looking for but shares some similar ideas. If I remember correctly, there is an interesting paper studying the scooping patterns with the aid of this database.  Solutions found!  and some other university-run pre-print services do have an embargo function. Moreover,  is a widely used repository, that, unlike arxiv, only displays the newest version to the general public, although still keeps a tag on the first submitted date! Is Gauss's law wrong, or is it possible that $\int_s{\vec E} \cdot d\vec{s}=0$ does not imply $\vec E = 0$? This is a question from David J Griffith's Introduction to Electrodynamics.      A specified charge density $\sigma(\theta)=k\cos(\theta) $ is glued over the surface of a spherical shell of radius $R$. Find the resulting potential inside and outside the sphere.   The question was solved using legendre polynomials and the final answer for potential inside the sphere was : $V(r,\theta) = \frac{kr}{3\epsilon_0}cos\theta$  This final answer is confusing because The Electric field inside the sphere is coming out to be dependent on $r$ and $\theta$ whereas electric field inside a shell, no matter what the charge distribution is outside, is $zero$ from gauss's law.      my doubts:         why is the electric field inside non zero?    Can gauss's law explain this, or does it fail here?      Since solving using ordinary surface integral gave me the same result and since the. divergence inside the shell is $zero$, I concluded that legendre polynomials and gauss's law in differential form are correct. So the problem should be with the integral form of gauss's law : $\int_s{\vec E}.d\vec{s} = \frac{q}{\epsilon_0}$  The answer I got for this doubt is that  "since the charges are glued to the surface, and not evenly distributed, electric field inside need not be zero. "     This is not convincing because proof of gauss's law does not expect the charges to be free to move. presence of an exrernal force that would hold the charges in place does not change the theorem. That is    Say only a single charge $q_i$ is present outside      then $\int_s{\vec E_i}.d\vec{s} = \frac{q_{inside}}{\epsilon_0}=0$      Now if there are more charges, following any distribution, net electric field $\vec E = \vec E_1 + \vec E_2+\vec E_3+...$       So the net flux,       $\int_s{\vec E}.d\vec{s} = \int_s{\vec E_1}.d\vec{s}+\int_s{\vec E_2}.d\vec{s}+\int_s{\vec E_3}.d\vec{s}+. . .=0$   Or is it possible that $\int_s{\vec E}.d\vec{s}=0$ does not imply $\vec E = 0$? highest power of prime $p$ dividing $\binom{m+n}{n}$ Some issues with timezones in PHP have been in the back of my mind for a while now, and I was wondering if there are better ways to handle it than what I'm currently doing.  All of the issues revolve around reformating database stored dates:  When dealing with a site that has to support multiple timezones (for users), to normalize the timezone offest of stored timestamps I always store it with the server timezone using the CURRENT_TIMESTAMP attribute or the NOW() function.   This way I don't have to consider what timezone was set for PHP when the timestamp was entered (since PHP time functions are timezone aware). For each user, according to his preference I set the timezone somewhere in my bootstrap file using:  date_default_timezone_set($timezone);   When I'm looking to format dates with the php date() function, some form of conversion has to take place since MySQL currently stores timestamp in the format Y-m-d H:i:s. With no regard to timezone, you could simply run:  $date = date($format,strtotime($dbTimestamp));   The problem with this is that date() and strtotime() are both timezone aware functions, meaning that if the PHP timezone is set differently from the server timezone, the timezone offset will apply twice (instead of once as we would like).  To deal with this, I usually retrieve MySQL timestamps using the UNIX_TIMESTAMP() function which is not timezone aware, allowing my to apply date() directly on it - thereby applying the timezone offset only once.  I don't really like this 'hack' as I can no longer retrieve those columns as I normally would, or use * to fetch all columns (sometimes it simplifies queries greatly). Also, sometimes it's simply not an option to use UNIX_TIMESTAMP() (especially when using with open-source packages without much abstraction for query composition).  Another issue is when storing the timestamp, when usage of CURRENT_TIMESTAMP or NOW() is not an option - storing a PHP generated timestamp will store it with the timezone offset which I would like to avoid.  I'm probably missing something really basic here, but so far I haven't been able to come up with a generic solution to handle those issues so I'm forced to treat them case-by-case. Your thoughts are very welcome Showing that two definitions of $\limsup$ are equivalent What are the different colors on the unity launcher icons? Example:      My question is simple.  What are the different colors representing in the unity launcher background for each icon.  I mean, it seems consistent (firefox is always orange), but it's not jumping out at me what the pattern is.  On my screen, it's:   Firefox: Orange Chrome: Yellow Terminal: Grey RDP App: Blue KeyPassX: Green NetBeans: Blue   I'd like to turn it off if possible, but first I'd like to understand more about it.  Any launcher experts? Checking if file is checked out through CSOM Is there a way to check if a file is checked out by another user? I am going trhough a list file by file and would like to avoid the "file is opened by another user" error. Something like this would be nice:  Guid id = new Guid(slideLibrary); // ID of Slide-Library. List list = ctx.Web.Lists.GetById(id); ListItemCollection items = list.GetItems(CamlQuery.CreateAllItemsQuery()); ctx.Load(items); // Loading all the fields System.Security.SecureString pwd = new System.Security.SecureString(); foreach (char c in "pwd".ToCharArray()) pwd.AppendChar(c);  ctx.Credentials = new SharePointOnlineCredentials(login, pwd); ctx.ExecuteQuery();  // Iterating through all the entries. foreach (var item in items) {     String currentID = item["ID"].ToString(); // Getting the ID of the current item.      if (!item.IsCheckedOut()) // This is the part I am looking for.     {        // Do stuff     }     else     {        Console.WriteLine("Item is blocked, skipping it.")     } }   I have yet not been able to find something fitting. This is probably a silly question but I need some help. I opened a file that I've been working on for about a month in the new 2.8 version of Blender. However when I tried to reopen the file in version 2.79, the scene is completely empty. Here is where the problem lies for me, I accidentally saved over the original file save while in version 2.8 . Please help. Thanks! "Timed Out" error when trying to join server Apache error "Could not reliably determine the server's fully qualified domain name" When I restart my Apache server using the command  sudo /etc/init.d/apache2 restart   I get the following error:  Restarting web server apache2 apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName ... waiting apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName   Is the server using 127.0.1.1 instead of 127.0.0.1? What causes this error? Zero probability and impossibility I read a comment under :     There are plenty of events that can occur that have zero probability.   This reminds me that I have seen similar saying before elsewhere, and have never been able to make sense out of it. So I was wondering    if zero probability and impossibility mean the same? if an event with zero probability doesn't mean that the event is impossible to occur, how probability theory represents/describes impossibility?   Thanks and regards! Lost USB BlueTooth Dongle for Keyboard and Mouse I lost my USB bluetooth dongle (from HP) which I used for a wireless keyboard and mouse. They came together in a set when I bought my last HP computer.  Are the keyboard and mouse useless now? or will any bluetooth dongle allow them to work? If I can just buy a new one - any recommendations on a replacement (good price, and perhaps works with Windows and Ubuntu out-of-the-box?   Forgive me if this is an easy question. I'm just not that familiar with wireless mice/keyboards. How can I make a material only apply to a side of a plane? Limits of sequences of sets Possible Australianism - netbank = a website + app by which an Aussie can do their banking, including transferring money to other people.  A while ago, I ended up with $1000 transferred into my account, which in the description looked like a netbank transfer, not like a cheque, cash deposit etc, and which looked like it had already cleared and landed in my account. Usually when something is still working through the bank's system it displays as 'pending', but did not in this case.  I received a phone call from someone, saying that they had accidentally typed in the wrong account number, and wanting me to send them the same amount of money back via netbank.   Surely bank account numbers have a checksum, which make it relatively difficult for a typo to result in a payment going to the wrong person? What are likely sources of them being able to find my phone number to call me? Obviously, the bank either being hacked, or giving it out in response to a query from this person (but surely the bank is unlikely to tell me my own mobile number if I claim to have forgotten it?). Presumably either my phone, or the phone of someone I have sent money to/received money from could be compromised. Has anyone heard of any instances of this happening?  I then went to my bank, explained the situation and said that I did want to refund the money through the officially sanctioned methodology. After the laughter died down, the bank told me to ask the person to fill out a form, then they would get me to fill out a form that would authorize undoing that exact payment.  I rang up the person to tell them this, and over the course of about a week received an increasingly elaborate story about how that wasn't working, they needed the money immediately, there was a fee to fill out that form and they couldn't afford to pay it etc.  After that, I never heard back from them again. I check my netbank for several weeks after, expecting the money to magically disappear, but it did not. This was probably a year ago, and I'm pretty vague with money so may not have noticed if it disappeared more recently. How were they expecting to benefit?  Were they hoping to get the transfer from me, and undo the transfer to me, to leave them $1k up? If so, how can an internet banking transfer be 'undone' once it has already shown as 'received'. Or was this to do with money laundering? The account they requested me to send money to was the same as the one that the money appeared to come from. This was a scam, right?