I installed DrupalGap. Everything works fine so far, except that the node body is not displayed. I have none of the mentioned interfering modules installed. I also tried with a fresh Drupal 7 installation in a new test environment with the same result.

I ask for advice or hints.

Note: values are handed over. I can display the body instead of the title. But after clicking a node title, in the sub sequent page only the titel and the comments are shown.

Watchdog log

Additional information: the edit mode of a node shows the html content. Only the view does not show the content (body)

10th of Jan 2020: I made a clean Drupal 7.69 installation with minimum modules (in order to exclude module interferences) with DrupalGap 7.x-1.17 on my localhost. Same effect - not showing the node body in View mode. I wonder what configuration the DrupalGap demo does have? There it works.

  • Clear Drupal's cache. I don't know about DrupalGap, but in vanilla Drupal "Main Page Content" block "contains" the fields for a node. It's usually in Admin-Structure-Blocks, "Content" region. It is $variables['content'] during node processing, and $content in template files. Use Devel and hook_preprocess_node in custom module to see the body: dpm($variables['content']['body'][0]['#markup']); Enable Theme debug mode, look at the page source and the node template filename is under CALL: theme('node') Look in it for print render($content); You can also add dpm($content'); there Jan 6, 2020 at 21:26
  • Also, check Drupal watchdog and the web server error logs to see if they have entries that explain what is happening. Jan 7, 2020 at 3:58
  • Clearing cache did not make a change. In watchdog protocols is written 'page not found' after I tried to open a node's content. The message seems to be incomplete.
    – xandi
    Jan 7, 2020 at 10:26
  • Actually the error message is complete. My guess is it has to do with the DrupalGap SDK and/or a DrupalGap Module. One or more aren't installed or are broken somehow. The error indicates DrupalGap is trying to build the path to a JavaScript file for one of its modules, but what it has for the module's sub-directory and JavaScript filename are empty: path/to/drupalgap_sdk_dir/mobile-application/app/modules/[MODULE_DIRECTORY]/[JAVASCRIPT_FILE].js?[MODULE_PARAM]=157... Try looking at the DrupalGap config page. Jan 7, 2020 at 14:29
  • Also, the docs for DrupalGap Modules may be helpful. Jan 7, 2020 at 14:37

1 Answer 1


The problem was that the Body field was not added to the DrupalGap Display Mode for the content type:

By default, there are no fields displayed using the DrupalGap Display Mode. We need to specifiy which fields, labels and formats will be used when our nodes are displayed in the mobile app. Do this for each content type.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.