PHP Classes

File: config/select_encryption.php

Recommend this page to a friend!
  Classes of jon   PHP Folder Image Gallery   config/select_encryption.php   Download  
File: config/select_encryption.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: PHP Folder Image Gallery
Display images and folders inside a directory
Author: By
Last change:
Date: 2 years ago
Size: 446 bytes
 

Contents

Class file image Download
<?php

//checks ajax post value whether http or https
if($_POST['value'] === 'http')
{
   
$value = '1;'; //http
}
else
{
   
$value = '2;'; //https
}

//write to "config.cfg" file
$filename = $_SESSION['drive_site_dir'] . 'config.cfg';
$line_i_am_looking_for = 0;
$lines = file( $filename , FILE_IGNORE_NEW_LINES );
$lines[$line_i_am_looking_for] = $value;
file_put_contents( $filename , implode( "\n", $lines ) );






?>