Skip to content

Commit

Permalink
Add promotion for my WordPress Accessibility course.
Browse files Browse the repository at this point in the history
Also, update to the recent course. Sheesh.
  • Loading branch information
joedolson committed Aug 25, 2024
1 parent 4b1dafd commit 12f14b9
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 1 deletion.
6 changes: 6 additions & 0 deletions src/css/wpa-styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,12 @@
display: block;
}

.linkedin-course-promotion.promotion img {
max-width: 110px;
margin-right: 10px;
margin-left: 10px;
}

.postbox.promotion p.coupon {
padding: 1em;
border: 2px dashed #ccc;
Expand Down
Binary file added src/imgs/linkedin.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 26 additions & 1 deletion src/wp-accessibility-settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -674,6 +674,7 @@ function wpa_admin_sidebar() {
</div>
</div>
<?php wpa_edac_promotion(); ?>
<?php wpa_linkedin_promotion(); ?>

<div class="postbox">
<h2 class='hndle'><?php _e( 'Accessibility References', 'wp-accessibility' ); ?></h2>
Expand All @@ -685,7 +686,6 @@ function wpa_admin_sidebar() {
<li><a href="https://make.wordpress.org/themes/handbook/review/accessibility/">WordPress Theme Accessibility Guidelines</a></li>
<li><a href="https://www.joedolson.com/tools/color-contrast.php">Color Contrast Testing</a></li>
<li><a href="http://wave.webaim.org/">WAVE: Web accessibility evaluation tool</a></li>
<li><a href="https://www.linkedin.com/learning/wordpress-accessibility-2/">WordPress Accessibility course at LinkedIn Learning</a></li>
</ul>
</div>
</div>
Expand Down Expand Up @@ -747,6 +747,31 @@ function wpa_admin_sidebar() {
<?php
}

/**
* Show LinkedIn WordPress Accessibility promotion.
*/
function wpa_linkedin_promotion() {
// translators: link to linkedin learning course page.
$promo_text = sprintf( __( 'Want to learn more about WordPress and Accessibility? Take my <a href="%s">WordPress Accessibility course at LinkedIn Learning</a>!', 'wp-accessibility' ), 'https://www.linkedin.com/learning/wordpress-accessibility-22376834/making-accessible-websites-using-wordpress' );
?>
<div class="postbox linkedin-course-promotion promotion">
<h2 class='hndle'><?php _e( 'Learn more about WordPress Accessibility', 'wp-accessibility' ); ?></h2>

<div class="inside">
<div class="wpa-flex">
<img src="<?php echo plugins_url( 'imgs/linkedin.png', __FILE__ ); ?>" alt="LinkedIn" />
<p class="small">
<?php echo wp_kses_post( $promo_text ); ?>
</p>
</div>
<p class="wpa-affiliate">
<a href="https://www.linkedin.com/learning/wordpress-accessibility-22376834/making-accessible-websites-using-wordpress"><?php _e( 'Try the Course', 'wp-accessibility' ); ?></a>
</p>
</div>
</div>
<?php
}

/**
* Show Equalize Digital Accessibility Checker promotion.
*
Expand Down

0 comments on commit 12f14b9

Please sign in to comment.