User Tools

Site Tools


uphp:functions:ini_put_array

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
uphp:functions:ini_put_array [2017/04/13 10:58]
jeff created
uphp:functions:ini_put_array [2021/09/13 05:57] (current)
Line 7: Line 7:
 ====Description==== ====Description====
  
-<well size="sm"> +<well size="sm"><html>
-<html>+
 <span style="font-size:125%"> <span style="font-size:125%">
-<span style="color:black"> +<span style="color:black">ini_put_array (
-</html> +
-[[ini_put_array]] ( +
-<html>+
 <span style="color:green">string <span style="color:green">string
 <span style="color:blue">$filename<span style="color:black">, <span style="color:blue">$filename<span style="color:black">,
Line 22: Line 18:
 <span style="color:blue">$section <span style="color:blue">$section
 <span style="color:black">] ) <span style="color:black">] )
-</html> +</html></well>
-</well>+
  
-<html>This function writes multiple configuration key/value pairs to an INI file. Values can be written to a single section if the optional <b><span style="color:blue">$section<span style="color:black"></b> is specified (provide a single-dimensional <b><span style="color:green">array<span style="color:black"></b>). Values can be written to one or more sections if <b><span style="color:blue">$section<span style="color:black"></b> is not specified (provide a two-dimensional <b><span style="color:green">array<span style="color:black"></b>).</html>+<html>This function writes multiple configuration key/value pairs to an INI file. Values can be written to a single section if the optional <b><span style="color:blue">section<span style="color:black"></b> is specified (provide a single-dimensional <b><span style="color:green">array<span style="color:black"></b>). Values can be written to one or more sections if <b><span style="color:blue">section<span style="color:black"></b> is not specified (provide a two-dimensional <b><span style="color:green">array<span style="color:black"></b>).</html>
  
-<alert type="warning">If the INI file pre-exists it will be entirely overwritten. Use [[ini_set]] to partially update an existing INI file.</alert>+<alert type="warning">If the INI file already exists it will be entirely overwritten. Use [[ini_set]] to partially update an existing INI file.</alert>
  
 ====Parameters==== ====Parameters====
Line 35: Line 30:
 <html><b><span style="color:blue">$data<span style="color:black"></b>:  <b><span style="color:green">Array<span style="color:black"></b> of key/value elements to write</html> <html><b><span style="color:blue">$data<span style="color:black"></b>:  <b><span style="color:green">Array<span style="color:black"></b> of key/value elements to write</html>
  
-  * <html>If <b><span style="color:blue">$section<span style="color:black"></b> is specified, a single-dimensional <b><span style="color:green">array<span style="color:black"></b> should be provided (to write values only to that section).</html> +  * <html>If <b><span style="color:blue">section<span style="color:black"></b> is specified, a single-dimensional <b><span style="color:green">array<span style="color:black"></b> should be provided (to write values only to one section).</html> 
-  * <html>If <b><span style="color:blue">$section<span style="color:black"></b> is not specified, a two-dimensional <b><span style="color:green">array<span style="color:black"></b> can be provided, where the first dimension contains the sections and the second the key/value pairs (to write values in one or more sections).</html>+  * <html>If <b><span style="color:blue">section<span style="color:black"></b> is not specified, a two-dimensional <b><span style="color:green">array<span style="color:black"></b> can be provided, where the first dimension contains the sections and the second the key/value pairs (to write values in one or more sections).</html>
  
-<html><b><span style="color:blue">$section<span style="color:black"></b>:  Optional, section inside the INI file (provide <b><span style="color:blue">$data<span style="color:black"></b> as a single-dimensional <b><span style="color:green">array<span style="color:black"></b>)</html>+<html><b><span style="color:blue">$section<span style="color:black"></b>:  Optional, name of the section inside the INI file (provide the <b><span style="color:blue">data<span style="color:black"></b> as a single-dimensional <b><span style="color:green">array<span style="color:black"></b>)</html>
  
-====Return Value====+====Return Values====
  
 None None
Line 97: Line 92:
 [[ini_get_array()]] - Get a group of parameters from an INI file as an <html><b><span style="color:green">array<span style="color:black"></b></html> [[ini_get_array()]] - Get a group of parameters from an INI file as an <html><b><span style="color:green">array<span style="color:black"></b></html>
  
-[[ini_set()]] - Write a value to a section in an INI file+[[ini_set()]] - Set a value in an INI file
  
uphp/functions/ini_put_array.1492081132.txt.gz · Last modified: 2021/09/13 05:56 (external edit)