teleren/devto huggingface dataset:
🍎 💵 In-App Purchase in iOS apps: how to avoid 30% Apple Pay commission
Tags: ios, swift, todayilearned
Published: 2021-11-19 15:51:22

There are many ways to monetize an application. What affects your choice here are the aims and specifics of your application and the market, for which it was made. One of those methods is organizing purchases within the app. From this text, you will find out how iOS organized the process, what Apple and their competitors provide you with, and why you sometimes will have no choice.

## In-App Purchases

This simple and easy to use mechanism was developed by Apple to help organize sales of their apps or of additional features from their apps. Apple takes a 30% fee from every purchase made with In-App Purchases

There are three types of In-App Purchases:
* Consumable
This purchase can be done multiple times. For example, lives or energy in games.
* Non-consumable
This purchase can only be done once. For example, a character in a game or a movie in an online theater.
* Subscriptions (auto-renewable and non-renewable)
A payment that unlocks your app’s functions for a limited period of time. Auto-renewable subscriptions charge users automatically at the end of each paid period. To continue using non-renewable subscriptions, users need to renew them manually. iTunes is an example of that.

## A few other payment systems

**Stripe** is an American company that develops solutions for accepting and processing electronic payments. Stripe allows users to integrate payment processing into their apps without a need to register a merchant account.

Stripe **takes 2.9% + 30 cents** from each successful transaction.

**PayPal** is the largest debit digital payment platform. PayPal users are able to pay bills, make purchases, accept, and send money transactions.

PayPal **takes from 2.9% to 3.9%** commission fee, depending on how expensive the product was. The exact fee amount depends on your sales figures and whether you trade domestically or internationally.

## Do you need In-App Purchases?

Apple charges lots of money in comparison to their competitors. Going for **Stripe** or **PayPal** might look like a no-brainer, but it’s not so simple. When you develop an iOS application, you face multiple requirements from Apple. One of those requirements prohibits you from making purchases through something other than In-App Purchases.

All digital and virtual goods and services must be paid via **In-App Purchases**. Therefore, owners of entertainment apps and online movie theaters, digital content sellers, and others must use **In-App Purchases**.

On the other hand, if you’ve created a mobile app for your online store, tour agency, or air ticket office, the outcome of the deal between you and your buyer is a physical item or a physical document that proves your right to use the service. In that case, you can use an external payment system and get your money fast, avoiding being ripped-off by the App Store.

![ios-payment-commission](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/37kqq6kfz9w7y3wnuoca.png)
Data in fixed fields text files
Tags: text, php, datastructure
Published: 2021-11-19 15:35:48

---
title: Data in fixed fields text files
published: true
description: Read and write data in fixed fields text files in PHP
tags: text, php, datastructure
//cover_image: https://direct_url_to_image.jpg
---

I have to read and write data from a fixed fields text file.
What is a it? It'a mess like this.

![Fixed fields text file](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4wbynk8s30x6h8ucd9zq.png)

The data organized based on the character position:
1  - 11 Packet ID
12 - 11 Anagraph ID
23 - 10 Submission date
and so on.

How can I read the data in PHP?

First, ugly solution: use `substr` to read

```php
 $identificativo_pacchetto = substr($line,0,11);
 $identificativo_mandante = substr($line,11,11);
 $data_affido = substr($line,22,10);
...
```
and `str_pad` to write

```php
 $line = str_pad($identificativo_pacchetto,11);
 $line .= str_pad($identificativo_mandante,11);
 $line .= str_pad($data_affido,10);
...
```
It'a nightmare!!!

Lets'try with `unpack` and `pack` command.

One line of code to read.

```php
$data =unpack('A11identificativo_pacchetto/A11identificativo_mandante/A10data_affido',$line));

```

and data is an array like this

```json
{
   "identificativo_pacchetto":"1",
   "identificativo_mandante":"52301",
   "data_affido":"19-11-2021"
}
```
One line of code to write

```php
$data = ['1','52301','19-11-2021'];
$line =pack('A11A11A10',...$data));

```
The is no need to pad the values.
Note that the are no filed names (eg . *identificativo_pacchetto*) and no separators (`/`).

I put all together defining the structure in an array.

```php
$def = [
'A11identificativo_pacchetto',
'A11identificativo_mandante',
'A10data_affido
];
$data = ['1','52301','19-11-2021'];
$line = pack(implode('',preg_replace('/^(A\d+).*/','$1',$def)),...$data);
$data = unpack(implode('/',$def),$line);
```
More info:
[PHP manual](https://www.php.net/manual/en/function.unpack.php)
[PHP Cookbook](https://www.oreilly.com/library/view/php-cookbook/1565926811/ch01s11.html)
[Stackoverflow](https://stackoverflow.com/questions/40902357/php-parse-text-file-with-fixed-column-width?rq=1)
PlanetScale integrates with Arctype's MySQL GUI
Tags: mysql, devops, database, tooling
Published: 2021-11-19 15:47:58

Check out our exclusive integration with [Arctype](https://arctype.com/), our favorite database GUI for developers. 

Arctype features a fast, modern interface with [keyboard shortcuts](https://docs.arctype.com/keyboard-shortcuts), a [command bar](https://docs.arctype.com/getting-started/quick-find) to quickly find objects, and the best support for JSON in a SQL client. It’s also free to use. You can already [connect to the main branch](https://arctype.com/mysql/setup/planetscale-mac) of your PlanetScale database in Arctype, but today it’s possible to connect to development branches, switch between them, and even create deploy requests. The power of PlanetScale is experienced within a beautiful GUI! 

For a full walk through, check out the [demo video](https://planetscale.com/blog/planetscale-free-sql-gui-with-arctype).
APK Site 
Tags: programming, softwares, python
Published: 2021-11-19 15:32:59

Apps are what make a phone smart, on android you can load as many apps you want. Primarily users download their apps from the Google play store but now they have a play store alternative, which is called Ac market Apk. Basically, Ac Market is an advanced version of the Google play store with a sample collection of apps and games. All the former run on android devices while the AcMarket app can run on many other platforms like android, ios devices, and windows pc. 

<a href="AcMarket Apk">https://evergreenapk.com/ac-market-apk/</a> download delivers a better experience than the original Google play store. If you think about it for a bit, you’ll probably come up with a quite few names of substitute stores or repositories of android applications that intend to be the greatest revolutionaries to Google play store as they allow us to download the same application but the other alternatives want the user to pay or the user has to purchase an in-app subscription.
Smarty (php template engine) environment setup in vs code
Tags: php, template, vscode, smarty
Published: 2021-11-19 15:27:22

Hi Guys!

I am working in a php app that uses https://www.smarty.net/. I am just beginning to learn, and I'd like to have the best possible setup for my vs code. 
However I have issues. 
I am using prettier and php intelephense at the moment. 
I've got this added in my settings.json:
```
 "files.associations": {
    "*.tpl": "html"
  },
```
that should help with autoformatting using shift+alt+f. However it doesn't.

I have had a hard time finding the php methods in the code, so I added this to my AppData/Roaming/Code/Settings.json file to change the color:

```
"editor.tokenColorCustomizations": {
    "textMateRules": [
      {
        "scope": "entity.name.function",
        "settings": {
          "foreground": "#06ffc1",
          "fontStyle": "italic"
        }
      }
    ]
  }
```
What is CAP (Consistency, Availability or Partition Tolerance) Theorem And Distributed Data ?
Tags: database, datascience, distributedsystems, devops
Published: 2021-11-19 15:08:16

What is CAP (Consistency, Availability or Partition Tolerance) Theorem And Distributed Data ? I got this q in an interview a few years ago and so better learn more about it. It will help you understand why some cloud DBs using strong consistency and some can only do eventual consistency! Thanks to #coachroachlabs Jim Walker for this good talk and help us understand more in the challenges to ensuring consistent distributed data, how to deal with network failures, dropped messages, RAFT, MVCC, etc...

1. video - https://lnkd.in/gM3A-TcE
2. details - https://lnkd.in/gkSaYAHd

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

[Original post - What is CAP (Consistency, Availability or Partition Tolerance) Theorem And Distributed Data ?]
The role of low-code platforms in legacy app migration
Tags: app, webdev, mobile, legacyapps
Published: 2021-11-19 15:00:01

**How low-code platforms help in legacy app migration**

Low-code development is an ideal solution to overcome the challenges of legacy app migration. It plays a significant role in legacy app migration. With low-code platforms, it becomes easier to bridge the gap between legacy and modernized apps.

Low-code solutions can help you to enhance your app performance and drive innovation. However, there are several reasons why you should [migrate your legacy system to low-code](https://www.softwebsolutions.com/resources/migrate-legacy-systems-to-low-code.html).
Fetching weather API Using async/await & axios in react.
Tags: javascript, react, beginners, webdev
Published: 2021-11-19 14:38:59

##I learn an easy way to retrieve weather data from weathermap.org without too may lines of codes and I want to share with you. Let me know if there's a better way to do so. 
1. I install axios into my react weather application:
<pre>
//Axios is use to get HTTP request data from external sources like weather api.

npm install axios
</pre>
 

2. I Go to openweathermap.org and create an account to get url and custom generated api key. Once account is created, click API Keys to create your api key.
You will need the base URL & your custom key as shown below:

<pre>
https://api.openweathermap.org/data/2.5/
[custom api key]
</pre>

Define my api key in my react file. I have in my app.js file:
```javascript
const apiKeys = {
  key: 'e902985907738b357b6a7c7a2651a108',
  base: 'https://api.openweathermap.org/data/2.5/',
};
```
import axios to my app.js file:
```javascript
import axios from 'axios';
```
In my function called App I create async function:

```javascript
async function fetchWeather(e) {
    e.preventDefault();
    try {
      const response = await axios(
//The base URL & api key
        `${apiKeys.base}weather?q=${city}&units=metric&APPID=${apiKeys.key}`
      );
      updateWeather(response.data);
//console.log to see if there's data
console.log(response);
    } catch (error) {
      setError({ message: 'Not Found' });
console.log(error);
    }
  }
```
The code above work like this: Async tell react that the function fetchWeather is asynchronous and await for axios to retrieve the data once it finish, return the result to response variable. Putting the code into try/catch block will catch an error of the code that could potentially fail. In this case if 
there's no location found, the error message will be shown.

####There you go! I hope this is helful. Leave any comment and constructive criticism. :)
##See you next time!

Source code: https://github.com/tomyotwongjai/react-weather-app
How to ask your team for help
Tags: productivity, codenewbie, motivation, leadership
Published: 2021-11-19 14:28:32

## Introduction

Whether you're brand new to coding or you've been doing it for years, if you're working on a coding project with a team, you're going to need to ask for help to make personal progress, as well as progress within the project. Here are some tips to help you out. 

## 1. Don't ask too late

If you've been struggling with something on your own for hours, and keep running into the same purple Google links, don't keep going without help from your team. If you're on a team project, it's not just your own time you're using. You need to consider the overall goals of the project.  

## 2. Explain the problem

Define where you're at in the process, and where you'd like to be. This might mean describing anything from the stack you're working with, down to the desired outcome of a function you've been trying to write. 

## 3. Explain what you've tried

Think of it like filing a Github issue. Explain what your teammate can do to replicate the problem. Otherwise, the problem won't have context in their minds, and they won't know how to help.


## Example 

Here's a template you can use if you'd like an example of how to ask for help:


```
Hi (teammate),
I've been working with x tools, with the goal of y.
I need help with z. 

I have tried this tutorial (link here), 
as well as following this example (link here). 
These are the results, which give an error/ don't match our goal.  

You can clone this repo and run (commands here) 
to see the issue I'm running into firsthand. 

Do you have input for me? 
```

Good luck!
Making the Switch...
Published: 2021-11-19 14:17:51

At the start of my tech career, if you would have told me I'll be in a coding bootcamp in a few years, I would have thought you were crazy. Why? I believed it was extremely out of reach.
    Most colleagues, friends, and professionals I know that changed careers in IT, have switched from Software Engineering to Network Engineering. Usually citing plainness, and tediousness of coding as the main reasons for their decision.
   I started my career working in Helpdesk support. As the company was small, after a short time, I touched all levels of Networking, from installing apps, to using heat maps, and setting up Networks from the bottom up. I enjoyed the challenge of building out a network from scratch. More than that, when it aligned with what the client needs were(I'm looking at you, bandwidth), that generally made me happy. ![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/delx4lm7b3t90gl9cof8.png)*Source:https://community.fs.com/blog/tcpip-vs-osi-whats-the-difference-between-the-two-models.html*

   After working in Helpdesk for a few years, I moved into more of a hybrid role, splitting onsite, remote, and managerial work. From here on, I worked with various departments, assisting with NOC, Escalation, and the Solution teams. I think this is where I became interested in programming. It was the only department I didn't directly work with, but collaborated a few times and my interest was piqued.
   I also learned a valuable lesson during this period. Why I enjoyed Networking, had nothing to do with Networking, and more so, who I was as a person. As the company grew, I realized the values I held, were no longer applicable.![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1xfzyhci73faib6p0ywa.JPG)
  I did a few free coding courses, (CodeAcademy, Solo learn, among others..) but was very hesitant about taking it a step further. I was comfortable, complacent, and it wasn't a decision I could just make on a whim. 
  The longer I fretted over this, the unhappier I was. So...I just moved. Once I made that decision, a weight was lifted off my shoulders, and out my pockets, but I was satisfied with my decision.
   After a few months into the bootcamp, I believe I made the right decision. Although, this is not easy, by any means, I am moving forward, learning new things everyday.  I do agree, some of what I've learned has been tedious as it's been daunting, though this has been the most creative freedom I've had in a long time.

*Cover Source:https://www.nytimes.com/2020/07/01/technology/personaltech/make-your-tech-last-longer.html*
How to destructure object and make alias for keys name
Tags: javascript
Published: 2021-11-19 14:16:03

Let say you have object that look like this:

```js
const userData={firstName:'John',lastName:'Doe',country:'Ireland'}
```

Then you want to destructure this object and change `country` key name with `nationality`, here how to do that

```js
let {firstName,lastName,country:nationality} = userData
    /*
        firstName
        'John'
        lastName
        'Doe'
        country
        Uncaught ReferenceError: country is not defined 
--> because we don't declare country variable
        nationality
        'Ireland'
    */

```
Top Tips To Get Hired By Big Tech Companies
Published: 2021-11-19 14:08:38

Getting a degree in computer science or engineering is never an assurance you are going to be employed. It is just a step ahead over a self-taught programmer or Bootcamp person🤣🤣. The IT industry is changing, today you don’t need even that degree to work with Google, Facebook etc.

You just have to gain hands-on –experience using a variety of technologies. If you want to major in web development, dig deep to know how those browsers transform your code into a real product. Gain knowledge in programming languages, databases, workflow tools, and libraries. Let’s narrow down the best tips:

Grasp the Key concept while in institution
If you are taking computer science or any IT field as a four-year degree course, don’t rely on class education alone. Technology is growing at a terrific speed. Get general knowledge of how compilers work. Play around with the hardware and software to understand their relationship. Boot camp might sound best, but you have to take your time and revisit some CS areas. Peruse through a variety of programs to learn more than what you gain in school.

Gain tech skills that your dream company uses
The good thing about working for a big company, you will always get a job with any tool you are learning. If you are good at python, you will work with a team of pythoneers. But if you are going to join a minor startup, you must diversify your skills. Learn the data structure and algorithms, then understand how time and space complexity works. This is more than just writing programs. You have to know how to scale down applications. Let the software perform the required job with as little time and memory as possible.

Online certification might be an added advantage. LinkedIn, freecodecamp, Udacity,udemy, etc. have a hundred tech certificates. They might give you an edge over others while applying for the same role.

Get some experience
This is where the hands-on experience gets to climax. Anything you learn must be able to translate into something useful and essential. Work on a variety of projects and push them on GitHub. Contribute to open-source projects and learn to read other people’s code. It will motivate you to work hard. But don’t scare away when you find complex code written by your peers, your time will come. Focus on your work and be consistent. Open your mind to be able to absorb more knowledge.

Soft skills are essential
Every industry demands better communication among individuals. You are going to work with a team of new people. There is sharing of ideas and solving problems. You must learn the soft skills to collaborate with others well. If you are a technical lead, it means you will present the software with the document to the hired non-technical individuals.

Bonus: Programming! Coding! Solving Problems!

Read the blog and watch podcasts to be updated on the trend. Your machine should sit next to you. Make sure you write some code daily to stay focused. Coding interviews are indeed very challenging, but the job comes with a reward. Hard work and sacrifice.
Day 42 of 100 Days of Code & Scrum: Footer, SCSS Debugging, and Breakpoints
Tags: 100daysofcode, beginners, javascript, programming
Published: 2021-11-19 13:53:47

Hello there, everyone!

Today, I almost finished the skeleton layout for my entire homepage. Now, I just need to design the homepage and look for images to use for styling. I've made a decent amount of progress so far, so I'm fairly pleased.

Anyway, let's move on to my daily report!

## Yesterday

I finished most of the contact form's skeleton, added state management, and validation.

## Today

Here are the things I learned and worked on today:

### Next.js

- fixed bugs on displaying error messages for the input fields.
- fixed broken CSS styling and classNames.
- add footer skeleton layout.
- add styling for different breakpoints.

### Scrum

- I did some practice flashcards for Scrum.
- reviewed some of the things I've learned before.

Have a good day, everyone! Thank you for reading.

![Thank You Banner](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x9ayfxxxaz2g2hfcqbsk.png)

### Resources/Recommended Readings

- [Official Next.js tutorial](https://nextjs.org/learn/basics/create-nextjs-app?utm_source=next-site&utm_medium=nav-cta&utm_campaign=next-website)
- [Scrum Master learning pathway | Scrum.org](https://www.scrum.org/pathway/scrum-master)
- [The 2020 Scrum Guide](https://scrumguides.org/scrum-guide.html)
- [Mikhail Lapshin's Scrum Quizzes](https://mlapshin.com/index.php/scrum-quizzes/)

### DISCLAIMER

**This is not a guide**, it is just me sharing my experiences and learnings. This post only expresses my thoughts and opinions (based on my limited knowledge) and is in no way a substitute for actual references. If I ever make a mistake or if you disagree, I would appreciate corrections in the comments!

<hr />

### Other Media

Feel free to reach out to me in other media!

<span><a target="_blank" href="https://www.rammina.com/"><img src="https://res.cloudinary.com/rammina/image/upload/v1638444046/rammina-button-128_x9ginu.png" alt="Rammina Logo" width="128" height="50"/></a></span>

<span><a target="_blank" href="https://twitter.com/RamminaR"><img src="https://res.cloudinary.com/rammina/image/upload/v1636792959/twitter-logo_laoyfu_pdbagm.png" alt="Twitter logo" width="128" height="50"/></a></span>

<span><a target="_blank" href="https://github.com/Rammina"><img src="https://res.cloudinary.com/rammina/image/upload/v1636795051/GitHub-Emblem2_epcp8r.png" alt="Github logo" width="128" height="50"/></a></span>
WordPress Starter Theme für Kirchen und Pfarren
Tags: wordpress, kadencestartertempla, kadencewp, wordpressthemes
Published: 2021-11-19 13:53:38

---
title: WordPress Starter Theme für Kirchen und Pfarren
published: true
date: 2021-11-19 13:26:07 UTC
tags: WordPress,kadencestartertempla,KadenceWP,WordPressThemes
canonical_url: https://bloggerpilot.com/kadence-church/
---

![Kadence Starter Template Church](https://bloggerpilot.com/wp-content/uploads/2021/11/kadence-church.png)

Du willst also eine Gemeinde gründen? Vielleicht träumst du davon, eine Kirche zu gründen, und du willst wissen, wie du damit anfangen kannst. Nun, ich habe tolle Neuigkeiten für dich. Es war noch nie so einfach. Es gibt ein WordPress-Theme, das speziell für Kirchen und Ministerien entwickelt wurde, das Kadence Church Theme.

Der Original-Artikel erschien auf [WordPress Starter Theme für Kirchen und Pfarren](https://bloggerpilot.com/kadence-church/).

Wie wichtig es ist, einen Blog zu starten, wurde mir erst klar, als ich mit dem Bloggen begann. Ich arbeite gerade an meiner dritten Website und wusste damals noch nicht, dass ich mit einem Blog meine Meinungen, Geschichten und Erfahrungen teilen kann.