wip find user fields
This commit is contained in:
@@ -57,6 +57,7 @@ function fipfcard_main_shortcode() {
|
||||
|
||||
$fipfcard_tools = new PLGNTOOLS();
|
||||
|
||||
|
||||
$fipfcard_tools->add_files_to_front( array(
|
||||
"example_style.css",
|
||||
"example_init.js",
|
||||
@@ -76,12 +77,21 @@ function fipfcard_main_shortcode() {
|
||||
$names = ["hugo", "camille"];
|
||||
$ages = ["13", "34", "56"];
|
||||
|
||||
$getPostMeta = get_post_meta( get_the_ID() );
|
||||
$getMetaData = get_metadata( 'post', get_the_ID() );
|
||||
$post_meta = $getPostMeta;
|
||||
|
||||
$getUserMeta = get_metadata( 'user', get_current_user_id() );
|
||||
$user_meta = $getUserMeta;
|
||||
|
||||
$html_front = $fipfcard_tools->create_html(
|
||||
array(
|
||||
"example_index.html",
|
||||
"example_index2.html",
|
||||
),
|
||||
compact(
|
||||
"post_meta",
|
||||
"user_meta",
|
||||
"names",
|
||||
"ages",
|
||||
)
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
<div id="model_plugin_shortcode">
|
||||
<ol>
|
||||
<p>list of post meta :</p>
|
||||
<?php
|
||||
foreach($post_meta as $meta_key => $meta_value) {
|
||||
include($html_dir."templates/print_meta.html");
|
||||
}
|
||||
?>
|
||||
</ol>
|
||||
<ol>
|
||||
<p>list of user meta :</p>
|
||||
<?php
|
||||
foreach($user_meta as $meta_key => $meta_value) {
|
||||
include($html_dir."templates/print_meta.html");
|
||||
}
|
||||
?>
|
||||
</ol>
|
||||
|
||||
<p>i am a new p</p>
|
||||
<p class="first_el_to_change">to change</p>
|
||||
<button id='test_ajax_1' name="ajax_button_1" value="2024">2024</button>
|
||||
|
||||
4
plugins/fipfcard_plugin/html/templates/print_meta.html
Normal file
4
plugins/fipfcard_plugin/html/templates/print_meta.html
Normal file
@@ -0,0 +1,4 @@
|
||||
<li>
|
||||
"<?php echo esc_html($meta_key); ?>" :
|
||||
<?php echo esc_html(json_encode($meta_key)); ?>
|
||||
</li>
|
||||
2
private
2
private
Submodule private updated: a3f485f995...3a33975c3f
Reference in New Issue
Block a user