By default, custom post types are not included in the search results, so we are going to create a function that allows them to be queried and searched by WordPress. You can include custom post types in the search result by adding below function in your functions.php file.
This is a place where you can quickly reference elements from wp-admin.
You can use them in your own plugins.
If you don’t want to deal with the messy process of loading WordPress manually, you can just use WP-CLI’s eval-file command:
This function checks in each directory level starting from the directory of the current file for the file wp-config.php. If it is found the directory is to be assumed the wordpress base path. The check can of course be changed to other wordpress core files.
Php class that downloads a remote image, moves it into the /uploads/ directory of your site, adds it to WordPress as a new attachment and returns to you the attachment ID.
This is a php function you can use to remove base url prepended to image loaded from remote host. Just copy this script and drop it in your theme function or plugin.
You can use Git to work with a local repo and the CodeCommit repository to which you’ve connected the local repo. The following are some basic examples of frequently used Git commands. Read Git documentation.
Click the links below to read: Vagrant Tutorial For Beginners: Getting Started Guide Discover Vagrant Boxes
Read it here: https://developer.hashicorp.com/vagrant/docs/networking/basic_usage
Generate Private key Open terminal as an Administrator and goto openssl installation path by typing below commad. then enter below command and enter a password 2 times and then enter below command and enter same password you entered in previous step. Create SSL Certificate Enter below command and enter real or dummy company information You …
I get the error message, “Error: Init: SSLPassPhraseDialog builtin is not supported on Win32” when starting my website using Apache.
There are two directories in which we can create and store our virtual host configuration files. Both of them are located inside /etc/nginx directory. The name of those two directories are sites-available and sites-enabled. But why do we need two directories to store our virtual host files? Actually, we will store our virtual host files in the sites-available directory only. Then, we …
In the context of Nginx, worker processes refer to the individual instances or units of execution that handle incoming client requests and process them in parallel. Nginx is a popular web server and reverse proxy server that is known for its high performance and scalability. By default, Nginx starts a single worker process, which means …