teleren/devto huggingface dataset:
How no IDE & a single monitor paved the way to my PHP expert certification
Published: 2023-12-22 16:23:10

Hello, coders! 💻

Today I'd like to talk about how a frugal setup helped me learn core PHP 20 years which made it a lot easier to get my PHP 5 Expert certification later on.
Yes, PHP 5, the most recent version back then. :D
Context

Back in 2002 I was still a student. In one assignment we had to develop a complete product. I decided to have a go at coding a forum engine.
We're talking login/registration forms, forgotten password, My Account page with some settings, threads and replies with creation dates, last updated at and all that you'd expect from a decent forum engine.

## Tools used

I decided to not use any framework and start from scratch to better learn PHP.

Since I fancied a challenge I also decided to use Windows Notepad (this was before I switched to Ubuntu).
With Notepad you get:
* no auto completion
* no jump to definition
* no hints

On the other hand you get such a low memory footprint! :D

## Set up: a single screen.
This one is probably the most important factor that helped me remember a ton of functions and their parameters.
You go to php.net and look a function up.
You come back to your editor and code.
You switch back to the doc because you forgot param orders.
Repeat.
Rince.
Now you remember it all because that switching is annoying!

## RTFM
How many times have you heard that? It's really important to know how to read a documentation.
And not just the method you're interested in but the whole family too.
Are you looking at array_merge? Why not check array_column as well and notice it takes a third param which can help you refactor foreach loops you've been using to index elements by a specific key?

Reading comments users added on the official PHP doc is also a great source of information. Take time to read them (even though some are from older versions).

## Certification
To pass the certification you need to know a lot of functions, what they do, their params etc.
Take a look: https://www.testpreptraining.com/tutorial/zend-certified-engineer-sample-questions/

I also had a 5 day training dedicated to preparing developers for the PHP 5 certification. I've learned more about PHP internals (pointers, memory allocation etc).

And then, I passed the exam!

## Conclusion
Even though you might not want to be an official expert it's very important to (know how to) read the documentation. 

So read your language official doc, then the one of your framework/tool of choice.
Read about aspects of the language you do not use or are not familiar enough with.

Most importantly: have fun and keep on getting better!

### PS
It's 2024 and I still use a single monitor ([wmctrl](https://linux.die.net/man/1/wmctrl) FTW)!
Learn how to build a recipe-sharing website with Nuxt and BCMS (Under an Hour)
Published: 2023-12-22 16:10:49

We released the [Nuxt Recipe code starter](https://github.com/bcms/starters/tree/master/nuxt/recipes) and are publishing a step-by-step tutorial! Learn how to create a recipe website using BCMS, structure your recipe website or app, and organize content management and publishing to monetize your recipe-sharing platform.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/s7aum9dn6etlq7ielmw1.jpg)

## Building a recipe-sharing website with Nuxt and BCMS

To create a recipe-sharing platform, you can leverage the power of Nuxt.js, a popular Vue.js framework for building web applications, and BCMS, which provides a flexible and scalable backend infrastructure.

Nuxt.js supports building a fast and dynamic frontend interface for our recipe-sharing platform. It provides features like server-side rendering, static site generation, and routing capabilities that enhance the user experience and make the platform easily navigable.

BCMS serves as the backend system that powers our recipe-sharing platform. It enables us to handle recipe data storage and retrieval and facilitate user interaction through features like comments and likes.

By combining Nuxt.js and BCMS, you can create a powerful and user-friendly recipe-sharing platform that caters to the needs of both recipe creators and food enthusiasts.

Below is a step-by-step tutorial on creating a recipe-sharing platform that covers the basic features of recipe posting and retrieval using Nuxt and BCMS.

You can view the finished version of the application [here](https://recipes-starter.thebcms.com/).

## BCMS and Nuxt: Steps in building a recipe-sharing website

As with any building process, a workflow needs to be followed. Luckily, this one is simple with easy-going logic.

Step1: BCMS Setup

Step 2: Preparing BCMS to render data

Step 3: Content creation of recipe-sharing app in BCMS

Step4: Create Nuxt Application and connect it to our BCMS Backend

Step 5: Deployment

The only thing you need to do is follow these simple steps from the technical tutorial: https://thebcms.com/blog/build-recipes-website-with-nuxt-and-bcms
789win
Published: 2023-12-22 16:02:32

789win | 789win Casa – Nhà cái cá cược và casino trực tuyến hàng đầu Việt Nam. Cung cấp đa dạng trò chơi cá cược thể thao, casino trực tuyến. Giao diện thân thiện, bảo mật tuyệt đối. Tham gia ngay để nhận ưu đãi 89K.
Liên hệ:
Công Ty: 789win Casa
Website: https://789win.casa/
Địa Chỉ: 106a Lê Thị Hồng Gấm, Phú Trinh, Thành phố Phan Thiết, Bình Thuận, Việt Nam
Email: 789win.casa@gmail.com
Điện Thoại: 0908 789 789
Mã Bưu Điện: 70000
#789win #789win_casa #789win_casino #789wincasa

https://twitter.com/789wincasa
https://vimeo.com/789wincasa
https://www.pinterest.com/789wincasa/
https://www.tumblr.com/789wincasa
https://www.twitch.tv/789wincasa/about
https://www.reddit.com/user/789wincasa
https://www.youtube.com/@789wincasa
https://500px.com/p/789wincasa?view=photos
https://linkfly.to/512225DGNMf
https://joy.link/789wincasa
https://micro.blog/789wincasa
https://dubo.tribe.so/user/wincasa789
The Dawn of a New Era in Creativity: GenAI as the Great Equalizer
Published: 2023-12-22 15:56:47

In a remarkable demonstration I recently witnessed, AI showcased its power to redefine artistry. Picture this: a person vocalizes imitations of iconic tunes like those from 'Pulp Fiction', and AI miraculously transforms these hums into full-fledged instrumental masterpieces. This isn't just technology at play; it's a revolution in the making.

{% embed https://www.youtube.com/embed/uKLxVQU-lAU?si=CD1lVhj7MRGg-nqQ %}

AI is rapidly evolving into a pivotal ally for creators, accelerating the process of art creation across various domains - be it text, visuals, or audio. What once took years to master can now be achieved with a few whispers and hums, thanks to Generative AI's intuitive understanding and recreation capabilities.

This seismic shift isn't just about speed. It's about democratizing creativity. AI breaks down barriers, allowing individuals without formal training or experience to express themselves in ways previously unimaginable. It's a gateway for unleashing hidden talents and bridging gaps in technical expertise.

More profoundly, AI stands as a beacon of hope for those with different impediments. It opens doors to artistic avenues that were once deemed inaccessible. Whether it's composing music, creating videos, or penning narratives, AI equips everyone with the tools to materialize their creative visions.

As we stand at the beginning of this this transformative era, it's crucial to recognize AI's role not just as a tool but as a collaborator in the creative process. It's a partnership where human imagination is complemented by AI's efficiency and innovation, paving the way for a more inclusive and diverse artistic landscape.

Gen AI is not just changing the way we create; it's redefining who can be a creator. It's an exciting time for all of us in the creative industry, as we embrace this new wave of inclusive and democratized artistry.

## Join Me

Read more about [Engineering Culture in Meta (Facebook)](https://engineeringbolt.com), [⚡Newsletter](https://engineeringbolt.substack.com/subscribe), [Twitter](https://twitter.com/alexrashkov) and [LinkedIn](https://www.linkedin.com/in/alexrashkov) for more Career, Leadership and Growth advice.

[![Engineering Bolt Newsletter Subscription](https://miro.medium.com/v2/resize:fit:1400/0*GRosK-LpWlj01rUR.png)](https://engineeringbolt.substack.com/subscribe)
Extensions Browser useful
Tags: extensions, browser, customize, tooling
Published: 2023-12-22 15:55:19

Some useful extensions for everyday:

- Bitwarden - Free Password Manage - [Link](https://chromewebstore.google.com/detail/bitwarden/nngceckbapebfimnlniiiahkandclblb)
>Bitwarden is a free and secure password manager for all your devices.
>Bitwarden is the easiest and most secure way to save all your usernames and passwords, keeping them synchronized between all your devices.

- daily.dev | The homepage developers deserve - [Link](https://chromewebstore.google.com/detail/dailydev-the-homepage-dev/jlmpjdjjbgclbocgajdjefcidcncaied)
>Get one personalized feed for all the knowledge you need as a developer and tech world.

- Notifier for Gmail - [Link](https://chromewebstore.google.com/detail/notifier-for-gmail/dcjichoefijpinlfnjghokpkojhlhkgl)
>Notifier for multiple Google Mail (Gmail) accounts and labels.
>Gmail™ Notifier is an open-source project that notifies you about incoming emails from all your Google Mail accounts and labels.

- DuckDuckGo Privacy Essentials - [Link](https://chromewebstore.google.com/detail/bkdgflcldnnnapblkhphbgpggdiikppg)
>Simple, seamless privacy protection for your browser.

- Notion Web Clipper - [Link](https://chromewebstore.google.com/detail/notion-web-clipper/knheggckgoiihginacbkhaalnibhilkk)
>Web Clipper to save any website into Notion.
>Notion is your all-in-one workspace, where you can write, plan, collaborate and get organized. Take notes, keep databases, build a wiki, project manage your team — all with one tool.

- Session Buddy - [Link](https://chromewebstore.google.com/detail/session-buddy/edacconmaakjimmfgnblocblbcdcpbko)
>Session Buddy is a tab manager.Save open tabs as collections that can be easily restored later.

- Tab Suspender - [Link](https://chromewebstore.google.com/detail/tab-suspender/fiabciakcmgepblmdkmemdbbkilneeeh)
>Automatically suspend, park, hibernate inactive tabs and save up to 80% of memory, reduce load on your device, battery and heat.
If you like to use many open Tabs at once - this extension will help you and automatically accelerate your browser and purge the memory.

- Take Webpage Screenshots Entirely - FireShot - [Link](https://chromewebstore.google.com/detail/captura-de-p%C3%A1gina-complet/mcbpblocgmgfnpjjppndjkmgjaogfceg)
>Capture web page images, edit and save in PDF/JPEG/GIF/PNG/BMP. Upload, print, send to clipboard or email.

- Video Speed Controller - [Link](https://chromewebstore.google.com/detail/video-speed-controller/nffaoalbilbmmfgbnbgppjihopabppdk)
>Speed up, slow down, advance and rewind HTML5 audio/video with shortcuts. you can customize keyboard shortcuts and super usefull for Youtube.

**📝You can add others that you consider in the comments.**



Thanks for read!

[redhcp page](https://redhcp.site/)  | [redhcp X](https://x.com/Th3Ces4r) | [redhcp github](https://github.com/redhcp)
la moneda física
Published: 2023-12-21 13:07:12

La actualidad esta en un proceso de transición progresivo del uso de la moneda física a los pagos digitales que, gracias al avance de la tecnología, se han posicionado como un método habitual de pago. Este proceso se ha dado en todo el mundo y Latinoamérica no ha sido la excepción. Sin [embargo](https://financialmulticultural.com/), el contrapunto de este avance son los desafíos de seguridad que enfrentan las empresas para hacer frente a los ciberdelitos relacionados con el robo de datos e identidad que hoy son los más _[frecuentes](https://www.basictechcapital.com/)_.  

Chile es un país digitalmente conectado, con una alta tasa de penetración de Internet, por lo que se ha [vuelto ](https://betterpeoplebusiness.com/)un mercado atrayente para los negocios digitales. Además, cuenta con una tasa de penetración bancaria por encima del promedio de los países de América Latina, lo que es un buen indicador para que los pagos digitales proliferen y se ganen la confianza de los consumidores chilenos. Los pagos digitales en el país han sufrido un acelerado crecimiento en el número de transacciones y diversidad de aplicaciones, ascendiendo al 110% del PIB. Estos datos son proporcionados por el Informe de de [Pago ](https://betterupdigital.com/)(ISIP), que comunica la evolución y las principales tendencias de los medios y sistema de pago en Chile, presentado por el Banco Central en el 2023.
Let's have a look at #cybersecurity #breaches #data leaks from 11.12.2023-16.12.2023 #dataleak
Tags: cybersecurity, devsecops, developers, devops
Published: 2023-12-22 15:31:54

Hello, since I was and still I'm sick I forgot to post a new video here on walk BREACH forums to see the breached websites. I hope you enjoy if so please subscribe and like the video as that is what is driving me forward on creating even better videos with more content, etc.

YouTube:
{% embed https://youtu.be/qSfbfJJyzjI %}

Rumble:
{% embed https://rumble.com/v42al60-lets-have-a-look-at-cybersecurity-breaches-data-leaks-from-11.12.2023-16.12.html %}


Thanks
C# - Using Static Caches for Efficiency
Tags: csharp, programming, tutorial, beginners
Published: 2023-12-22 15:30:00

**Tired of repeating calculations?**  Static caches can be your savior! Here's a quick trick to boost your C# code's efficiency.

For example, We need to calculate the factorial of a number multiple times within our code.

**Inefficient approach:**

```C#
public int Factorial(int n)
{
  if (n == 0)
    return 1;
  return n * Factorial(n - 1);
}

// Repeated calls to Factorial slow down the code
```

**Solution:** Implement a static cache to store calculated values.

```C#
public class FactorialHelper
{
  private static readonly Dictionary<int, int> cache = new Dictionary<int, int>();

  public static int Factorial(int n)
  {
    if (cache.ContainsKey(n))
    {
      return cache[n];
    }

    if (n == 0)
    {
      return 1;
    }

    int result = n * Factorial(n - 1);
    cache[n] = result;
    return result;
  }
}
```

**Benefits:**

* **Reduced overhead:** By caching previously calculated values, we avoid unnecessary re-calculations, significantly improving performance.
* **Improved memory efficiency:** Caching avoids holding intermediate results in memory, saving valuable resources.

Consider using the `ConcurrentDictionary` class for thread-safe cache access in multi-threaded applications.
The Twelve-Factor App: Dependencies
Tags: learning, writing, architecture, devjournal
Published: 2023-12-22 15:28:46

### Explicitly declare and isolate dependencies

---

Most programming languages have their designated platforms for sharing and posting system packages. For instance, Ruby utilizes `Rubygems`.

Each library can be installed through what we refer to as "site-packages," which serve system-wide, or by explicitly declaring them within our app's scope, a practice known as "vendoring."

**The Twelve-Factor methodology does not rely on the implicit existence of system-wide packages.** Instead, dependencies should be declared within our application via a declaration manifest. Additionally, it employs dependency isolation tools during execution to prevent any implicit dependencies from seeping in from the surrounding system. For instance, Ruby employs the `Gemfile` manifest format for dependency declaration and `bundle exec` for dependency isolation.

Explicitly declaring dependencies brings the benefit of simplifying setup for new developers joining the app. A new developer can clone the app's codebase onto their local machine, needing only the language runtime and the installed dependency manager as prerequisites. Consequently, they can set up everything required with a single command, such as `bundle install` for Ruby/Bundler.

**The Twelve-Factor methodology also does not rely on the implicit existence of system tools** like `curl` or `ImageMagick`, for example. Even though these tools may be prevalent in many systems, there's no assurance that they will exist on all systems where the app may run in the future, or that they will be compatible with the app. All of those should be "vendored" into the app.

_This Twelve-Factor App post series is a means for me to consolidate the knowledge I've gained while studying these rules. Please feel free to visit [the site (https://12factor.net/) for more detailed explanations. That's all folks!_
How to create a #Docker image ( for the #website ) and run the container #php #apache #devops 2024
Tags: docker, php, developer, devops
Published: 2023-12-22 15:28:46

Hello, since I was and still I'm sick I forgot to post a new Tutorial update on How to Write and Build Docker images. I hope you enjoy if so please subscribe and like the video as that is what is driving me forward on creating even better videos with more content, etc.

YouTube:
{% embed https://youtu.be/lmp1oeLNoEo %}


Thanks
Resolving Intellisense Autosuggest (Ctrl + Space) Issues in VS Code on macOS Ventura and Sonoma
Tags: fix, macos, vscode
Published: 2023-12-22 15:26:58

## TLDR 

Check your global shortcuts

1. Go to System Settings > Keyboard > Keyboard Shortcuts ... > Input Sources
2. Disable "Select the previous input source"
3. Click "Done"
4. Restart machine
5. Enjoy! 

## Introduction

Recently, I encountered a frustrating issue while working in Visual Studio Code on my Mac running macOS Ventura and Sonoma. The Intellisense autosuggest, a crucial feature for any developer, suddenly stopped working. After some investigation, I realized that a specific keybinding conflict was the root cause. In this article, I’ll share how I fixed this issue, hoping it will help others facing a similar problem.
The Problem

Intellisense is an essential tool in a developer's arsenal, offering real-time code suggestions, parameter info, and quick fixes. However, a few months ago, it became unresponsive on my setup. The issue was perplexing, as there were no apparent changes in my VS Code settings or extensions that could have led to this.

After a bit of research and troubleshooting, I discovered that the problem was due to a keybinding conflict with macOS Ventura and Sonoma. The default keybinding for Intellisense in VS Code is Ctrl + Space. However, this combination is also used by macOS for switching input sources.
The Solution

Here's a step-by-step guide to resolve this keybinding conflict:
Step 1: Access Keyboard Shortcuts

Navigate to System Settings > Keyboard > Keyboard Shortcuts ... > Input Sources.
Step 2: Modify the Shortcut

Locate the option for "Select the previous input source" and disable it. This step is crucial as it removes the conflict with the VS Code Intellisense shortcut.
Step 3: Save Changes

After disabling the conflicting shortcut, click "Done" to save your changes.
Step 4: Restart Your Machine

For the changes to take full effect, restart your Mac. This ensures that the new settings are applied correctly.
Step 5: Enjoy Uninterrupted Coding

Once your machine restarts, open VS Code and enjoy the seamless functionality of Intellisense autosuggest.
Conclusion

Keybinding conflicts can be a subtle yet frustrating issue, especially when they interfere with essential development tools like Intellisense in VS Code. By following these simple steps, you can quickly resolve such conflicts on macOS Ventura and Sonoma, leading to a more efficient and enjoyable coding experience.

Remember, sometimes the solutions to complex problems are simpler than we think!

Follow me on X [@tonadev](https://x.com/tonadev)
Laravel 10 Find Month Difference Between Two Dates with Example
Tags: laravel, php, webdev, tutorial
Published: 2023-12-22 15:12:23

To calculate the difference in months between two dates in Laravel, you can use the Carbon library, a PHP API extension for DateTime. Laravel comes bundled with Carbon, making it easy to perform date and time operations within your Laravel application.
<br>

## Laravel Using Carbon diffInMonths Method
You can determine the difference in months between two dates as follows.
```php
use Carbon\Carbon;

$date1 = Carbon::createFromDate(2023, 1, 1); // start date
$date2 = Carbon::createFromDate(2023, 6, 1); // end date

$monthDifference = $date1->diffInMonths($date2);

echo $monthDifference; 
```
Using diffInMonths will provide you with the absolute difference in months between two dates. You can customize the dates by replacing createFromDate(2023, 1, 1) and createFromDate(2023, 6, 1) with your desired date values.
![laravel two date calculate](https://larainfo.com/storage/canvas/images/lqsUv71hwr6brQp27aVj6Y9pqcsav3UfId8dhufb.png)
<br>

## Laravel Carbon Handling Time Zones
If you're working with time zones, make sure to set the correct time zone for each Carbon instance.
```php
$date1 = Carbon::createFromDate(2023, 1, 1, 'America/New_York');
$date2 = Carbon::createFromDate(2023, 6, 1, 'America/New_York');
```
[Laravel 10 REST API CRUD Operation Example
](https://larainfo.com/blogs/laravel-10-rest-api-crud-operation-example)
<br>
## Laravel Subscription Duration Calculation
Let's say you're running a subscription service and you want to calculate the number of months a user has been subscribed.
```php
use Carbon\Carbon;

// Subscription start date (for example, the date a user joined)
$subscriptionStartDate = Carbon::parse('2023-01-15');

// Current date (or the date of subscription end/cancellation)
$currentDate = Carbon::now();

// Calculate the month difference
$monthsSubscribed = $subscriptionStartDate->diffInMonths($currentDate);

echo "The user has been subscribed for $monthsSubscribed months.";
```
![laravel two date month calculate](https://larainfo.com/storage/canvas/images/FG7z93uGzyL9unknru9ykqsmO8aegQw0lZzZbYYA.png)
<br>

## Laravel Age Calculation in Months
Suppose you have a web application where you need to calculate a user's age in months.
```php
<?php

use Carbon\Carbon;

// User's date of birth
$birthDate = Carbon::createFromDate(2010, 5, 20); // Replace with the actual date of birth

// Current date
$currentDate = Carbon::now();

// Calculate age in months
$ageInMonths = $birthDate->diffInMonths($currentDate);

echo "The user is $ageInMonths months old.";
```