Home Forums Newsletter Plugin Support [PATCH] Advanced Import: support Mac line endings

Viewing 1 post (of 1 total)
  • Author
    Posts
  • #282270
    Anonymous
    Participant

    When working with Filemaker on a Mac, the exported list of email addresses uses CR (Carriage Return, \r) line endings.

    Currently, the Advanced Import plugin for the newsletter plugin does not detect Mac line endings correctly.
    It only detects DOS and Unix line endings (NL, Newline, \n) line endings correctly.

    The fix is to replace the $handle = fopen($this->get_filename(), 'r'); calls in csv-map.php and plugin.php with:

    $original = ini_get("auto_detect_line_endings");
    ini_set("auto_detect_line_endings", true);
    $handle = fopen($this->get_filename(), 'r');
    ini_set("auto_detect_line_endings", $original);
    

    Could you please include this fix in the next version of the Advanced Import plugin?

    Thanks

Viewing 1 post (of 1 total)
  • You must be logged in to reply to this topic.