My php file has some defined variables with $downtime_hosts, what i need is a single command to just find and replace entire $downtime_hosts = 8;
into $downtime_hosts = 15;
and without affecting the other $downtime_hosts
used several time within the file.
here my number 8,15,16 may change anytime, what i need is find the line beginning with$downtime_hosts = anyinteger
and simply replace with my new line $downtime_hosts = newinteger . please note anyinteger / newinteger=2,3,4,15
or any
$downtime_hosts = 8;
$total_hosts = $all_hosts - $downtime_hosts;
if ($host_up == $total_hosts )
Hosts under downtime $downtime_hosts
`
Any inputs are really welcomed !