w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Changing header "From: noreply@domain.com" to other value, sends mail into spam folder
You must to add a needle headers: Sample code : $headers = "From: myplace@example.com "; $headers .= "Reply-To: myplace2@example.com "; $headers .= "Return-Path: myplace@example.com "; $headers .= "CC: sombodyelse@example.com "; $headers .= "BCC: hidden@example.com "; if ( mail($to,$subject,$message,$headers) ) { echo "The email has been sent!"; } else { echo "The email has failed!"; } ?> And I would suggest to read oswalds's

Categories : PHP

Emails not arriving on dovecot/postfix (debian)
Can you please post the output of /var/log/mail.log ? Because as far as i think the mail.log would contain something like "could not connect to /var/run/dovecot/auth-master: permission denied". If this is the case then all you have to do is change the permissions of /var/run/dovecot/auth-master so that vmail user can access it. But there's a catch to it. Whenever dovecot is restarted the permissions are reverted. You will have to give them again or you can write a script that does that for you every time dovecot or system is restarted. If this is not the case then post the log here for more clarification.

Categories : Misc

Linux postfix/dovecot 554 Relay access denied
If you use a postfix version newer then 2.10, then you need to add the smtpd_relay_restrictions option as described here: # With Postfix 2.10 and later, the mail relay policy is # preferably specified under smtpd_relay_restrictions. /etc/postfix/main.cf: smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated reject_unauth_destination # Older configurations combine relay control and spam control under # smtpd_recipient_restrictions. To use this example with Postfix ≥ # 2.10 specify "smtpd_relay_restrictions=". /etc/postfix/main.cf: smtpd_recipient_restrictions = permit_mynetworks permit_sasl_authenticated reject_unauth_destination ...other rules... After that, any sasl authenticated user should be able to send mails through the

Categories : Linux

AE.net.Mail, How to move mail to a new folder in outlook
to move a message to another folder do this: ic.MoveMessage(message.Uid, "some existing folder"); The uid is the unique identifiier for the mailmessage. I assume it maps to the message-id as described in RFC for Internet Message Format. Or otherwise to the UNIQUEID in the IMAP protocol. to create a new folder use the this method: ic.CreateMailbox("new mailbox name"); To send emails use an SmtpClient, like the one that is supplied in the .net framework: using(SmtpClient client = new SmtpClient("your smtp server.com")) { client.Send("from@example.com", "to@example.com", "subject", "Hello World"); }

Categories : Email

Outgoing Listing-Mail stucks in Spam-Filter since I moved to a new Server
First, check that your outgoing mail server is identifying itself correctly in the HELO command (or EHLO command) when it connects to a receiving mail server. There should also be an A record for this name that should point to the IP address of the mail server. Also, this IP address should reverse to some name (possibly, but not necessarily, the same name as above), and this name should point to the mail server's IP. If any of this is not right, then most spam filters will not consider your server to be a 'real' mail server, and will most likely flag any message sent from your server as spam. This is how many spam filters block spam that originates from computers that have been taken over as 'zombies'. Another thing to do is to check that you mail server IP is not on any blacklists. Yo

Categories : Email

Email with attachments going to Spam folder - VPS Server
EDIT #2: (PDF attachment) You will need to enter your $_POST variables, but if you try this as is, including the PDF file you wish to send, will run on its own. Change all instances of file.pdf in the code to the file name you wish to attach, as well as your Email address. (TESTED) <?php $sendto = "email@example.com"; $message = "Message here Hello, this is a test!!"; $filename = "file.pdf"; $handle = fopen($filename, 'rb'); $contents = fread($handle,filesize($filename)); fclose($handle); $encoded = chunk_split(base64_encode($contents)); $seperator = md5(uniqid(time())); $from = '"First Last" <username@domain.com>'; $header = ''; $header .= "From: $from "; $header .= "MIME-Version: 1.0 Content-Type:"." multipart/mixed; boundary="$seperator"; "; $body.= "--$seperator ";

Categories : PHP

postfix; pipe mail content to script for all mail of specific subdomain
It seems i solved the mystery problem. When i create an alias myself from test@example.com to test@vacation.example.com, the script gets called. mail.log Jul 12 15:20:55 mail postfix/pipe[14843]: 8854BB80B07: to=<test@vacation.example.com>, relay=vacation, delay=0.19, delays=0.07/0/0/0.12, dsn=2.0.0, status=sent (delivered via vacation service) vacation.pl logfile: 2013/07/12 15:21:27 DEBUG> /var/spool/vacation/vacation.pl:550 main:: - Script argument SMTP recipient is : 'test@vacation.example.com' and smtp_sender : 'peter@example.org' 2013/07/12 15:21:27 DEBUG> /var/spool/vacation/vacation.pl:580 main:: - Converted autoreply mailbox back to normal style - from test@vacation.example.com to test 2013/07/12 15:21:27 DEBUG> /var/spool/vacation/vacation.pl:590 main:: - Emai

Categories : Misc

postfix forward all mail to an external mail address
Finally found the answer. Listing here for posterity. Add the folowing line to the end of your main.cf file vi /etc/postfix/main.cf virtual_maps = hash:/etc/postfix/virtual, regexp:/etc/postfix/virtual-regexp Create a file which lists the mail address you want all mails to be sent to vi /etc/postfix/virtual-regexp Add the following: /.+@.+/ forwardingmailaddress@gmail.com add it to postmap postmap /etc/postfix/virtual-regexp you will need to add a virtual file. touch /etc/postfix/virtual now add it to postmap postmap /etc/postfix/virtual

Categories : Ubuntu

Send mail using php and postfix
PHP runs on the server. onClick executes Javascript on the CLIENT machine. You can NOT directly invoke PHP functions via Javascript code, or vice versa. What you're doing can be accomplished with a simple form: <?php if ($_SERVER["REQUEST_METHOD"] == 'POST') { $to = $_POST['to']; $text = $_POST['text']; mail($to, .....); } ?> <form method="POST" action=""> <input type="text" name="to" /> <input type="text" name="text" /> <input type="submit" /> </form> There is no need to use Javascript at all.

Categories : PHP

Postfix sending mail from nonexistent email addresses
The reject_unlisted_sender restriction listed in smtpd_sender_restrictions is listed after permit_mynetworks and permit_sasl_authenticated. Postfix traverses the restriction list in order and terminates when it hits the first permit/reject and hence never reaches reject_unlisted_sender. Since your message wasn't rejected by reject_unauth_destination it must've been accepted because of permit_mynetworks or permit_sasl_authenticated. Additionally, unless the sender address you used had a domain part that was actually "owned" by Postfix (i.e. listed in mydestination, virtual_mailbox_domains, virtual_alias_domains, or relay_domains), it can't be validated and reject_unlisted_sender won't work. See details in the postconf(5) man page. Other observations: The warn_if_reject restriction is pl

Categories : Mysql

Email sent from VPS going into spam folder or being blocked
One reason why your messages may be going to the SPAM folder is the lack of a positive reputation. Look at it from Gmail's perspective... about 80% of new sources of email are spewing malicious messages. Often times Gmail and other mailbox providers look upon new sources of email as guilty until proven innocent. ReturnPath, a email reputation company shows your IP as not having sent very much mail. https://senderscore.org/lookup.php?lookup= By sending good mail to people who want to receive your messages your mail will begin to more often land in the inbox. Your only other options are to play around with your content. Try using different local address portions, domains, subjects, and content. If you include URLs like bit.ly which is a domain commonly abused you could

Categories : Email

unable to semd 1000 mail from cakephp to centos(postfix/covedot)
I'd say this is probably due to the php script taking too long to execute. One solution is to send the emails using BCC but this isn't always an option if you are trying to track emails. You might try sending using a less memory intensive way. What is your current Configemail.php

Categories : Cakephp

Moving files from one folder to a hot folder BUT only move one at a time when the hot folder is empty
Pretty sure this should do what you want in vbscript: Set objFS = CreateObject("Scripting.FileSystemObject") set objFolderA = objFS.GetFolder("c:Folder A") set objFolderB = objFS.GetFolder("c:Folder B") For each objFile in objFolderA.Files Do While True If objFolderB.Files.Count = 0 Then objFS.MoveFile objFile.Path, ojbFolderB.Path & "" Exit Do End If Loop Next

Categories : Batch File

Move Redirected User Documents to a new folder location at a different folder level
According to your description this should work: $csv = 'C:scriptsusernames.csv' $log = 'C:scriptsHomeDir_robocopy.log' Import-Csv $csv | % { $_.username } | % { $src = "\server1Users$_" $dst = "\server2Users$_My Documents" robocopy "$src" "$dst" /e /copyall /r:1 /w:5 /log+:"$log" }

Categories : Powershell

Rename files recursively by adding them the folder's name and move them into another folder
This is a little bit tricky on windows ;) But you can do it the following way: create 2 batch files outside the folder which should be "scanned" first one should be named findfiles.bat forfiles /p %1 /s /c "cmd /c if @isdir==FALSE %~p0 enameit.bat @relpath @file %1 %~p0" the second one should be named renameit.bat @echo off set oldname=%1 set oldname=%oldname:.=% set oldname=%oldname:"=% set tmpname=%2 set newname=%oldname:=_% set newname=%newname:"=% move "%4%3\%oldname%" "%4%3\%newname%" now you can execute the findfiles.bat with the main folder as parameter. (so in your example : Pictures) So for example if your Pictures folder resides in D: then create the 2 batch files in D: then go to cmd and execute findfiles.bat Pictures But be careful! Try to execute this on a copy of y

Categories : Windows

How to configure PHP to send e-mail?
You need to have a smtp service setup in your local machine in order to send emails. There are many available freely just search on google. If you own a server or VPS upload the script and it will work fine.

Categories : PHP

Move all files and Subdirectories from a folder to another Subdirectory of the same folder
This is gonna be very simple. Directory.Move("SourcePath", "DestinationPath"); Process all directories in the source folder and use the above syntax for each and every folder using forloop or foreach to move to your destination folder.

Categories : C#

Warning: mail(): SMTP server response: 550 This is a submission only port. You must authenticate before sending mail in
php.ini & SMTP= - how do you pass username & password PHP mail() command does not support authentication. Your options: ...

Categories : Email

Configure NSSplitView with three subviews like mail.app
I found a solution without using auto layout constraints. I'm working with Rubymotion so my solution is in Ruby but it can be easily translated in Objective-C. First of all, to get only left and right subviews changing their size when the user drags the divider between the left and the middle subviews, I created two nested NSSplitView, the second one into the right part of the first one. The last point mentionned in the question, that is to say when the user drags the divider between the middle and the right subviews only these subviews change size is the default behavior of an NSSplitView so nothing to do here. Finally, to get only rightmost subview changing its size when the user resizes the window, I implemented the splitView:resizeSubviewsWithOldSize: delegate method: def splitView

Categories : Osx

Switched exchange servers, kept the same e-mail but some incoming mail is still going to the old server
I'm assuming that you changed the MX records for your domain, so that they now point to Microsoft 365's mail servers, correct? If so, it may take a day or two for the DNS changes to propagate.

Categories : Email

AJAX chat - Prevent spam server sided?
In the part of your scripts, where the server is about to save the chat message, you hook up a database query like SELECT COUNT(*) FROM chat_messages WHERE uid='1234' AND timestamp > DATE_SUB(NOW(), INTERVAL 10 SECOND) LIMIT 10 then check if the result is greater than your limit and return false, or a message "too many messages sent in too short time" Another, maybe better approach would be to identify not only a user/session, but also save the IP and limit messages to an IP. Many modern bots can easily circumvent sessions or switch IP very fast, so you should go for a combination of more than one technics. Also consider client side prevention, like hashing the message, or adding a checksum to the messages. Many bots don't talk JavaScript too good.

Categories : PHP

how to move a photo from a folder on sd card to another folder?
Try this: File file1 = new File("mnt/sdcard/kaic1/imagem.jpg"); File file2 = new File("mnt/sdcard/Kaic2/imagem.jpg"); file1.renameTo(file2); Here's more info on the renameTo function: http://developer.android.com/reference/java/io/File.html#renameTo(java.io.File) Edit: also check Osmium USA's answer regarding hard-coding the "mnt/sdcard/" folder path in your code.

Categories : Android

Unable to get emails sent by PHP mail function because of another mail server
The first thing to establish is how you are sending emails (sendmail or SMTP). Then, whether your emails are a) not sent at all or b) getting rejected by the destination mail server. I'd check all available logs (source and destination mail servers and daemons). See if mail() itself is erroring. Try using sendmail/smtp directly. If its the destination server rejecting the mail based on its spam score, try setting SPF records to enable the web server to send mail legally.

Categories : PHP

Configure Spring mail sender dynamically
Spring EMail function is just a thin wrapper around java's standard mail function (javax.mail) https://javamail.java.net/nonav/docs/api/. You do not need to use the spring mail function if you do not want, you can use java.mail directly. There it should be relative easily to use different configuration for every mail.

Categories : Database

MySQL Query to Bulk Delete Spam Wordpress Users
You can use a INNER JOIN when using DELETE in MySQL. DELETE FROM wp_users INNER JOIN wp_usermeta ON wp_users.ID = wp_usermeta.user_id WHERE wp_users.user_email LIKE "%@hotmail%" AND [etc, etc.] This solution gives you two (or maybe more ;-)) problems: 1) you can't reassign posts and links (if you want) and 2) you have to deal with JSON values in MySQL. A better way is to use WordPress functions for the job. You can use get_users to search for users and wp_delete_user to delete the user. <?php $args = array( 'blog_id' => $GLOBALS['blog_id'], 'role' => 'subscriber', 'search' => '*@hotmail.com' ); $blogusers = get_users($args); foreach ($blogusers as $user) { wp_delete_user( $user->ID, $reassign ); } ?> Please read

Categories : Mysql

How to configure Magento to send mail in Godaddy shared host?
To solve this configured the sender mail in: System > Configuration > Contacts > Email Options Just change the hello@example.com to your email. And use the first configuration explained in the question: Choose extension option: SMTP Authentication: Login Username: mymail... Pass: mypass... Server: smtpout.secureserver.net Port: 80 SSL Security: No SSL Hope it help someone too.

Categories : Magento

php restart process in the background spamassassin
Try using nohup. http://en.wikipedia.org/wiki/Nohup <?php // Note the backticks! `nohup service spamassassin restart &` ?> Also, make sure the user running apache has enough permissions to restart this service.

Categories : PHP

Move mail runtime error
Test that each object is a mailitem, because if not they might not have ReceivedTime or Flagstatus. Try something like: If TypeOf objItem Is MailItem Then If objItem.ReceivedTime < Now - 50 And objItem.FlagStatus = 1 Then ...

Categories : Vba

How to move large amounts of mail with PHP?
Perhaps there are only 25,112 messages in the mailbox, and the other ~50,000 are in another mailbox. I know GMail, for example, may report a rough total for the Inbox, but a good percentage of those messages are actually archived. You might want to do a sanity check at this point. :)

Categories : PHP

Spamassassin false negative for message from text
I wrote a response (below) not having noted how you started this question. The "I'm downloading my twitter feed and saving them into text files" piece is key. Very key. Specifically, SpamAssassin is designed to scan email, complete with rich metadata from the headers. Twitter feeds do not have headers. The best spam-fighting techniques I've seen for twitter, which are mostly academic research rather than usable code, involve intense link graphs that track followers and build reputations for each user. This is pretty much the only metadata available in twitter, so SpamAssassin has nothing to go on but the tweet ("body") content itself. Sure, the Bayesian mechanism can conceivably help, though again it is composed with headers and email-specific tokenization techniques. So too can th

Categories : Perl

How to configure config.php in include folder
Your question seeming to be a bit out of context - what exactly are you using the $config array for? What application are you trying to install? Either way, the basedir variable you have sounds like a UNIX based XAMPP one, it should probably be something like "C:xampphtdocs" on your windows installation. As for the baseurl, try maybe adding "http://" before it.

Categories : PHP

How to create list of Mail messages to move together rather than moving them individually
Try using a filter reference form like this: set d to (current date) - 14 * days tell application "Mail" repeat with a in (get accounts where enabled is true) move (messages of mailbox "INBOX" of account a where date sent < d and (sender ends with "<events@goldstar.com>" or sender ends with "<hello@touchofmodern.com>")) to mailbox "Old_Newsletters" of account "BlueStar Studios" end repeat end tell

Categories : Osx

Configure a sitecore role to access the system folder
First off, make sure the user has the Entire Tree and Hidden Items options ticked in the View tab. Also, to check if it's access rights you can use the Access Viewer to see whether the user has access rights. If they don't you can click on the Read right (for instance) and see why they don't have access to the System node (for example, which role Denies the read access). For more information, please check the Security Reference document on SDN.

Categories : Security

How to configure Durandal.js to have multiple areas with views and viewmodels in same folder?
You can have any folder structure your heart desires. Durandal does not impose any folder structure on your application but it does have a default convention which is completely overridable. If you are using Durandals router then you will want to look into how to configure it to find modules. There are many ways of doing this, I prefer to create my own convention by overriding the router.autoConvertRouteToModuleId. If you are not using the router plugin then you will have to manage the uris for your modules yourself and this is done by following requirejs' convention and using this convention along w/ durandals composition module. Also, you can override how it finds the views to bind to your modules by overriding the viewlocators convention. Durandal provides an very simplistic way

Categories : Misc

How to monitor specific folder and save content of each log file in that folder to mysql database
First of all, congratulations! You are in front of a beautiful problem. My suggestion is to use divide and conquer. Here are my considerations: Put the relevant folder(s) under version control (for example, GIT) Check via GIT commands the files that changed every X amount of time. Also obtain the differences between the prior version of each file, and the new ones, so you can update your database parsing the new info. Just in case, here are ways to call system commands from ruby. Hope that helps,

Categories : Mysql

Rails server command generates another folder in project's folder with default folders and files
This is because you are using rails 2 gem version, you can check by rails -v. As well you can see, there is no app/assets folder. there are only public/javascripts etc rails2 style directories Try to install rails 3 by gem install rails --version '>3.0.0'

Categories : Ruby On Rails

Get latest unread mail from specific folder using outlook
I managed to got it work by doing this way: Dim app As Microsoft.Office.Interop.Outlook.Application = Nothing Dim ns As Microsoft.Office.Interop.Outlook._NameSpace = Nothing Dim inboxFolder As Microsoft.Office.Interop.Outlook.MAPIFolder = Nothing Dim subFolder As Microsoft.Office.Interop.Outlook.MAPIFolder = Nothing Dim destinationDirectory As String = Directory.GetCurrentDirectory & "Output" If Not Directory.Exists(destinationDirectory) Then Directory.CreateDirectory(destinationDirectory) End If Try app = New Microsoft.Office.Interop.Outlook.Application() ns = app.GetNamespace("MAPI") ns.Logon(Nothing, Nothing, False, False) inboxFolder = ns.GetDefaultFolder(Microsoft.Office.Interop.Outlook.OlDefaultFolders.olFolderInbox)

Categories : Vb.Net

What is the point of adding "IP domain.tld" to the ( /etc/hosts ) file if the server is not gonna be used as a mail server?
/etc/hosts file is an alternative to DNS host name resolution. It has nothing specifically to do with mail servers. But, to use a mail server it has to be found on the network. /etc/hosts is a local lookup file that computer uses as specified in /etc/nsswitch.conf. DNS is a network service provided for each domain. For example, BIND. Domain zone files are configured and hosted on the domains primary DNS servers. You can configure domain searches in /etc/resolv.conf.

Categories : Linux

configure nginx to get js and css directly from public folder of node.js express site
A 403 forbidden response may be related to the nginx process don't having permission to read the files. Check that the folder public is recursively readable by the user running nginx and change the permissions if needed: sudo chmod -R 744 /root/pathToNodeJsExpressSiteFolder/public

Categories : Node Js

How can I configure TortoiseSVN to not show .class, .log and folder list when creating an svn patch
If you are on Windows you can do the following: Just rightclick any *.class or *.log file in the repofolder, go to the tab TortiseSVN-> Add to Ignorelist-> *.log/*.class. If you sue the commandline tool. You had to configure a svn:ign propperty.

Categories : Svn

© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.