Fetching WordPress Categories with Python API

Fetching WordPress Categories with Python API

Tiempo de lectura: 3 minutos Reading time: < 1 minute Today we are going to learn how to fetch categories from the WordPress API. Let’s create a python file named code.py with the following content: import os from dotenv import load_dotenv import requests import json import random from requests.auth import HTTPBasicAuth def fetch_categories(): load_dotenv() WORDPRESS_USERNAME = os.getenv("WORDPRESS_USERNAME") WORDPRESS_PASSWORD = os.getenv("WORDPRESS_PASSWORD") ... Read more

Auto-publishing posts on WordPress using Python

Auto-publishing posts on WordPress using Python

Tiempo de lectura: 2 minutos Reading time: 2 minutes Today we are going to learn how we can auto-publish posts on our WordPress using Python. The first thing we need to do is create our remote_publish.py file. def post_publisher(wpBaseURL, postStatus): WP_url = wpBaseURL + “/wp-json/wp/v2/posts” auth = HTTPBasicAuth(WORDPRESS_USERNAME, WORDPRESS_PASSWORD) headers = { “Accept”: “application/json”, “Content-Type”: “application/json” } payload = json.dumps({ … Read more

Replace URL in WordPress for Domain Migration

Replace URL in WordPress for Domain Migration

Tiempo de lectura: < 1 minuto Reading time: < 1 minute Hello, today we are going to see how we can replace the WordPress URL with a new one. We go to the WordPress files and search for wp-config.php. We modify these lines (if they are not present, we add them and they will be used by default): define('WP_HOME','https://domain.com'); define('WP_SITEURL','https://domain.com'); In ... Read more

Fix HTTP Issue in WordPress When Migrating to HTTPS. CSS or JS Resources Not Loading.

Fix HTTP Issue in WordPress When Migrating to HTTPS. CSS or JS Resources Not Loading.

Tiempo de lectura: < 1 minuto Reading time: < 1 minute Today, I’m going to show you how to fix the WordPress issue when migrating a site with SSL HTTPS and encountering the message “Mixed content blocked: WordPress”. This issue typically affects JSON and CSS files. This problem prevents the CSS or JS resources from loading on our WordPress website. To … Read more

How to Secure a WordPress Website? Different Security Techniques You Can Apply to Your WordPress Sites.

How to Secure a WordPress Website? Different Security Techniques You Can Apply to Your WordPress Sites.

Tiempo de lectura: 2 minutos Hello everyone! In this tutorial, we will discuss some security techniques you can use to make your website secure. These techniques are applicable to any website, whether it’s built with WordPress or another platform. Use HTTPS HTTPS is a secure hypertext transfer protocol that protects the privacy and integrity of data exchanged between a website … Read more

How to Create a CSS Animation in WordPress

How to Create a CSS Animation in WordPress

Tiempo de lectura: 2 minutos Reading Time: 2 minutes Hello! In this tutorial, I’ll show you how to create a CSS animation in WordPress. CSS animations can add dynamism and life to your website and are relatively easy to implement. To get started, you’ll need to access your WordPress dashboard and create a new post or page. Once you’ve entered … Read more

WordPress Error Solution: ‘The uploaded file exceeds the upload_max_filesize directive in php.ini’

WordPress Error Solution: ‘The uploaded file exceeds the upload_max_filesize directive in php.ini’

Tiempo de lectura: 2 minutos Reading time: 2 minutes Good afternoon, friends. Today I have prepared a post that can help you solve a very common error that occurs when uploading heavier-than-normal plugins to your WordPress site. In this case, we are going to install the plugin wp-rocket (please note that this plugin is paid). In my case, I already … Read more

Connect a WordPress Website with AdSense to Display Automatic Ads

Connect a WordPress Website with AdSense to Display Automatic Ads

Tiempo de lectura: 3 minutos Reading time: 3 minutes Good afternoon, in this post, I’m going to explain how to connect AdSense to our WordPress website with automatic ads to monetize it. Below, I’ll detail the steps you need to follow: In the WordPress Control menu, go to the Plugins option and click on “add new”. Search for “Site Kit … Read more