Skip to content

Commit

Permalink
Added new speaker fields
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Abraham <[email protected]>
  • Loading branch information
cjyabraham committed Jul 18, 2024
1 parent 52d421e commit a0340df
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -824,14 +824,25 @@
'settings' => array(
array(
'type' => 'text',
'id' => 'title',
'id' => 'job_title',
'data_type' => 'meta',
'data_key' => 'title',
'label' => __( 'Title, Company' ),
'data_key' => 'job_title',
'label' => __( 'Job Title' ),
'register_meta' => true,
'ui_border_top' => false,
'default_value' => '',
'placeholder' => __( 'Senior Software Engineer' ),
),
array(
'type' => 'text',
'id' => 'company',
'data_type' => 'meta',
'data_key' => 'company',
'label' => __( 'Company' ),
'register_meta' => true,
'ui_border_top' => false,
'default_value' => '',
'placeholder' => __( 'Title, Company' ),
'placeholder' => __( 'Microsoft' ),
),
array(
'type' => 'image',
Expand All @@ -849,7 +860,7 @@
'data_key' => 'linkedin',
'label' => __( 'LinkedIn URL' ),
'register_meta' => true,
'ui_border_top' => false,
'ui_border_top' => true,
'default_value' => '',
'placeholder' => __( 'https://www.linkedin.com/in/username/' ),
),
Expand Down Expand Up @@ -886,6 +897,17 @@
'default_value' => '',
'placeholder' => __( 'https://cncf.io' ),
),
array(
'type' => 'text',
'id' => 'title',
'data_type' => 'meta',
'data_key' => 'title',
'label' => __( 'OLD!!! Title, Company' ),
'register_meta' => true,
'ui_border_top' => true,
'default_value' => '',
'placeholder' => __( 'For old speakers block' ),
),
),
),
),
Expand Down
12 changes: 7 additions & 5 deletions web/wp-content/plugins/speakers-block-2/block-speakers-block.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,13 @@ function ( $speaker ) {
<?php
while ( $query->have_posts() ) {
$query->the_post();
$id = get_the_ID();
$linkedin = get_post_meta( $id, 'lfes_speaker_linkedin', true );
$twitter = get_post_meta( $id, 'lfes_speaker_twitter', true );
$github = get_post_meta( $id, 'lfes_speaker_github', true );
$website = get_post_meta( $id, 'lfes_speaker_website', true );
$id = get_the_ID();
$linkedin = get_post_meta( $id, 'lfes_speaker_linkedin', true );
$twitter = get_post_meta( $id, 'lfes_speaker_twitter', true );
$github = get_post_meta( $id, 'lfes_speaker_github', true );
$website = get_post_meta( $id, 'lfes_speaker_website', true );
$job_title = get_post_meta( $id, 'lfes_speaker_job_title', true );
$company = get_post_meta( $id, 'lfes_speaker_company', true );
$company_logo = get_post_meta( $id, 'lfes_speaker_company_logo', true );
?>
<li id="<?php
Expand Down

0 comments on commit a0340df

Please sign in to comment.