Home > OS >  Bat to modify the ini file or the conf configuration file, such as annotations can't read
Bat to modify the ini file or the conf configuration file, such as annotations can't read

Time:10-05

@ echo off
CD % ~ dp0
The set of aa=% ~ dp0
Aa: set bb=% \ %=/
(for/f "delims=" % % a in (PHP/PHP ini) do (
Set "STR=% % a"
Setlocal enabledelayedexpansion
Set "STR=! Bb: STR: D:/yzinfo=% ~ 0, 1%!"
Echo,! STR!
Endlocal
)) & gt;" Setup3. TMP "
Move/y "setup3. TMP" "PHP/PHP ini"
Want to PHP + mysql + Apache packaged into an installation package, need to call the script when installed to modify the configuration file path, but found that the above writing, replace PHP. Ini configuration path, after replacing the original PHP. The annotation in the ini all have no, the configuration of the Apache HTTPD. Conf all didn't, similarly also comments, and newlines consult everybody a great god, and keep the same should be how to write these comments, and newlines?
The original PHP. Ini file screenshot
Performed after replacement screenshot
  • Related