teleren/devto huggingface dataset:
Install Mongodb on PHP Mac OS Montery (M1)
Tags: mongodb, php, macos, webdev
Published: 2024-03-13 03:43:40

# Install Mongodb on PHP Mac OS Montery (M1)

Install the PHP MongoDB Extension before installing the PHP Library for MongoDB. It is worth noting, that full MongoDB driver experience is provided by installing both the low-level extension (which integrates with our C driver) and high-level library, which is written in PHP.

But to make windows terminal look beauty we need to add a theme, so lets start.

## Prerequisites
- Install PECL
	```
	brew install pecl
	```
- Install pcre2
	```
	brew install pcre2
	```

## Tutorial
- Install mongodb extension
	```sh
	pecl install mongodb
	```
- Enabled extension on PHP.ini
	```sh
	extension=mongodb.so
	```
- To verify installation.
	```
	php -i | grep mongodb
	```
- You shoul see output.
	```
	$ php -i|grep mongo
	mongodb
	libmongoc bundled version => 1.17.2
	libmongoc SSL => enabled
	libmongoc SSL library => Secure Transport
	libmongoc crypto => enabled
	libmongoc crypto library => Common Crypto
	libmongoc crypto system profile => disabled
	libmongoc SASL => enabled
	libmongoc ICU => disabled
	libmongoc compression => enabled
	libmongoc compression snappy => enabled
	libmongoc compression zlib => enabled
	libmongoc compression zstd => enabled
	libmongocrypt bundled version => 1.0.4
	libmongocrypt crypto => enabled
	libmongocrypt crypto library => Common Crypto
	```

## Error
When error appear.
- Copy pcre2 to your php dir
  ```
  cp /opt/homebrew/Cellar/pcre2/10.xxxx/include/pcre2.h /opt/homebrew/Cellar/php@7.xxx/7.xxx/include/php/ext/pcre/pcre2.h
  ```
  notes Change pcre2 version & php version with your local machine version.
- Run
	```
	sudo pecl install mongodb
	```
- It should fix your error.

## Source
-  https://stackoverflow.com/questions/66496119/pecl-fails-installing-mongodb-driver-on-apple-silicon-m1
-  https://www.mongodb.com/developer/quickstart/php-setup/
Jun88 - Trang Chủ Thương Hiệu Cá Cược Nhà Cái Jun88
Published: 2024-03-13 03:42:33

JUN88 khang dinh uy tin cua minh thong qua viec dam bao mot moi truong ca cuoc minh bach, cong bang va an toan. Dan dau trong viec mang den nhung trai nghiem giai tri cao cap cung co hoi kiem tien lon.
Dia Chi: 31/6/14 Hoang Viet, Phuong 4, Tan Binh, Thanh pho Ho Chi Minh, Viet Nam
Email: jun88es8@gmail.com
Website: https://jun88.es/
Dien Thoai: (+63) 967 118 6409
#jun88 #jun88es #nhacaijun88 #jun88online
Social Links:


https://jun88.es/
https://jun88.es/huong-dan-dang-ky-jun88/
https://jun88.es/huong-dan-nap-tien-jun88/
https://jun88.es/huong-dan-rut-tien-jun88/
https://jun88.es/huong-dan-tai-app-jun88/
https://jun88.es/quynh-anh/
https://www.facebook.com/jun88es/
https://twitter.com/jun88es
https://www.youtube.com/channel/UCQY1IDvOJj3r9JylJITLW5g
https://www.pinterest.com/jun88es/
https://social.msdn.microsoft.com/Profile/jun88es
https://social.technet.microsoft.com/Profile/jun88es
https://vimeo.com/jun88es
https://github.com/jun88es
https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/678712
https://www.blogger.com/profile/05173680404736561532
https://www.reddit.com/user/jun88es
https://vi.gravatar.com/jun88es
https://soundcloud.com/jun88es
https://medium.com/@jun88es/about
https://www.flickr.com/people/jun88es/
https://www.tumblr.com/jun88es
https://jun88es8.wixsite.com/jun88es
https://sites.google.com/view/jun88es/trang-ch%E1%BB%A7
https://www.behance.net/jun88es
https://www.openstreetmap.org/user/jun88es
https://draft.blogger.com/profile/05173680404736561532
https://www.liveinternet.ru/users/jun88es/post503195511/
https://linktr.ee/jun88es
https://www.twitch.tv/jun88es/about
http://tinyurl.com/jun88es
https://ok.ru/jun88es/statuses/155499707102175
https://profile.hatena.ne.jp/jun88es/profile
https://issuu.com/jun88es
https://dribbble.com/jun88es/about
Embracing the Evolution of Education: Learning Online
Tags: tutorial, productivity, discuss, learning
Published: 2024-03-13 03:35:23

In the digital age, education has transcended the confines of traditional classrooms, paving the way for a dynamic and accessible learning experience through online education. With the internet as our virtual campus, the opportunities for learning have expanded exponentially, breaking down barriers of geography, time constraints, and accessibility.

Online education offers unparalleled flexibility, allowing learners to customize their learning journey according to their schedule and pace. Whether it's mastering a new skill, pursuing a degree, or delving into a hobby, there's a plethora of courses and resources available at the click of a button.

Moreover, the interactive nature of [online](https://scholarlyhelp.com/online-class/) learning fosters a collaborative and engaging environment, where students can connect with peers and instructors from around the globe. Discussion forums, virtual classrooms, and multimedia content enrich the learning experience, encouraging active participation and knowledge sharing.
2024-03-12: Not too much going on
Tags: devjournla
Published: 2024-03-13 03:29:20

I don't really have much to report. The job hunt has been going decently well; been getting an unprecedented amount of interviews and recruiters reaching out, so that's probably a good sign. I also revamped my resume a bit to fit a more senior level developer like myself.

I did try to get started on developing a Safari extension that would automatically close any duplicate tabs in the background that it sees, but apparently extensions are a lot more complicated than given credit for and the documentation is surprisingly sparse. Even ChatGPT is pretty unhelpful. But I'm determined to get it done because it would be very useful. I'd already been using an equivalent extension in Brave/Chrome and it's been a lifesaver.

I think my biggest challenge so far is trying to get the Info.plist to actually be configured correctly because there are so many flags that could be set. Same with the manifest.json. At a first glance, Safari extensions seem pretty similar to Chrome extensions but I also haven't worked with Chrome extensions either, so it's kind of a moot point.

I did manage to get it so that it can have permissions to all domains in Safari, but I'm just trying to figure out at the moment how to get the actual underlying JavaScript code to run at all. I'll be tackling this through the coming week and keep you updated by next week.

Until next time, cheers.
🚀 Seeking Study Partners for ASP.NET! 🚀
Published: 2024-03-13 02:37:57

Hey fellow developers,

Are you passionate about ASP.NET? Let's team up and dive deep into these exciting technologies together! I'm seeking dedicated study partners who are eager to learn and collaborate on challenging projects.

Please note: I'm specifically looking for partners who can work in the EST or CST timezone to ensure smooth communication and collaboration.

If you're ready to level up your skills and share knowledge in a supportive environment, this is the perfect opportunity. Let's tackle complex concepts, build innovative applications, and support each other's growth as developers.

If you're interested in joining our study group and can accommodate the EST or CST timezone, drop a comment or message me directly. Let's embark on this learning journey together and make meaningful progress in our development careers!

Looking forward to connecting with you all!
Top Bến Tre AZ
Published: 2024-03-13 02:37:50

 Top Bến Tre AZ là một trang web trang web hàng đầu cung cấp thông tin đa dạng và đáng tin cậy về tỉnh Bến Tre từ lịch sử, văn hóa, du lịch, địa điểm nổi tiếng, đặc sản ẩm thực, những kỷ niệm, trải nghiệm và góp phần giới thiệu vẻ đẹp văn hóa và tiềm năng phát triển đến những thông tin cập nhật mới nhất về đời sống, sự kiện xã hội, kinh tế của tỉnh 

[https://topbentreaz.com/](https://topbentreaz.com/)

#topbentreaz, #topbentreaz, #topbentre, #topbentre, #tinhbentre, #tinhbentre
https://www.facebook.com/profile.php?id=61557367286976
https://www.pinterest.com/topbentreaz/
https://www.linkedin.com/in/top-b%E1%BA%BFn-tre-az-329398294/
https://www.reddit.com/user/topbentreaz/
https://www.instagram.com/topbentreaz/
📈 ETHEREUM PRICE ANALYSIS & PREDICTION
Published: 2024-03-12 22:36:35


📈 Ethereum surged above $4,000, marking a significant milestone in its continuous uptrend. After facing rejection, it now retests this level as support, with a bounce expected amid optimistic buying sentiment. 🚀

💹 Since June 2022, Ethereum has witnessed an impressive 3,200% increase, reaching a peak of $4,093 before retracing to the $4,000 mark. The current dip appears to be a retest of the breakout, indicating a potential further uptick in the coming days.

📉 Despite minor fluctuations, Ethereum's overall trend remains highly bullish, mirroring Bitcoin's pattern and potentially aiming to surpass its all-time high soon. The January 2022 high serves as the next buying target, while the $3,200 level acts as monthly support.

📊 Immediate resistance lies at $4,150, followed by $4,220, $4,500, and $4,800, with the all-time high of $4,868 representing a crucial breakout point. On the downside, key support levels include $3,900, $3,580, and $3,300.

⚠️ Disclaimer: This analysis is not financial advice. It's essential to conduct thorough research and exercise caution when investing in cryptocurrencies. 🛡️

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0cvguf4trw3qxenaytqh.png)
accessibility tips from an accessibility engineer
Tags: a11y
Published: 2024-03-13 02:08:32

---
title: accessibility tips from an accessibility engineer
published: true
description: I am a blind accessibility engineer who happens to program as well. Here are some typical accessibility errors I see in my day job and how to fix them.
tags: #a11y
# cover_image: https://direct_url_to_image.jpg
# Use a ratio of 100:42 for best results.
# published_at: 2024-03-13 01:18 +0000
---
I am a blind accessibility engineer and programmer and I thought I would write an article detailing some of the common things I see in my day job. Accessibility may seem overwhelming, but it doesn't have to be. So here are three things you can do to improve your website's accessibility right away.
* use semantic html
If something should be a button, make it a <button> If something should be a link, make it a link. Don't use purely clickable divs to indicate actions. If you must make a custom web control, reach for a library that has implemented aria best practices. There are a lot of complications to using aria correctly, and why reinvent the wheel?

* label form fields
It is super important to label form fields. Otherwise, people using assistive technology may not understand which fields need which data. Labeling is typically done using the <label> tag which takes the id of the form field as the for attribute and wraps the visible label. For example:
```
<label for="firstName">First Name</label>
<input type="text" id="firstName" name="firstName"/>
```
You may also use the aria-describedby attribute, which takes the id of a div/span htat describes the control. This is typically used to add additional instructions to a form field or convey validation errors.
* properly mark up modals and set focus to them
You need to set focus to an element inside a modal dialog when it opens, otherwise people using assistive technology will have no clue that your modal opened. Also decorate your modal with the role="dialog" and aria-modal="true" attributes. Ensure that users cannot escape the modal by tabbing out of it into the page content behind it. A good library should take care of this for you.

I hope this short post has been helpful. Please leave feedback/questions in the comments.
Unleashing the Magic of JavaScript's Superpowers: Making Code Dance to Its Own Beat
Tags: javascript, asyn, beginners, webdev
Published: 2024-03-13 01:23:41

Ever wondered how websites do multiple things at once, like loading images while showing text or fetching data without freezing up? Well, that's where JavaScript's special trick comes in: it's asynchronous nature!

So, what's the big deal about being asynchronous? Think of it like this: imagine you're cooking in the kitchen. Instead of waiting for one thing to finish before starting the next, you can chop veggies while something's boiling on the stove. JavaScript works kinda like that, handling tasks simultaneously without getting stuck.

Now, let's talk about the cool tools JavaScript uses for its magic show. First up, callbacks: they're like little notes you leave for JavaScript to pick up once it's done with something else. Then came promises, which are like guarantees that something will happen in the future, and you can plan for it. And finally, async/await swooped in, making things even simpler by letting you write code that looks and acts like it's happening one step at a time, even if it's not!

Why does all this matter? Well, imagine you're browsing a website, and it freezes every time it's loading something. Not fun, right? But with JavaScript's asynchronous powers, websites can keep doing stuff in the background while still letting you scroll, click, and interact smoothly.

And it's not just for websites! JavaScript's tricks work for all sorts of things, like making apps run faster or handling lots of tasks at once on the server side. It's like having a multitasking superhero in your coding toolbox!

But, as with any superpower, there are challenges. Keeping track of what's happening when, handling errors, and making sure everything stays neat and tidy can get tricky. That's why it's important to learn the best ways to use JavaScript's powers responsibly.

So, next time you're amazed by how fast a website loads or how smoothly an app runs, remember: it's all thanks to JavaScript's awesome ability to juggle tasks like a pro. And with a little practice, you too can unlock the magic of asynchronous programming!
handlebars: TypeError: exphbs is not a function
Published: 2024-03-13 01:20:39

I was trying to use handlebars as my template engine on nodejs doing this:

**const exphbs = require("express-handlebars");
app.engine("hbs", exphbs());
app.set("view engine", "hbs");
app.set("views", "views");**

but this gerate an error:

![error](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/v1ar3sozeyufphvlj6qd.png)

To fix this, I had to change the way I import


**const express = require('express');
const { engine } = require('express-handlebars');
const app = express();
app.engine('handlebars', engine());
app.set('view engine', 'handlebars');
app.set("views", "./views");**
CSS Battle #2 - Carrom
Tags: html, css, webdev, challenge
Published: 2024-03-13 01:16:00


![image css battle target #2-Carrom](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yhhqosn1nki5dtkla7u4.png)
[see the daily target](https://cssbattle.dev/play/2)

### Challenge Overview

The goal of this challenge is to create a design resembling a square using HTML and CSS. The provided target image features a square shape against a contrasting background.

## Method 1 - Reflection Box

**YouTube Video** : [see video](https://www.youtube.com/watch?v=Z0Asqy0dcvU)
**GitHub Repo** : [see code](https://github.com/jithesh-poojari/css-battles/blob/main/battles/%231%20-%20Pilot%20Battle/%232_Carrom.md#method-1---reflection-box)

**Stats:**

- **Match:** 100%
- **Score:** 687.89{159}

```html
<p><p a>
<style>
  * {
    background: #62374e;
  }

  p {
    position: absolute;
    top: 34;
    left: 50;
    width: 50;
    height: 50;
    background: #fdc57b;
  }

  [a] {
    top: 184;
  }

  p, [a] {
    -webkit-box-reflect: right 200px;
  }
```

**Code Explanation:**

- **Background (`*`):** The `*` selector targets the entire page, setting its background to a warm golden shade `#5d3a3a`.
- **Square (`p`):** A square is created using a `<p>` element, positioned at the top center of the container. It has a fixed width and height of 50 pixels, with a contrasting background color `#fdc57b`.
- **Reflection (`[a]`):** The `[a]` attribute selector applies a reflection effect to the square, adding a visual touch.

## Method 2 - Shadow Box

**YouTube Video** : [see video](https://www.youtube.com/watch?v=i9WFFFbxYNc)
**GitHub Repo** : [see code](https://github.com/jithesh-poojari/css-battles/blob/main/battles/%231%20-%20Pilot%20Battle/%232_Carrom.md#method-2---shadow-box)

**Stats:**

- **Match:** 100%
- **Score:** 707.36{138}

```html
<style>
  * {
    background: #62374e;
    > * {
      margin: 50 0 0 50;
      width: 50;
      height: 50;
      background: #fdc57b;
      color: #fdc57b;
      box-shadow: 0 150px, 250px 0, 250px 150px;
    }
  }
</style>
```

**Code Explanation:**

- **Box Shadow (`box-shadow`):** The `box-shadow` property is applied to an anchor (`<a>`) element. Two shadows are defined:
  - A 2-inch inner shadow with a white color (`#b5e0ba`).
  - A 5-inch outer shadow with a contrasting dark color (`#5d3a3a`).

### Conclusion

Both methods effectively create a square design, meeting the challenge's requirements.

- Method 1 (Reflection Box) utilizes the box model approach, setting background colors and dimensions while adding a reflection effect.
- Method 2 (Shadow Box) achieves a similar result using the `box-shadow` property to simulate the square shape with shadows.

Choose the method that best fits your preference or coding style.
error to install next.js
Published: 2024-03-13 01:15:51

I was trying to install next.js using their tutorial and got this error message: "npm ERR! enoent ENOENT: no such file or directory, lstat **C:\Users\mariobros\AppData\Roaming\npm**

This problem can be fixed by creating an empty folder called "npm" at the directory C:\Users\mariobros\AppData\Roaming\
NodeJS and "crypto" for tokens
Published: 2024-03-13 00:45:48

If you want to have secure tokens in your action emails that can contain state information then consider using nodejs crypto functions - specifically `json-crypto` (which is based on the crypto library).

Here are the reasons why:
- URL safe (so you can use them immediately in your email links)
- "nonce" based - meaning that each invocation of the encryption function produces a completely different encrypted string (so it is harder to crack)
- easy to use with your own TOKEN secret (the thing that you protect on your backend that allows the magic to happen)

I wont go into a tutorial because the github repo for `json-crypto` is easy to follow.

The only thing I will point out is that you don't want to create your TOKEN key/secret each time - you should create that once and store it securely for your application to use it.  This is often in environment variables but you could also use a secrets vault of some kind.

The other thing to consider is what you put in your payload - the JSON data that you encrypt.  I'd recommend at least a `timestamp` of some kind (probably just the numeric date from `new Date()`).  With a timestamp you can manage an `expiry` of the token as well as provide timeline reporting (like how long did it take to get a response).  You also want some context regarding what is in the decrypted token.  This could be anything like a `type` or an `email` or both - or just some other pieces of context that allow the token to be actioned for the specific purpose you want it for (e.g. a subscription confirmation).  The payload can be any valid stringified JSON.

Personally, to keep my token smaller, I like to use an array rather than an object.  The array then has a standard sequence of information like a `type`, the `timestamp`, a `version`, then other context information applicable to the `type` based on the `version`.  But you do you - just make sure you follow a standard that you set.

That's about it... Yes - no code on this one again.  I don't want to tackle the JS vs TS debate.
How to create a rule to filter out emails received by BCC
Published: 2024-03-13 00:21:38

1.Open an BCC email
2.Select File > Properties
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kfq05y4ynwkmwa8q2za6.png)

3.Look for Internet headers and find and save BCC identifier which looks something like this: _X-MS-Exchange-Organization-Recipient-P2-Type: Bcc_
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/f5ln9cmq63empk34jkc2.png)

4.Access the outlook on the web (OWA)
5.Select Settings > Mail > Rules
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qnz9gmpeg4idwdscn8ml.png)

6.Create a rule and choose “Message header includes”
7.Copy in the value you found on step 3
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/c03sy1wgo8mamezv9jol.png)

8.Save rule

**Logic behind this**
- With Outlook rules, some are “client side” and some are “server side”. When you create them in OWA, they are automatically server side and will trigger regardless of Outlook client being open or not. 
- If the rule is “client side”, then Outlook must be open for them to trigger. The specific predicate of the subject is available both client and server side.
- Creating the rule in OWA ensures it is completely server side, and that’s why it works when the rule is added to OWA, not to Outlook Desktop.
Add Parameters for Workflow Input in Azure Logic Apps
Tags: azure, logicapps
Published: 2024-03-13 00:17:32

1.Open Azure logic app
2.Select Workflows > choose workflow you want to edit
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ce624ohbh8zi4rwnye7u.png)

3.Select Developer > Designer on the left side menu
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hda9a3src05oaor44xsc.png)

4.Select the action box
5.Select the desired parameter and add value for the selected parameter
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pisunrrt9e769q61rejb.png)
Welcome Thread - v267
Tags: welcome
Published: 2024-03-13 00:00:00

---
published_at : 2024-03-13 00:00 +0000
---
![Jerry from Tom and Jerry waving](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pj943tf3xz7zxy6of414.gif)

---

1. Leave a comment below to introduce yourself! You can talk about what brought you here, what you're learning, or just a fun fact about yourself.

2. Reply to someone's comment, either with a question or just a hello. 👋 

3. Elevate your writing skills on DEV using our [Best Practices](https://dev.to/devteam/best-practices-for-writing-on-dev-creating-a-series-2bgj) series!