Changeset 5915 for trunk/calendar
- Timestamp:
- 04/11/12 12:25:36 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/calendar/csv_import.php
r5912 r5915 373 373 foreach($trans[$csv_idx] as $pattern => $replace) 374 374 { 375 if (preg_match( (string) '/'.$pattern.'/',$val))375 if (preg_match("/$pattern/",$val)) 376 376 { 377 377 // echo "<p>csv_idx='$csv_idx',info='$info',trans_csv=".print_r($trans_csv).",ereg_replace('$pattern','$replace','$val') = "; … … 380 380 381 381 $reg = $CPreReg.'([a-zA-Z_0-9]+)'.$CPosReg; 382 while (preg_match( '/'.$reg.'/',$val,$vars))382 while (preg_match("/$reg/",$val,$vars)) 383 383 { // expand all CSV fields 384 384 $val = str_replace($CPre.$vars[1].$CPos,$val[0] == '@' ? "'".addslashes($fields[array_search($vars[1],$csv_fields)])."'" : $fields[array_search($vars[1],$csv_fields)],$val);
Note: See TracChangeset
for help on using the changeset viewer.