gde_row_actions
The Google Doc Embedder gde row actions function.
Description
gde_row_actions( $pid );
Parameters (1)
- 0. $pid
- The pid.
Usage
if ( !function_exists( 'gde_row_actions' ) ) { require_once ABSPATH . PLUGINDIR . 'google-doc-embedder/options.php'; } // The pid. $pid = null; // NOTICE! Understand what this does before running. $result = gde_row_actions($pid);
Defined (1)
The function is defined in the following location(s).
- /options.php
- function gde_row_actions( $pid ) {
- $actions = array(
- // action name => arr ( label, class )
- "edit" => array( __('Edit', 'google-document-embedder'), 'edit' ),
- "delete" => array( __('Delete', 'google-document-embedder'), 'delete' ),
- "default" => array( __('Make Default', 'google-document-embedder'), 'default' )
- );
- // protect default profile
- if ( $pid == 1 ) {
- unset( $actions['delete'], $actions['default'] );
- }
- foreach ($actions as $k => $v) {
- $act[] = '<span class="'.esc_attr($v[1]).'" id="'.esc_attr($k).'-'.esc_attr($pid).'"><a href="options-general.php?page=gde-settings">'.htmlentities($v[0]).'</a></span>';
- }
- $acts = implode( " | ", $act );
- return $acts;
- }