Comprehensive List of WordPress Action Hooks Lista completa de la acción de WordPress Hooks

For WordPress Plugin and Theme Developers by Por plugin WordPress y el tema de los desarrolladores Plugin Developer Plugin para Desarrolladores

This contains all the available action hooks (documented as well as undocumented) for WordPress plugin and theme developers. Este contiene todos los ganchos de acción disponibles (documentados, así como indocumentados) para el plugin WordPress y el tema desarrolladores. All available documentation on these hooks have been updated from WordPress Codex. Todos los documentos disponibles en estos ganchos se han actualizado de WordPress Codex.

Source file and line number information is provided to allow you to find more details about the hook. El archivo de origen y número de línea se proporciona información que le permite encontrar más detalles sobre el gancho. Please maximize your browser for better display. Por favor, maximizar su navegador para una mejor visualización.

Note: You may also want to refer Nota: También puede hacer referencia WordPress 2.x Filters - Comprehensive List for Plugin and Theme Developers WordPress 2.x Filtros - Lista completa de Tema Plugin y Desarrolladores .

No. N º Action Acción Source File Origen del archivo Line
No. N º
Comments Comentarios
1 wp_logout wp-login.php wp-login.php 25 25
2 lost_password wp-login.php wp-login.php 38 38
3 retreive_password wp-login.php wp-login.php 100 100
4 retrieve_password wp-login.php wp-login.php 101 101
5 password_reset wp-login.php wp-login.php 137 137
6 wp_authenticate wp-login.php wp-login.php 189 189
7 wp_login wp-login.php wp-login.php 201 201
8 rss_head wp-rss.php WP-rss.php 22 22
9 rss_item wp-rss.php WP-rss.php 33 33
10 template_redirect wp-includes\template-loader.php wp-incluye \ plantilla-loader.php 3 3

No
parameter. parámetro. Executes before the determination of the template file to be used to display Ejecuta antes de la determinación de la plantilla que se utiliza para mostrar
the requested page. la página solicitada. Useful for providing additional templates based on request criteria. Útil para la presentación de más plantillas basadas en criterios de solicitud.
Example (pedagogical, not useful): Redirect all requests to the all.php template file Ejemplo (pedagógica, no es útil): Redireccionar todas las solicitudes para el archivo de plantilla all.php
in the current themes’ directory. en los temas actuales'.

function all_on_one () { all_on_one función () (
include(TEMPLATEPATH include (TEMPLATEPATH
. ‘/all.php’); '/ All.php');
exit;
} )
add_action(’template_redirect’, add_action ( 'template_redirect »,
‘all_on_one’); 'All_on_one');

11 wp_meta wp-includes\template-functions-general.php wp-incluye \ plantilla de funciones-general.php 59 59 No
parameter. parámetro. Executes in the Ejecuta en el
  • Meta
  • section of the included Theme’s la sección de Tema del incluido
    sidebar.php’s. sidebar.php 'S. Useful for insertion of additional content in meta section. Útil para la inserción de contenido adicional en la sección meta.

    12 mce_options wp-includes\js\tinymce\tiny_mce_gzip.php wp-incluye \ js \ TinyMCE \ tiny_mce_gzip.php 144 144
    13 tinymce_before_init wp-includes\js\tinymce\tiny_mce_gzip.php wp-incluye \ js \ TinyMCE \ tiny_mce_gzip.php 150 150
    14 profile_update wp-includes\registration-functions.php wp-incluye \ registro-functions.php 76 76
    15 user_register wp-includes\registration-functions.php wp-incluye \ registro-functions.php 78 78
    16 private_to_published wp-includes\functions-post.php wp-incluye \ funciones-post.php 175 175 Receives Recibe
    the post ID as a parameter. el puesto de identificación como un parámetro. Executes when a post is moved from private to published Ejecuta un puesto cuando se traslada de privado a publicado
    status. estatus.
    17 edit_post wp-includes\functions-post.php wp-incluye \ funciones-post.php 178 178 Receives Recibe
    the post ID as a parameter. el puesto de identificación como un parámetro. Executes every time a post is edited. Ejecuta cada vez que un puesto está editado.
    18 publish_post wp-includes\functions-post.php wp-incluye \ funciones-post.php 182 182 Receives Recibe
    the post ID as a parameter. el puesto de identificación como un parámetro. Executes when a post is saved and its status is set to Ejecuta un puesto cuando se guarda y su estado está ajustado a
    "publish", regardless of its prior setting. "publicar", independientemente de su consentimiento previo. NOTE: to add a hook to this NOTA: para añadir un gancho a esta
    action in 1.2, be sure to specify a priority between 0 and 9. acción en 1,2, asegúrese de especificar un orden de prelación entre 0 y 9. The generic_ping hook El gancho generic_ping
    is buggy and prevents any lesser priority hooks from working. está libre de errores, y que evite cualquier tipo de menor prioridad ganchos de trabajo.
    19 save_post wp-includes\functions-post.php wp-incluye \ funciones-post.php 206 206 Receives Recibe
    the post ID as a parameter. el puesto de identificación como un parámetro. Executes when a post is saved to the database. Ejecuta un puesto cuando se guarda en la base de datos.
    20 wp_insert_post wp-includes\functions-post.php wp-incluye \ funciones-post.php 207 207
    21 edit_attachment wp-includes\functions-post.php wp-incluye \ funciones-post.php 342 342
    22 add_attachment wp-includes\functions-post.php wp-incluye \ funciones-post.php 344 344
    23 delete_attachment wp-includes\functions-post.php wp-incluye \ funciones-post.php 380 380
    24 delete_post wp-includes\functions-post.php wp-incluye \ funciones-post.php 538 538 Receives Recibe
    the post ID as a parameter. el puesto de identificación como un parámetro. Executes whenever a post is deleted. Ejecuta cuando un puesto queda suprimido.
    25 wp_blacklist_check wp-includes\functions-post.php wp-incluye \ funciones-post.php 642 642
    26 parse_query wp-includes\classes.php WP-incluye \ classes.php 86 86
    27 parse_query wp-includes\classes.php WP-incluye \ classes.php 238 238
    28 pre_get_posts wp-includes\classes.php WP-incluye \ classes.php 262 262
    29 loop_start wp-includes\classes.php WP-incluye \ classes.php 699 699
    30 loop_end wp-includes\classes.php WP-incluye \ classes.php 706 706
    31 generate_rewrite_rules wp-includes\classes.php WP-incluye \ classes.php 1323 1323 No
    parameter. parámetro. Executes whenever the rewrite rules are recomputed. Ejecuta cada vez que la reescritura de las reglas se recalcula. To modify the computed Para modificar la calculada
    rules, use the filter rewrite_rules_array instead. normas, utiliza el filtro rewrite_rules_array lugar.
    32 comment_post wp-includes\comment-functions.php wp-incluye \ functions.php comentario - 52 52 Receives Recibe
    the comment ID as a parameter. la observación ID como parámetro. Executes when a comment is added through wp-comments.php. Ejecuta un comentario cuando se añade a través de wp-comments.php.
    33 comment_flood_trigger wp-includes\comment-functions.php wp-incluye \ functions.php comentario - 126 126
    34 edit_comment wp-includes\comment-functions.php wp-incluye \ functions.php comentario - 191 191 Receives Recibe
    the comment ID as a parameter. la observación ID como parámetro. Executes whenever a comment is edited. Ejecuta un comentario cada vez que se edita.
    35 delete_comment wp-includes\comment-functions.php wp-incluye \ functions.php comentario - 198 198 Receives Recibe
    the comment ID as a parameter. la observación ID como parámetro. Executes when a comment is deleted. Ejecuta un comentario cuando se suprime.
    36 wp_set_comment_status wp-includes\comment-functions.php wp-incluye \ functions.php comentario - 209 209 Receives Recibe
    the comment ID as a parameter. la observación ID como parámetro. Executes when the comment status changes. Ejecuta cuando el comentario cambios en el estado.
    37 pre_ping wp-includes\comment-functions.php wp-incluye \ functions.php comentario - 635 635
    38 wp_set_comment_status wp-includes\comment-functions.php wp-incluye \ functions.php comentario - 794 794
    39 wp_head wp-includes\functions.php WP-incluye \ functions.php 1432 1432 No
    parameter. Template tag. Executes in the parámetro. plantilla de etiqueta. Ejecuta en el section. sección. Useful for insertion Útiles para su inserción
    of additional content like metatags or javascript. de contenido adicional como metaetiquetas o javascript.
    40 wp_footer wp-includes\functions.php WP-incluye \ functions.php 1436 1436 No
    parameter. Template tag. Executes just before the end of the <body> tag. parámetro. plantilla de etiqueta. Ejecuta justo antes de que finalice el <body>.
    Useful for insertion of additional content or statistics code like Google Analytics. Útil para la inserción de contenido adicional o código como las estadísticas de Google Analytics.
    41 comment_form wp-content\themes\classic\comments-popup.php wp-content \ temas \ clásico \ comentarios-popup.php 86 86 Receives Recibe
    the comment’s post ID as a parameter. la observación del puesto de ID como parámetro. Template tag. Plantilla de etiqueta. Executes after displaying the Ejecuta después de mostrar el
    comment form for a post that allows comments. el formulario de comentarios para un puesto que permite comentarios.
    42 comment_form wp-content\themes\classic\comments.php wp-content \ temas \ clásico \ comments.php 67 67
    43 comment_form wp-content\themes\default\comments-popup.php wp-content \ temas \ default \ comentarios-popup.php 86 86
    44 comment_form wp-content\themes\default\comments.php wp-content \ temas \ default \ comments.php 98 98
    45 rdf_ns wp-rdf.php WP-rdf.php 21 21
    46 rdf_header wp-rdf.php WP-rdf.php 32 32
    47 rdf_item wp-rdf.php WP-rdf.php 54 54
    48 comment_id_not_found wp-comments-post.php WP-comments-post.php 11 11 Receives Recibe
    the comment’s post ID as a parameter. la observación del puesto de ID como parámetro. Executes when attempting to display the comment Ejecuta al intentar mostrar el comentario
    form for a post that does not exist. formulario para un puesto que no existe.
    49 comment_closed wp-comments-post.php WP-comments-post.php 14 14 Receives Recibe
    the comment’s post ID as a parameter. la observación del puesto de ID como parámetro. Executes when attempting to display the comment Ejecuta al intentar mostrar el comentario
    form for a post that has closed comments. formulario para un puesto que ha cerrado los comentarios.
    50 comment_on_draft wp-comments-post.php WP-comments-post.php 17 17
    51 pingback_post xmlrpc.php xmlrpc.php 1236 1236 Receives Recibe
    the comment ID as a parameter. la observación ID como parámetro. Executes when a comment is added via XMLRPC. Ejecuta un comentario cuando se añade a través de XMLRPC.
    52 publish_phone wp-mail.php WP-mail.php 146 146 Receives Recibe
    the post ID as a parameter. el puesto de identificación como un parámetro. Executes when a post is added via wp-mail.php. Ejecuta un puesto cuando se añade a través de wp-mail.php.
    53 rss2_ns wp-rss2.php WP-rss2.php 19 19
    54 rss2_head wp-rss2.php WP-rss2.php 29 29
    55 rss2_item wp-rss2.php WP-rss2.php 52 52
    56 edit_form_advanced wp-admin\edit-form-advanced.php wp-admin \ edit-form-advanced.php 216 216 No
    parameter. parámetro. Executes during the display of the admin panel’s advanced editing page, Ejecuta durante la exhibición de la administración del grupo de avanzada de edición de la página,
    just before the justo antes de la
    is closed that contains the post content textarea. está cerrado que contiene el puesto de contenido de texto. Useful Útil
    for inserting additional input fields into the advanced editing form. para la inserción de campos de entrada adicional en la forma de edición avanzada.
    57 admin_menu wp-admin\menu.php wp-admin \ menu.php 57 57 No
    parameter. parámetro. Executes after the basic admin panel menu structure is in place. Ejecuta después de que el administrador de base de menús del panel de estructura en su lugar. Useful Útil
    for adding additional menus to the admin panel. para añadir menús adicionales para el panel de admin.
    58 admin_head wp-admin\admin-header.php wp-admin \ admin-header.php 312 312 No
    parameter. parámetro. Executes in the Ejecuta en el section of the admin panel. sección del panel de admin. Useful for insertion Útiles para su inserción
    of additional content. de contenido adicional.
    59 personal_options_update wp-admin\profile-update.php wp-admin \ perfil-update.php 23 23
    60 activate_ wp-admin\plugins.php wp-admin \ plugins.php 14 14
    61 deactivate_ wp-admin\plugins.php wp-admin \ plugins.php 21 21
    62 manage_posts_custom_column wp-admin\edit.php wp-admin \ edit.php 218 218
    63 delete_comment wp-admin\post.php wp-admin \ post.php 232 232
    64 check_passwords wp-admin\admin-functions.php wp-admin \ admin-functions.php 388 388
    65 check_admin_referer wp-admin\admin-functions.php wp-admin \ admin-functions.php 971 971
    66 switch_theme wp-admin\admin-functions.php wp-admin \ admin-functions.php 1126 1126
    67 switch_theme wp-admin\admin-functions.php wp-admin \ admin-functions.php 1133 1133
    68 edit_page_form wp-admin\edit-page-form.php wp-admin \ editar páginas-form.php 214 214 No
    parameter. parámetro. Executes inside the Ejecuta el interior de la
    tag on the page editing form. etiqueta en la página de edición. Useful for Útil para
    inserting additional input fields in the page editing form. la inserción de nuevos campos de entrada en la página de edición.
    69 show_user_profile wp-admin\profile.php wp-admin \ profile.php 105 105
    70 profile_personal_options wp-admin\profile.php wp-admin \ profile.php 114 114
    71 edit_user_profile wp-admin\user-edit.php wp-admin \ usuario-edit.php 168 168
    72 activity_box_end wp-admin\index.php wp-admin \ index.php 113 113
    73 admin_footer wp-admin\bookmarklet.php wp-admin \ bookmarklet.php 101 101 No
    parameter. parámetro. Executes at the end of the admin panel inside the body tag. Ejecuta al final del panel de admin dentro del cuerpo etiqueta. Useful for Útil para
    insertion of additional content. inserción de contenido adicional.
    74 edit_category wp-admin\admin-db.php wp-admin \ admin-db.php 123 123
    75 create_category wp-admin\admin-db.php wp-admin \ admin-db.php 126 126
    76 add_category wp-admin\admin-db.php wp-admin \ admin-db.php 127 127
    77 delete_category wp-admin\admin-db.php wp-admin \ admin-db.php 175 175
    78 delete_user wp-admin\admin-db.php wp-admin \ admin-db.php 238 238
    79 edit_link wp-admin\admin-db.php wp-admin \ admin-db.php 297 297
    80 add_link wp-admin\admin-db.php wp-admin \ admin-db.php 299 299
    81 delete_link wp-admin\admin-db.php wp-admin \ admin-db.php 323 323
    82 simple_edit_form wp-admin\edit-form.php wp-admin \ edit-form.php 70 70 No
    parameter. parámetro. Executes during the display of the admin panel’s simple editing page, just Ejecuta durante la visualización de los admin del panel de edición simple página, justo
    before the antes de la
    is closed that contains the post content textarea. está cerrado que contiene el puesto de contenido de texto. Useful for Útil para
    inserting additional input fields into the simple editing form. la inserción de nuevos campos de entrada en la edición de forma simple.
    83 admin_footer wp-admin\admin-footer.php wp-admin \ admin-footer.php 9 9
    84 switch_theme wp-admin\themes.php wp-admin \ themes.php 14 14 Receives Recibe
    the name of the current theme as a parameter. el nombre del tema actual como un parámetro. Executes when the blog theme is changed. Ejecuta cuando el tema blog está cambiado.
    85 trackback_post wp-trackback.php WP-trackback.php 95 95 Receives Recibe
    the comment ID as a parameter. la observación ID como parámetro. Executes when a comment is added via trackback.php. Ejecuta un comentario cuando se añade a través de trackback.php.
    86 atom_ns wp-atom.php WP-atom.php 17 17
    87 atom_head wp-atom.php WP-atom.php 25 25
    88 atom_entry wp-atom.php WP-atom.php 42 42
    89 core_files_loaded wp-settings.php WP-settings.php 164 164
    90 plugins_loaded wp-settings.php WP-settings.php 187 187
    91 shutdown wp-settings.php WP-settings.php 222 222 No
    parameter. parámetro. Executes when the page output is complete. Ejecuta cuando la página se completa la producción.
    92 init wp-settings.php WP-settings.php 227 227 Executes Ejecuta
    after WordPress has finished loading but before any headers are sent. después de WordPress ha terminado de cargar, pero antes de que las cabeceras se envían. Useful for intercepting Útil para interceptar
    $_GET or $_POST triggers. $ _GET O $ _POST desencadenantes.