For example in Cms a multi record section will have 2 text fields:
i want the permalink field to automatically generate this based on the content of those fields in that order.
So the above record would auto create the permalink
I know its possible to define a field as the one used for the permalink but is it possible to dynamically use 2 fields in order?
Hmm, it doesn't do that by default. But it does support multiple fields like this :
$GLOBALS['PERMALINKS']['autopopulate_fromFields'] = array('client project');
So you could try editing the _permalink_generate_getInputText() function in permalinks.php:
And replace ' ' with '/' in these two lines:
$inputText .= $recordOrRequest[$field] . ' '; // trailing space in case more fields are added
$inputText = rtrim($inputText, ' '); // remove trailing spaces
Let me know if that works for you.
Dave Edis - Senior Developer