Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: fs_ftp_connection_types

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
1666       * @since 4.6.0 The `$context` parameter default changed from `false` to an empty string.
1667       *
1668       * @param array  $types       Types of connections.
1669       * @param array  $credentials Credentials to connect with.
1670       * @param string $type        Chosen filesystem method.
1671       * @param object $error       Error object.
1672       * @param string $context     Full path to the directory that is tested
1673       *                            for being writable.
1674       */
1675      $types = apply_filters( 'fs_ftp_connection_types', $types, $credentials, $type, $error, $context );
1677 ?>
1678 <form action="<?php echo esc_url( $form_post ) ?>" method="post">
1679 <div id="request-filesystem-credentials-form" class="request-filesystem-credentials-form">
1680 <?php
1681 // Print a H1 heading in the FTP credentials modal dialog, default is a H2.
1682 $heading_tag = 'h2';
1683 if ( 'plugins.php' === $pagenow || 'plugin-install.php' === $pagenow ) {
1684      $heading_tag = 'h1';