I need to pre-set some values on a form. I have a custom module that sets a menu() link to a custom function to do this. It calls node_form() to save me the work of maintaining the form definition in more than one place. By using node_form() I can not pass parameters to form(), and default form action becomes /mymodule/myfunc/myparam, which does not handle post data.
I am solving this by modifying $_SERVER["REQUEST_URI"] which works, but in my opinion is an ugly hack that I do not like.
Can anyone suggest a better way of setting form "action" parameter?
-I'd like to set up a block that displayed the top ten referrers to my site; can anyone recommend a starting place for something like this? Any guidance you can offer would be most welcome.
I just wrote a module that let's me put and present points on geographic (or any other) maps. For the luck of a better name, it's called "geourl", and a demonstration can be seen on my home page: http://www.havlik.org/geourl/maps/AT
The module is really at "quick & dirty" stage now, but it works for me. Question: is anyone else interested in this kind of stuff?
How can i use the '%' multiple character wildcard in a query when the '%' is used to specify the arguments in that query ?
If I use it, it casts the error of too few args for the sprintf in db_query().
Replacing the '%' with the right number of its single character equivalent '_' does the job for my case.
But someday someone (me?) will need multiple character wildcard in his queries.
i'm trying to learn how to write a drupal module, that puts a block at the side. i read the "Creating modules: post 4.3.1" in the module developer's guide and tried to do the same. i can select the module in the modules section, but the block does not appear in the blocks section and i also can not see any permission. this is even if i copy and paste the onthisdate module from the module developer's guide.