All pastes #329693 Raw Edit

Untitled

public php v1 · immutable
#329693 ·published 2007-01-26 23:35 UTC
rendered paste body
$rule->entire_match= array_shift( $pattern_matches ); // The entire matched string is returned at index 0$rule->named_arg_values= array_combine($rule->named_args, $pattern_matches);if(	strlen($this->action) > 3 && 	$this->action{0} == '{' && 	$this->action{1} == '$' && 	$this->action{strlen($this->action)} == '}') {	$subaction = trim($this->action, '{$}');	if( isset( $rule->named_arg_values[ $subaction ] ) ) {		$this->action = $rule->named_arg_values[ $subaction ];	}}// or$rule->entire_match= array_shift( $pattern_matches ); // The entire matched string is returned at index 0$rule->named_arg_values= array_combine($rule->named_args, $pattern_matches);if (preg_match("/^\{\$(\w)+\}$/", $rule->action, $matches))  $rule->action= $matches[0];