The module development and code questions forum is intended to aid those who are developing modules or writing code for Drupal.
Please note that this forum is also not intended for "Is there a module that does..." or "I need help with module x..." questions. It's also not a place to ask developers to write your code for you. Please respect this.
Please do not post general discussions intended to target module developers. If the question you have isn't specifically related to writing a drupal module, please post it in a more appropriate forum.
If you you have drupal installed already and are seeking a module that does a specific task, have a question about a specific module and what it does or if it will fit your use case, please place your questions in the Post installation forum.
If you have a problem or question about a specific module, you should create an issue in the module's issue queue (after checking for an existing issue first).
If you don't have drupal installed yet, please place your questions in the Before you start forum.
I’m working on my first complex module. So far things seem to have been quite easy to get answers to (well, not real easy), and now I am working on a module that will be far more complex than the others, and I am going to need lots of help along the way.
For starters, the module creates three nodes. In the first node the form needs to upload an image. Rather than upload the image upon selection, the image will only be uploaded when the form is submitted.
I made a page with a form (my_form), when the "submit" button is pressed, a function save the data in the database (save_function). The date are then used by an other page (display_plage) which display the data in a specific maner.
I would like to improve my_form by adding a "preview" button which will allow the user to see his data as they will be displaied.
I'm learning to make custom modules in Drupal 7 and I've managed to put some code together that (almost) does what I want. When I edit the existing node with the image field, it will not save my changes to my custom fields. Any idea what I'm doing wrong? Do I need to include another function?