czerwiec 2021

How to add custom add_action hook to the custom admin settings page

In this example menu and submenu is created where specific css file is loaded with custom hook WordPress will read the hook name automatically if we provide the right syntax. When we create add_menu_page() we should assign it to the variable. Next we can add a hook starting with „load-{$variable name}”. Check the example below

How to add custom add_action hook to the custom admin settings page Read More »

Create wordpress plugin that adds custom text to the bottom of the single article content

To make this plugin we need to follow those steps: Step 1. Create plugin folder, main php file and fill it with standard values. Step 2. Create a menu where custom text can be added (in this case we will create a submenu of Generic Settings) add_options_page() with callback function that will generate the whole

Create wordpress plugin that adds custom text to the bottom of the single article content Read More »

Jak zainstalować SASS z konsolą i node.js

Na początek musimy sprawdzić czy posiadamy zainstalowane środowisko node.js.Można to zrobić przechodząc do konsoli cmd i wpisać Jeśli pokaże się nr wersji to pomijamy kolejny krok, a jeśli pojawi się błąd to musimy zainstalować node.jsPrzechodzimy na stronę https://nodejs.org/en/ pobieramy instalkę i instalujemy.Po zainstalowaniu node.js możemy zainstalować SASS. Aby to zrobić wpisujemy w konsoli cmd (czasami

Jak zainstalować SASS z konsolą i node.js Read More »

Wstęp do jQuery

jQuery to biblioteka javascript, która pozwala programować znacznie szybciej. Aby dołączyć bibliotekę jQuery, należy pobrać link CDN stąd: https://code.jquery.com/ lub pobrać cały plik i umieścić na stronie, choć opcja CDN jest preferowana. Link umieszczamy w sekcji <head> strony.Szkielet startowy dla strony www znajdziecie tutaj: Szkielet strony www html Kod w jQuery zaczynamy od jednej z

Wstęp do jQuery Read More »