You are here

public function DateIcalIcalcreatorParser::formatText in Date iCal 7.2

Format text fields.

@todo is \n \N handling correct?

File

includes/DateIcalIcalcreatorParser.inc, line 172
Classes implementing Date iCal's iCalcreator-based parser functionality.

Class

DateIcalIcalcreatorParser
@file Classes implementing Date iCal's iCalcreator-based parser functionality.

Code

public function formatText($property_key, $property, DateIcalIcalcreatorComponent $item, FeedsParserResult $result, FeedsSource $source) {
  $context = get_defined_vars();
  $text = $property['value'];
  $text = str_replace(array(
    "\\n",
    "\\N",
  ), "\n", $text);

  // Allow modules to alter the text before it's mapped to the target.
  drupal_alter('date_ical_feeds_object', $text, $context);
  return $text;
}