src/wcmf/lib/model/NodeUtil.php
public static function makeNodeUrlsRelative(Node $node, $baseUrl, $recursive=true) {
    // use NodeValueIterator to iterate over all Node values
    // and call the global convert function on each
    $iter = new NodeValueIterator($node, $recursive);
    for($iter->rewind(); $iter->valid(); $iter->next()) {
      self::makeValueUrlsRelative($iter->currentNode(), $iter->key(), $baseUrl);
    }
  }
public static function makeNodeUrlsRelative(Node $node, $baseUrl, $recursive=true) {
    // use NodeValueIterator to iterate over all Node values
    // and call the global convert function on each
    $iter = new NodeValueIterator($node, $recursive);
    for($iter->rewind(); $iter->valid(); $iter->next()) {
      self::makeValueUrlsRelative($iter->currentNode(), $iter->key(), $baseUrl);
    }
  }
public static function makeNodeUrlsRelative ( Node $ node , $ baseUrl , $ recursive = true ) { // use NodeValueIterator to iterate over all Node values // and call the global convert function on each $ iter = new NodeValueIterator ( $ node , $ recursive ) ; for ( $ iter -> rewind ( ) ; $ iter -> valid ( ) ; $ iter -> next ( ) ) { self :: makeValueUrlsRelative ( $ iter -> currentNode ( ) , $ iter -> key ( ) , $ baseUrl ) ; } }
Make all urls matching a given base url in a Node relative.
@param $node Node instance that holds the value
@param $baseUrl The baseUrl to which matching urls will be made relative
@param $recursive Boolean whether to recurse into child Nodes or not (default: true)
Make all urls matching a given base url in a Node relative .