You are here

function _sheetnode_html_import_value in Sheetnode 7

Same name and namespace in other branches
  1. 6 modules/sheetnode_html/sheetnode_html.module \_sheetnode_html_import_value()
  2. 7.2 modules/sheetnode_html/sheetnode_html.module \_sheetnode_html_import_value()

Utility function to import a cell value.

1 call to _sheetnode_html_import_value()
sheetnode_html_import_table in modules/sheetnode_html/sheetnode_html.module
API function to import a single table.

File

modules/sheetnode_html/sheetnode_html.module, line 161
Module file for the sheetnode_html module. This extends sheetnodes to enable inmporting of html to sheetnodes.

Code

function _sheetnode_html_import_value($val) {
  $val = str_replace(html_entity_decode(' ', ENT_COMPAT, 'UTF-8'), ' ', $val);
  $val = trim($val);
  $num = parse_formatted_number($val);
  return $num === FALSE ? $val : $num;
}