add_uploaded_file( $tag->name, $new_files ); } $result = apply_filters( "wpcf7_validate_{$tag->type}", $result, $tag, array( 'uploaded_files' => $new_files, ) ); } $this->invalid_fields = $result->get_invalid_fields(); return $result->is_valid(); } /** * Adds extra email attachment files that are independent from form fields. * * @param string|array $file_path A file path or an array of file paths. * @param string $template Optional. The name of the template to which * the files are attached. * @return bool True if it succeeds to attach a file at least, * or false otherwise. */ public function add_extra_attachments( $file_path, $template = 'mail' ) { if ( ! did_action( 'wpcf7_before_send_mail' ) ) { return false; } $extra_attachments = array(); foreach ( (array) $file_path as $path ) { $path = path_join( WP_CONTENT_DIR, $path ); if ( file_exists( $path ) ) { $extra_attachments[] = $path; } } if ( empty( $extra_attachments ) ) { return false; } if ( ! isset( $this->extra_attachments[$template] ) ) { $this->extra_attachments[$template] = array(); } $this->extra_attachments[$template] = array_merge( $this->extra_attachments[$template], $extra_attachments ); return true; } /** * Returns extra email attachment files. * * @param string $template An email template name. * @return array Array of file paths. */ public function extra_attachments( $template ) { if ( isset( $this->extra_attachments[$template] ) ) { return (array) $this->extra_attachments[$template]; } return array(); } } Affiliated Learning
Skip to content
Affiliated Learning

Affiliated Learning

  • Home
  • Contact Us

Blogs

What to Consider Before Choosing an Online Degree

By adminPosted on September 6, 2018August 24, 2022

For some campus students, selecting a university is as easy as calculating Ucas points. However, things are difficult for distance students. Studying off-campus requires a […]

What to Consider Before Choosing an Online Degree Read More

DOs and DON’Ts for Adults Relating to Younger Students

By adminPosted on August 7, 2018August 24, 2022

A mature student who attends school alongside other learners in their early twenties and late teens might feel a bit “different.” So, how should you […]

DOs and DON’Ts for Adults Relating to Younger Students Read More

Six Ways to Stay Motivated When Studying Online

By adminPosted on July 25, 2018August 24, 2022

When taking online classes, you have to be motivated if you want to be successful. Considering that you are juggling a lot of things at […]

Six Ways to Stay Motivated When Studying Online Read More

Benefits of Life Experience to Adult Education

By adminPosted on July 7, 2018August 24, 2022

Adult education comes in various forms, such as college degrees, high school diplomas and cooking classes. It refers to any education undertaken by an adult […]

Benefits of Life Experience to Adult Education Read More

Subscribe now to get the latest tips education to help you accelerate your future!




  • What to Consider Before Choosing an Online Degree
    For some campus students, selecting a university is as easy as calculating Ucas points. However, things are difficult for distance students. Studying off-campus requires a […]
  • DOs and DON’Ts for Adults Relating to Younger Students
    A mature student who attends school alongside other learners in their early twenties and late teens might feel a bit “different.” So, how should you […]
  • Six Ways to Stay Motivated When Studying Online
    When taking online classes, you have to be motivated if you want to be successful. Considering that you are juggling a lot of things at […]
  • Benefits of Life Experience to Adult Education
    Adult education comes in various forms, such as college degrees, high school diplomas and cooking classes. It refers to any education undertaken by an adult […]
© Affiliated Learning
Privacy Policy | Terms and Conditions | Disclaimer | Manage Your Subscription