Introduction to AJAX

Introduction to AJAX

Tiempo de lectura: 3 minutos Reading Time: 2 minutes AJAX (Asynchronous JavaScript and XML) is a web development technique that allows updating parts of a page without having to reload the entire page. This technology is widely used for creating interactive web applications and enhancing the user experience. What is AJAX?AJAX is a combination of different technologies, including JavaScript, XML, … Read more

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

Stopwatch Using HTML, CSS, and JavaScript

Stopwatch Using HTML, CSS, and JavaScript

Tiempo de lectura: < 1 minuto Reading time: < 1 minute To create a stopwatch in HTML, CSS, and JavaScript, you can follow the code example below: <!DOCTYPE html> <html> <head> <title>Stopwatch</title> <style> .container { text-align: center; margin-top: 50px; } .time { font-size: 48px; } </style> </head> <body> <div class=”container”> <h1>Stopwatch for DevCodeLight</h1> <div class=”time”>00:00:00</div> <button onclick=”start()”>Start</button> <button onclick=”stop()”>Stop</button> </div> <script> … Read more

Change Flutter App Theme from Light to Dark

Tiempo de lectura: < 1 minuto Reading time: < 1 minute First, we need to add the provider dependency inside the pubspec.yaml file. dependencies: flutter: sdk: flutter provider: ^5.0.0 To modify the theme of an application, I’ll show an example below: import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; void main() { runApp( ChangeNotifierProvider( create: (context) => ThemeProvider(), child: MyApp(), ), ); } class ThemeProvider … 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

Add Github Project to a Jenkins Pipeline

Add Github Project to a Jenkins Pipeline

Tiempo de lectura: 3 minutos Reading time: 3 minutes Hello and welcome, today we are going to learn how we can add a Github project in Jenkins. The first thing we’re going to do is go to our Job created in Jenkins. Now we go to Configure and then Pipeline. We choose Pipeline script from SCM. Now we choose SCM … Read more

Create Webhook for Jenkins using Github

Create Webhook for Jenkins using Github

Tiempo de lectura: 3 minutos Reading time: 3 minutes Hello, today we are going to learn how to create a Webhook to automatically deploy with Jenkins using Github. First, let’s go to our Jenkins and settings. We need to install the Generic Webhook Trigger plugin, which is compatible with Github. Once installed, go to your Jenkins Job > Configuration and … Read more

Create RSA Key for Github Authentication

Create RSA Key for Github Authentication

Tiempo de lectura: 2 minutos Reading time: 2 minutes Today, I’m going to show you how to create an RSA key for use in your Github projects (https://github.com/) The first thing we need to do is generate an RSA key in Ubuntu or WSL: ssh-keygen -t rsa -b 4096 -C “email@example.com” Replace “email@example.com” with the email associated with your Gitlab … Read more

Importing a Gitlab Project into Github

Importing a Gitlab Project into Github

Tiempo de lectura: 3 minutos Reading Time: 2 minutes Today we are going to learn how we can import a Gitlab project into Github. The first thing we are going to do is go to our Github and click on + (import repository). Now we are going to select the requested options: First, we add the URL of our Gitlab … Read more