Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@somatonic
Last active January 2, 2016 15:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save somatonic/8323844 to your computer and use it in GitHub Desktop.
Save somatonic/8323844 to your computer and use it in GitHub Desktop.
get field settings via API
<?php
// via field settings
$field = $fields->get("title");
echo "width:" . $field->columnWidth;
// via template context
$tpl = $templates->get("basic-page");
$field = $tpl->fieldgroup->getField("title", true);
echo "width:" . $field->columnWidth;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment