<?php
require_once( "ini_manager.php" );
function list_entry_values( $ini_path, $key )
{
$iniMANAGER = new ini_manager();
$list_values = $iniMANAGER->list_entry_values( $ini_path, $key ) ;
return $list_values;
}
function list_key_values( $ini_path )
{
$iniMANAGER = new ini_manager();
$list_values = $iniMANAGER->list_key_values( $ini_path ) ;
return $list_values;
}
function find_key( $ini_path, $key )
{
$iniMANAGER = new ini_manager();
$found = $iniMANAGER->find_key( $ini_path, $key ) ;
return $found;
}
function find_entry( $ini_path, $section, $entry )
{
$iniMANAGER = new ini_manager();
$found = $iniMANAGER->find_entry( $ini_path, $section, $entry ) ;
return $found;
}
function add_entry( $ini_path, $section, $entry, $entry_val )
{
$iniMANAGER = new ini_manager();
$iniMANAGER->add_entry( $ini_path, $section, $entry, $entry_val ) ;
}
function show_ini( $ini_path )
{
$iniMANAGER = new ini_manager();
$iniMANAGER->show_ini( $ini_path ) ;
}
function get_params_ini( $section, $entry, $ini_path )
{
$iniMANAGER = new ini_manager();
$entry_val = $iniMANAGER->get_entry( $ini_path, $section, $entry ) ;
return special_chars_out( $entry_val );
}
function set_params_ini( $section, $entry, $entry_val, $ini_path )
{
$iniMANAGER = new ini_manager();
$entry_val = special_chars_in( $entry_val );
$iniMANAGER->add_entry( $ini_path, $section, $entry, $entry_val ) ;
}
function delete_entry_ini( $section, $entry, $ini_path )
{
$iniMANAGER = new ini_manager();
// $iniMANAGER->parse_ini_file( $ini_path ) ;
$iniMANAGER->delete_entry( $ini_path, $section, $entry ) ;
}
function delete_key( $KEYname, $ini_path)
{
$iniMANAGER = new ini_manager();
// $iniMANAGER->parse_ini_file( $ini_path ) ;
$iniMANAGER->delete_key( $ini_path, $KEYname );
}
function delete_all_keys( $ini_path )
{
$iniMANAGER = new ini_manager();
// $iniMANAGER->parse_ini_file( $ini_path ) ;
$iniMANAGER->delete_all_keys( $ini_path );
}
function special_chars_in( $str )
{
$str = str_replace( "'", "\'", $str );
return $str ;
}
function special_chars_out( $str )
{
$str = str_replace( "\'", "'", $str );
return $str ;
}
?>
|