Карта сайта Интеллектуальная поисковая системаДобавить свою ссылку по ключевому запросуПоисковая система v3.kz поможет ускорить индексацию вашего сайта выводит в Топ |
|
I noticed when we enable the drupal default caching mechanism json output also gets cached and behave weirdly if we clear browser cache. drupal_json_output($var = NULL). Returns data in JSON format. 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() - Drupal6. Drupal_json_output() - Drupal7. FAQ. Как проще всего реализовать аякс с выдачей JSON в своем модуле на друпале? You need to add. Module_invoke_all(exit); To the template-file, immediately prior to the exit or die statement. This will trigger the boost-modules code that stores the generated output in a cache-file. Заметки о Друпале. Drupal - пожалуй лучший конструктор сайтов. It’s a simple page that in its rendering logic makes an external API call (to a dummy JSON endpoint) and caches its results. В Drupal 7, в калбаках меню или любых других функциях, которые что-то выводят на экран, принято возвращать "рендер массив". Drupal internal caching can be integrated with a preferred caching backend instead of default cache DB table. Old cache files are not deleted immediately when the lookup variable is emptied, but are deleted after a set period by drupal_delete_file_if_stale(). Информация взята v3.kz |
загрузка...
|