adding panel to select field in content type I created a content type for a new block. One of the fields in this needs to pull in category information from a magento site. I have code to get all of the categories and display them in a drop-down working in a panel template. 
The only step I am missing is know how to access this as a field in my new content type. I have read some articles about using something called hooks for this process but I'm not fully sure about how they work. 
Is a hook the best method and if so what exactly does it involve programmatically?
As mentioned in one of the comments I used the hook_form_alter but instead of pulling in the panel I just created another function to get the information and used that as the options for my select.

  function gacms_magecp_content_type_edit_form($form, &amp;$form_state) {

   $conf = $form_state['conf'];
   $categories = gacms_magecp_categories();

    $form['magecp'] = array(
     '#type' =&gt; 'select',
     '#options' =&gt; $categories,
     '#title' =&gt; t('Mage Category Product'),
     '#default_value' =&gt; isset($conf['magecp'])?$conf['magecp']:'',
     '#format' =&gt; isset($conf['format'])?$conf['format']:'full_html',
    );

    return $form;
  }

   function gacms_magecp_categories(){
    db_set_active('magento');

    $result = db_query("SELECT entity_id, name FROM catalog_category_flat_store_1");
        while ($row = $result-&gt;fetchAssoc()) {
           $content[$row['entity_id']]= $row['name'];
        }
        db_set_active();
        return $content;
    }