Skip to content

Instantly share code, notes, and snippets.

@giltotherescue
Created January 28, 2013 19:18
Show Gist options
  • Save giltotherescue/4658216 to your computer and use it in GitHub Desktop.
Save giltotherescue/4658216 to your computer and use it in GitHub Desktop.
Replace line 448 and below with this code if you want to rename the Source and Original stacks based on the title of the parent postcard.
<?
} else if ($node['parent']->getProperty('type') == 'meta') {
if (in_array($node['parent']->getProperty('parent'), array('Source', 'Original'))) {
$parent_mod = Module::getModuleById($node['adjective']->getProperty('title'));
$new_stack['title'] = escapeForDisplay($parent_mod->lens_module_title);
}
$new_stack['url'] = implode('/', array(
'stacks',
strtolower($this->getNoun(true, $node['parent']->getProperty('parent'))),
urlencode(strtolower($node['parent']->getProperty('title'))),
slug($node['adjective']->getProperty('title'))
));
} else {
throw new Exception('Unexpected node type');
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment