Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Provide Custom Callback For Row Actions Module #269

Open
varunsridharan opened this issue Sep 1, 2020 · 0 comments
Open
Assignees
Labels
enhancement New feature or request Module php Pull requests that update Php code

Comments

@varunsridharan
Copy link
Member

Is your feature request related to a problem? Please describe.

When i am using Row actions module to add custom links in row i can only have values that are predefined in WP_Posts Object
other than that i can't have my own values if i use Row Actions module for internal post types

Describe the solution you'd like

It would be great to have a custom callback option using which i can return my own HTML

Example

$instance = wponion_row_actions( 'post' );
$instance->link_after( 'share-link', function () {
	$value = get_post_meta( get_the_ID(), 'mysharelink', true );
	return sprintf( '<a href="%1$s">%2$s</a>', $value, __( 'My Share Link' ) );
} );

Describe alternatives you've considered

--

Additional context

--

@varunsridharan varunsridharan self-assigned this Sep 1, 2020
@varunsridharan varunsridharan added enhancement New feature or request Module php Pull requests that update Php code labels Sep 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Module php Pull requests that update Php code
Projects
None yet
Development

No branches or pull requests

1 participant