Tokyoj

Topic: How to stop Admin emails?

I want to prevent the site from sending the "Activate" / "Deactivate" emails when an Employer registers, and jobs are posted and such. I'm working on an Employer's Control Panel where they can control the job's status. This would eliminate the need for those emails.

I tried simply hiding the code in the .js with /* xxxxx */ but that generates errors.

Any ideas of how to do this?
Cheers,

---------------
Tokyoj
"You can't build a reputation on what you're going to do." (Henry Ford)
"Insanity is doing the same thing over and over, expecting different results." (Albert Einstein)

mployr.com

Re: How to stop Admin emails?

Adding return 1; in line 1032 of includes/class.Job.php bypasses the verification process: Perhaps, start looking here...I'll keep poking around and see where to disable this.

eg:

    // Check if the poster of this post has posted before with this e-mail address
    public function CheckPosterEmail()
    {
        return 1; // <---- bypassing verification
        global $db;
        $sql = 'SELECT poster_email FROM jobs
                          WHERE poster_email = "' . strtolower($this->mPosterEmail) . '" AND id <> ' . $this->mId . ' AND is_temp = 0
                                AND (is_active = 1 OR (is_active = 0 AND DATEDIFF(NOW(), created_on) > 30))';
        $result = $db->query($sql);
        $row = $result->fetch_assoc();
        if (!empty($row['poster_email']))
        {

Entrepreneur? Check this out...
http://www.eugeneg.com/overview/

Tokyoj

Re: How to stop Admin emails?

Tried that but it's not really what I'm working towards.
The file class.Postman.php controls system emails and there are 3 email that I want to prevent from going out...

// Send mail to user when a post is activated (after first-time post)
public function MailPostActivatedToUser($data)
    {

// Send mail to user when posting first time (thus the post needs to be moderated)
public function MailPublishPendingToUser($poster_email, $data)
    {

// Send mail to user when a post is published
public function MailPublishToUser($data)
    {

I tried using 'hide' tags /* xxx */ but that just causes errors (I'm really good at 'creating' errors....avoiding them is a challenge)

Any ideas anyone?
Thanks.

---------------
Tokyoj
"You can't build a reputation on what you're going to do." (Henry Ford)
"Insanity is doing the same thing over and over, expecting different results." (Albert Einstein)

filipcte

Re: How to stop Admin emails?

In page_publish.php:
- comment line 12 ($nicu->MailPublishToUser($job->GetInfo())wink
- comment line 19 ($nicu->MailPublishPendingToUser($job->mPosterEmail)wink

That should do it!

Original jobberBase author
www.filipcte.com

Tokyoj

Re: How to stop Admin emails?

That's works beautifully.
Thanks.

---------------
Tokyoj
"You can't build a reputation on what you're going to do." (Henry Ford)
"Insanity is doing the same thing over and over, expecting different results." (Albert Einstein)