I'm trying to built a fully dynamic website. My client made a lot of websites with the same layout but with different content, for me the job to make it easy update-able. This means I have to adjust a part of my .htaccess file by editing it with a php script.
The problem is that I cannot find a solution for the following problem:
.htaccess has the following lines:
The lines between the #O UD and #C UD lines should be updated. I thought I'd use the file_get_contents function, search and replace the lines with preg_replace and then save the file.
I've searched a lot but cannot find a working answer. What arguments do I use in the preg_replace function?
Thanks in advance,