|
@@ -11,12 +11,10 @@ get_header(); ?>
|
|
<?php while (have_posts()) : the_post();
|
|
<?php while (have_posts()) : the_post();
|
|
|
|
|
|
$login_id_e = "";
|
|
$login_id_e = "";
|
|
-
|
|
|
|
if (function_exists('get_field')) {
|
|
if (function_exists('get_field')) {
|
|
$pid = get_post();
|
|
$pid = get_post();
|
|
if (has_blocks($pid_content)) {
|
|
if (has_blocks($pid_content)) {
|
|
$blocks = parse_blocks($pid->post_content);
|
|
$blocks = parse_blocks($pid->post_content);
|
|
- var_dump($blocks);
|
|
|
|
foreach ($blocks as $block) {
|
|
foreach ($blocks as $block) {
|
|
if ($block["blockName"] == "acf/faculty-member") {
|
|
if ($block["blockName"] == "acf/faculty-member") {
|
|
$login_id_e = $block["attrs"]["data"]["login_id"];
|
|
$login_id_e = $block["attrs"]["data"]["login_id"];
|
|
@@ -24,6 +22,11 @@ get_header(); ?>
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
?>
|
|
?>
|
|
<section class="static-banner">
|
|
<section class="static-banner">
|
|
<div class="static-banner-underlay">
|
|
<div class="static-banner-underlay">
|
|
@@ -54,8 +57,6 @@ get_header(); ?>
|
|
<?php the_field('designation'); ?>
|
|
<?php the_field('designation'); ?>
|
|
</h2>
|
|
</h2>
|
|
|
|
|
|
- <p><?php echo $login_id_e ?></p>
|
|
|
|
-
|
|
|
|
<?php if (have_rows('contact_details')) : ?>
|
|
<?php if (have_rows('contact_details')) : ?>
|
|
|
|
|
|
<?php while (have_rows('contact_details')) : the_row(); ?>
|
|
<?php while (have_rows('contact_details')) : the_row(); ?>
|
|
@@ -107,15 +108,12 @@ get_header(); ?>
|
|
<?php endif; ?>
|
|
<?php endif; ?>
|
|
|
|
|
|
<?php
|
|
<?php
|
|
- $employeeid = get_field('employeeid');
|
|
|
|
-
|
|
|
|
-
|
|
|
|
$url = 'http://103.109.52.3/webapi/api/EmployeeJournal';
|
|
$url = 'http://103.109.52.3/webapi/api/EmployeeJournal';
|
|
$response = wp_remote_post(
|
|
$response = wp_remote_post(
|
|
$url,
|
|
$url,
|
|
array(
|
|
array(
|
|
'body' => array(
|
|
'body' => array(
|
|
- 'employee_id' => $employeeid,
|
|
|
|
|
|
+ 'employee_id' => $login_id_e,
|
|
"year" => "",
|
|
"year" => "",
|
|
'user_login_id' => 'api_user',
|
|
'user_login_id' => 'api_user',
|
|
'auth_token' => 'api_user20230419045143'
|
|
'auth_token' => 'api_user20230419045143'
|
|
@@ -123,26 +121,21 @@ get_header(); ?>
|
|
|
|
|
|
)
|
|
)
|
|
);
|
|
);
|
|
- $data = json_decode(wp_remote_retrieve_body($response), true);
|
|
|
|
-
|
|
|
|
- ?>
|
|
|
|
|
|
|
|
- <?php if (!empty($employeeid)) : ?>
|
|
|
|
-
|
|
|
|
- <div class="bio desc-block">
|
|
|
|
- <h2 class="m-text">Publication</h2>
|
|
|
|
- <p class="m-text">
|
|
|
|
- <?php
|
|
|
|
- if (!empty($employeeid)) {
|
|
|
|
|
|
+ $data = json_decode(wp_remote_retrieve_body($response), true); ?>
|
|
|
|
|
|
- print_r($data);
|
|
|
|
- } else {
|
|
|
|
- echo 'Please insert Login ID of the faculty member</ul></div>';
|
|
|
|
- }
|
|
|
|
|
|
+ <div class="bio desc-block">
|
|
|
|
+ <h2 class="m-text">Publication</h2>
|
|
|
|
+ <p class="m-text">
|
|
|
|
+ <?php
|
|
|
|
+ if (!empty($login_id_e)) {
|
|
|
|
|
|
- ?>
|
|
|
|
- </div>
|
|
|
|
- <?php endif; ?>
|
|
|
|
|
|
+ print_r($data);
|
|
|
|
+ } else {
|
|
|
|
+ echo 'Please insert Login ID of the faculty member</ul></div>';
|
|
|
|
+ }
|
|
|
|
+ ?>
|
|
|
|
+ </div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|