Create the URL for one of our standard AJAX forms based upon known information about the form.
function views_ui_build_form_url($form_state) {
$ajax = empty($form_state['ajax']) ? 'nojs' : 'ajax';
$name = $form_state['view']
->id();
$url = "admin/structure/views/{$ajax}/{$form_state['form_key']}/{$name}/{$form_state['display_id']}";
if (isset($form_state['type'])) {
$url .= '/' . $form_state['type'];
}
if (isset($form_state['id'])) {
$url .= '/' . $form_state['id'];
}
return $url;
}