About

Amateur hobbyist

16 Snippets
<10 Favourites
<10 Downloads

add post formats

Adding different types of post formats: aside – Typically styled without a title. Similar to a…

webfontloader.js

// Add custom scripts function add_custom_script_webfont_loader_js() { wp_register_script( 'webfontloader', 'https://cdnjs.cloudflare.com/ajax/libs/webfont/1.6.28/webfontloader.js', array(), '1.6.28', true ); wp_enqueue_script( 'webfontloader'…

Bootstrap 5

// Add custom scripts function add_custom_script_bootstrap5() { wp_register_script( 'bootstrap5_js', 'https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.3.3/js/bootstrap.min.js', array(), '5.3.3', true ); wp_enqueue_script( 'bootstrap5_js'…

Hide All Admin Notices in Sidebar

Hides all admin notices in a collapsible sidebar. AI generated code. Use with caution.

Display both published and modified date

‹?php // Code from codewp.ai function codewp_display_dates( $content ) { if(get_post_type() != 'post') { return $content;…

Dynamic copyright year using HTML

Adjust the styling either inline or using css

Back to Top Button (copy)

Add a simple button to scroll back to top on the frontend.

Shortcode for Dynamic copyright year using HTML

Adjust the styling either inline or using css. Either automatically add this to your site-wide footer,…

Replace [year] with the current year

Type [year] anywhere that you want the current year to be inserted.

Hide admin nags

.notice .is-dismissable { display: none; } /* In Wordpress, set this to be inserted into the…

Add dynamic copyright year

This shortcode will automatically add "Copyright © 2024" (or the current year).

1 2