This might be a daft question (that's why I'm here; if I understood things I would not ask the question), but how do I download the page_example module:
http://api.drupal.org/api/drupal/developer--examples--page_example--page...
I'm used to downloading modules as follows:
- Go to http://drupal.org/project/Modules and find the module I want
- Click on the "download" button!
but I've looked there for a module called "page_example" but it isn't there.
Isn't it possible to download the example module? Or do I somehow have to download each file from the above http://api.drupal.org link?
It's all a bit fishy to me!! I'm sure this must seem a really dumb question to those of you who know the answer.
If the answer is, "No, you can't download the page_example" module as if it were a normal module, er, why not?!?
Thanks!
Comments
It's easier than you think
In the page_example module page click on the "View source" link you find under the title and the Drupal version.
The body of the page will then show you the PHP code of the module: copy it (from
to
)
and create the page_example.module file with a standard text editor.
Hope this helps
Thanks
OK, thanks. It seems to me a pity that for the example module I need a different way to load it and try it than the other modules, but hey.
drupalshrek
The other modules are actual
The other modules are actual modules to be used on a site. The module you are looking at is just an example of how to write a module.
Contact me to contract me for D7 -> D10/11 migrations.
Even so, it had me as a
Even so, it had me as a novice baffled for a while, to the point I had to post a forum question.
If the example were actually available as a real downloadable module it would make it easier for people learning to try it out and test and learn.
drupalshrek
copy
Page Example module is
Page Example module is actually contained in the Examples for Developers project. See http://drupal.org/project/examples
So to install and enable it with drush, just do the following: (untested)
Hope that helps!