This forum is for module development and code related questions, not general module support. For general support, use the Post installation forum.

Can I submit my form value to a certain page?

I mean in the _submit function, I do not run a sql query but send the values to a page. How to do it?

Access module

I have a very stupid question. The node_access table has a field "realm" that determines what access method to use.

Why does Drupal have difficulties in dealing with different access modules? It should only use the module that belongs to the specified realm. Theoretically, one could have 200 different access systems. But why only theoretically?

Thanks for your enlightenment.

I want view [poll module ] on popup window

Hi all. Help me.
Sry My english :)

I want [ poll module ] view on popup window. No blocks.

Thanks all ;)

drupal only supports stdClass objects?

I've been beating my head on the wall for two days on this one... and could reall use some clarification and hopefully justification on Classes used in modules.

PHP allows you to define a class like

class myCustomClass{
    var foo = 'bar';
    var pea = 'nut';

    function coolClassFunc(){
        //do some cool stuff
    }
}

however, while drupal doesn't stop you from making a new instance of myCustomClass it does seem to block the instance from being in the global scope.

so if I had:

$objA = new myCustomClass();
$objB = new stdClass();

function someIncludedFunc(){
    global $objA, $objB;
    echo "objA is ".gettype($objA);
    echo "objB is ".gettype($objB);
}

this would spit out:
"objA is NULL"
"objB is Object"

if you ran this code independant of a drupal install both objects would be seen as objects by the included function... but when executed as a module inside a drupal enviroment, only the stdClass carries through to the global as shown in the example.

can anyone confirm this?
can anyone tell me why?

thanks all very much for the repsonses.

Book Module Question

Hey guys,

I'm still only a new drupal user but i was wondering if it was possible to add new fields to the existing content type of the book module.

So book entries are set out in my own desired format?

Such as the fields u can create with the cck module? OR is it possible to create a new content type with the cck module that is in fact a book entry? and not just a new content type?

i'm sorry if these questions are stupid, i still have a lot to understand.

Thanks

Chris

Problem about hidden type in Drupal form API

I have create a form by using form API and there is a hidden type element. I have to submit buttons in the form, one is 'save' and another is 'test'. When clicking 'test' I want change the hidden element value and submit to the form page, just look like nothing changed in the form page but just the hidden value changed. How to change the hidden value?
In the submit function I try to change it by using $form_values['xxxx'] = 'xxxxxxx'; but it does not work...

Pages

Subscribe with RSS Subscribe to RSS - Module development and code questions