New answers tagged templates
0
votes
Accepted
When are Shortcode Attributes Available in Template
The answer from @SallyCJ got me started on the solution that worked best for me. It uses some of her code. There are references to other resources that helped out.
function my_get_shortcode_atts($...
1
vote
When are Shortcode Attributes Available in Template
I need access to the shortcode attributes before the content (and
it's shortcode) is processed.... in the first "is $atts available
here" after the add_shortcode
In that case, you can ...
0
votes
Get page id by template
You can query the postmeta table directly:
global $wpdb;
$template = 'page-special';
$sql = "select post_id from {$wpdb->postmeta} where meta_key = '{$template}.php'";
$pages = $wpdb->...
Top 50 recent answers are included
Related Tags
templates × 2040custom-post-types × 257
page-template × 203
php × 174
pages × 147
theme-development × 140
customization × 137
plugins × 132
posts × 121
categories × 118
functions × 112
themes × 110
custom-taxonomy × 108
template-hierarchy × 100
loop × 96
plugin-development × 67
archives × 58
woocommerce-offtopic × 57
shortcode × 51
permalinks × 50
search × 49
child-theme × 48
css × 47
wp-query × 42
get-template-part × 42