Examples
Same name in other branches
- 3.x examples.module \examples
- 4.0.x examples.module \examples
Well-documented API examples for a broad range of Drupal 7 core functionality.
Developers can learn how to use a particular API quickly by experimenting with the examples, and adapt them for their own use.
Download the Examples for Developers Project (and participate with submissions, bug reports, patches, and documentation) at http://drupal.org/project/examples
File
-
./
examples.module, line 14
Functions
Title Sort descending | File name | Summary |
---|---|---|
examples_help | ./ |
Implements hook_help(). |
Sub-Topics
Title Sort descending | File name | Summary |
---|---|---|
Example: Action | action_example/ |
Creating actions in Drupal 7 |
Example: AJAX | ajax_example/ |
These examples show basic AJAX concepts. |
Example: AJAX Graceful Degradation | ajax_example/ |
These examples show AJAX with graceful degradation when Javascript is not available. |
Example: Batch API | batch_example/ |
Outlines how a module can use the Batch API. |
Example: Block | block_example/ |
Demonstrates code creation of blocks. |
Example: Cache API | cache_example/ |
Outlines how a module can use the Cache API. |
Example: Contextual Links | contextual_links_example/ |
Example of implementing contextual links. |
Example: Cron | cron_example/ |
Example using Cron API, including hook_cron() and hook_cron_queue_info(). |
Example: Database (DBTNG) | dbtng_example/ |
Database examples, including DBTNG. |
Example: Email | email_example/ |
Example of how to use Drupal's mail API. |
Example: Entity | entity_example/ |
Example creating a core Entity API entity. |
Example: Field Permissions | field_permission_example/ |
Example using permissions on a Field API field. |
Example: Field Types API | field_example/ |
Examples using Field Types API. |
Example: Filter | filter_example/ |
Demonstrates the creation of filters. |
Example: Form API | form_example/ |
Examples demonstrating the Drupal Form API. |
Example: Image | image_example/ |
Demonstrates the basic use of image API. |
Example: JavaScript | js_example/ |
Examples using Drupal 7's built-in JavaScript. |
Example: Menu | menu_example/ |
Demonstrates uses of the Menu APIs in Drupal. |
Example: Node | node_example/ |
Example defining a node type in code. |
Example: Node Access | node_access_example/ |
Demonstrates node access. |
Example: NodeAPI | nodeapi_example/ |
Example using NodeAPI. |
Example: Page | page_example/ |
This example demonstrates how a module can display a page at a given URL. |
Example: Pager | pager_example/ |
Example of a results pager. |
Example: Queue | queue_example/ |
Demonstrating the Queue API |
Example: RDF | rdf_example/ |
Example RDF Mapping. |
Example: Render | render_example/ |
Demonstrate how render arrays are arranged and how they can be altered. This alters blocks and the page to show the actual render array that is being used to create each item. |
Example: Simpletest | simpletest_example/ |
An example of simpletest tests to accompany the tutorial at http://drupal.org/node/890654. |
Example: Tabledrag | tabledrag_example/ |
Example of draggable table rows. |
Example: Tablesort | tablesort_example/ |
Example of a sortable table display. |
Example: Theming | theming_example/ |
Example of Drupal theming. |
Example: Token API | token_example/ |
Examples using the Token API. |
Example: Trigger | trigger_example/ |
Trigger definition example module. |
Example: Vertical Tabs | vertical_tabs_example/ |
Demonstrates the vertical tabs functionality provided by Drupal 7. |
Example: XML-RPC | xmlrpc_example/ |
Demonstration of XML-RPC in Drupal 7. |