private function normalizeArrayForNewLines(array $data) {
		foreach($data as $k => $item) {
			if(is_string($item)) {
				$data[$k] = str_replace(["\r\n", "\n\r", "\r"], "\n", $item);
			} elseif(is_array($item)) {
				$data[$k] = $this->normalizeArrayForNewLines($item);
			}
		}
		return $data;
	}
private function normalizeArrayForNewLines(array $data) {
		foreach($data as $k => $item) {
			if(is_string($item)) {
				$data[$k] = str_replace(["\r\n", "\n\r", "\r"], "\n", $item);
			} elseif(is_array($item)) {
				$data[$k] = $this->normalizeArrayForNewLines($item);
			}
		}
		return $data;
	}
private function normalizeArrayForNewLines ( array $ data ) { foreach ( $ data as $ k => $ item ) { if ( is_string ( $ item ) ) { $ data [ $ k ] = str_replace ( [ "\r\n" , "\n\r" , "\r" ] , "\n" , $ item ) ; } elseif ( is_array ( $ item ) ) { $ data [ $ k ] = $ this -> normalizeArrayForNewLines ( $ item ) ; } } return $ data ; }
crutch for linux and windows
crutch for linux and windows