I am working on an innovative drupal front end and I need to hook drupal into place to provide me just the content/body of nodes in the form json.
So when a user clicks on the menu, the page does not refresh but grabs the body of the node, so that I can use to re-populate in a sliding container.
How do I, in drupal 7, get a json output of the nodes. I've tried several techniques but I am not having any luck.
"The JSON server module gives you JSON output of nodes. If you want more custom JSON, you can use hook_menu() to create a new menu callback (basically a URL path pointed to a function) and then use drupal_json() within that callback to send the output as JSON rather than the default HTML."
http://stackoverflow.com/questions/3636463/drupal-create-a-page-that-out...
http://api.drupal.org/api/drupal/includes--common.inc/function/drupal_js...
Comments
I tried this, but it looks
I tried this, but it looks like its more suited to drupal 5?
http://drupal.org/node/174008
How does one create the menu callback for this to work?
http://drupal4hu.com/node/90
//_ on navigation $('#nav
I had something like this - where I need to get the contents of the node using something like the above.
Would something like this
Would something like this work?
http://eosrei.net/articles/2011/03/embedding-drupal-7-search-form-anothe...
This is what I am looking
This is what I am looking for, but using Drupal 7
http://drupal.org/node/174008#comment-4519778
The first attempt using
The first attempt using hook_menu
references:
http://api.drupal.org/api/drupal/modules--system--system.api.php/functio...
http://drupal.org/node/109153
http://api.drupal.org/api/drupal/includes--common.inc/function/drupal_js...
http://api.drupal.org/api/drupal/modules--system--system.api.php/functio...
is it possible to create a custom module like this?
Has anyone got a solution for
Has anyone got a solution for this? - Is it possible to create a view page that formats the content in json format?
I'm trying to do the same thing...
anyone having any luck here?
pulling json from a view in D7. it is doable in D6 with views_datasource.
but that is all I can find.
Doing Native iPHONE, ANDROID, Titanium, node.js and DRUPAL. as a contractor.
You can find an unofficial D7
You can find an unofficial D7 port of views_datasource at this address: http://windmill.sk/project/module/views_datasource
I've used it in a recent project and the json module has worked well for what I needed. There is also a specific thread #981810: views_datasource module Drupal 7 port.
Hope this help you.