Categories
Web Development

Clear cache with Chrome

Go to chrome://net-internals/#dns and clear the browser DNS cache Hard reload while developer tools are open with right-click on the refresh button Clean the local DNS ipconfig /flushdns

Categories
Wordpress

WordPress Theme – Template Files

Official link https://developer.wordpress.org/themes/basics/template-files/ index.php Used when the blog page of the website is opened front-page.php Used when the front page of the website is opened 404.php Used when the page or URL is not found on the website archive.php Used when posts from a category, tag or something else are displayed as an archive comments.php […]

Categories
Wordpress

WordPress API

https://developer.wordpress.org/reference/ WordPress API Dashboard widgets Database HTTP API Filesystem Global Variables Metadata Options Plugins Quicktags REST API Rewrite Settings Shortcode Theme Modification Transients XML-RPC

Categories
Wordpress

Where you can find the value of get_theme_mod

The value of get_theme_mod can be found and customized via the Customizer Click the Customize button at the top left corner when you browse the website

Categories
Wordpress

Display only the excerpt of the post and not the whole content

To display only the excerpt of the post and not the whole content find: the_content in the theme Here is documentation about the_content https://developer.wordpress.org/reference/functions/the_content/ https://developer.wordpress.org/reference/functions/get_the_content/ Change it to the_excerpt. Here is documentation https://developer.wordpress.org/reference/functions/the_excerpt/ Adding Read more to an excerpts function excerpt_readmore($more) { return ‘… <a href=”‘. get_permalink($post->ID) . ‘” class=”readmore”>’ . ‘Read More’ . ‘</a>’; […]

Categories
Wordpress

WordPress Plugins

I use

Categories
Wordpress

WordPress Editor TinyMCE Keyboard Shortcuts

Default shortcuts, Ctrl + letter: Letter Action Letter Action u Underline b Bold i Italic x Cut c Copy v Paste a Select all z Undo y Redo k Insert/edit link Additional shortcuts, Shift + Alt + letter: Letter Action Letter Action 1 Heading 1 2 Heading 2 3 Heading 3 4 Heading 4 5 […]

Categories
Web Development

Websockets vs AJAX

Long-polling Let’s say you want to check automatically if there is a new comment to add it automatically at the bottom of an article. Long-polling means you would check every Х seconds if there is something new, with web-sockets comments can come in automatically as they are posted Websockets have two advantages. They have much […]