承接 alexoliverwd/dotenv-loader 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

alexoliverwd/dotenv-loader

最新稳定版本:v1.2.0

Composer 安装命令:

composer require alexoliverwd/dotenv-loader

包简介

Load environment variables into a PHP application

README 文档

README

PHPUnit Latest Stable Version License

Environment Variables Loader

Load configuration variables into your PHP application's global namespace from an .env file for flexible management across different environments.

Installation

composer require alexoliverwd/dotenv-loader

Basic Usage

\AOWD\envLoader\ResourceLoader::applyEnvironmentVariables(__DIR__ . '/.env');

Public Class Methods

loadResource

loadResource(
	string $resource_location
): array

The loadResource method retrieves key-value pairs from a configuration file, like /home/.env, providing a structured and flexible way to manage application settings across various environments.

applyEnvironmentVariables

applyEnvironmentVariables(
	string $resource_location
): void

The applyEnvironmentVariables method imports key-value pairs from a configuration file, like /home/.env, directly into PHP's global namespace, making them accessible throughout your application using the built-in $_ENV superglobal variable.

encryptEnvironmentVariables

encryptEnvironmentVariables(
	array $environment_variables,
	string $public_key_content
): array

The encryptEnvironmentVariables method encrypts the values of the key, value pair array using a provided public key.

decryptEnvironmentVariables

decryptEnvironmentVariables(
	array $environment_variables,
	string $private_key_content
): array

The decryptEnvironmentVariables method decrypts the values of the key, value pair array using a provided private key.

统计信息

  • 总下载量: 1.28k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 2
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-05-22

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固