sc_connection_edit("Connetion_Name", $arr_conn)

La conexión editada solo estará disponible en la próxima aplicación.

1º Parameter: Connection name to be edited.

2º Parameter: Array of items containing the connection information to be edited. Check out the indices of the array:

Indice
Description Example
['server'] Database server (host) $arr_conn['server'] = "127.0.0.1"
['user'] Database username $arr_conn['user'] = "root"
['password'] Database password $arr_conn['password'] = "secretpass123"
['database'] Database name used in the connection $arr_conn['database'] = "sc_samples"
['persistent'] Defines if the connection is persistent or not $arr_conn['persistent'] = "Y" / "N"
['encoding'] Configure the connection encoding $arr_conn['encoding'] = "utf8"

Note:Is not required to use all the indices in the array, we can pass only the required ones.

Example:

$arr_conn = array();

$arr_conn['user'] = "admin2";
$arr_conn['password'] = "admin2pass";
$arr_conn['database'] = "sc_samples2";

sc_connection_edit("sc_connection", $arr_conn);