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

Help Me

I Am building a article website..is there to catagorise..the article under diffrent topic..Is there any way PLz help...

module setting form does not show updated values

Hi Guys,

I am working on a new module and have created its setting link(mean ?q=admin/settings/print_partners), When i submit its setting form, it does not show the updated values in the fields instead show the default values.

How it will show the updated fields in the setting form after submission.

THe code is.
<?php
function print_partners_menu($may_cache) {
$items = array();

if (!$may_cache) {
$items[] = array('title' => t('Printing Partners'),
'path' => 'admin/settings/print_partners',
'callback' => 'drupal_get_form',
'callback arguments' => array('print_partners_admin_settings'),
'access' => user_access('administer site configuration'),
'type' => MENU_NORMAL_ITEM,
'description' => t('Printing Service Settings.'),
);
}
return $items;
}
///////////////////////////////////////////////////////////////////////////////////////////////
function print_partners_admin_settings() {
$print_api_res = db_query("SELECT pa.*,pad.* from printing_apis pa, printing_apis_details pad where pa.api_id=pad.api_id and pa.api_id='1'");
$print_api_obj = db_fetch_object($print_api_res);

$refer_id = $print_api_obj->refer_id;
$protocol = $print_api_obj->protocol;
$pid = $print_api_obj->pid;

UIE Server Control

Hey everyone,

I've created a new module (uieservercontrol) and would appreciate some input on how I've implemented it.
Ideally, I'd like to be able to make the list of servers grow/shrink as required (similar to the poll module) but I've no idea how to go about doing this in the admin section. I've used some poll module logic to generate the list of servers (as you may notice in the code).

Anyway, hints/suggestions/comments would be appreciated!

Daniel

New York Observer

i have a little knowledge abt drupal and i went through the newyork observer site. i want to create the same replica of the site or a similar news paper site . plz help me . how they designed the regions and blocks and cck

phpcake-framework for module-development

Hi..just a simple q! i like the phpcake framework, is it possible to use this framework to development drupal modules?
cheers toul

Image Module changing!

Hi Guys,

I am using image module with drupal 5. I have created a link, that will be shown in the Administer->site configuration as "printing Partners". This link shows the setting form, on submitting, this form doesn't return the updated values but shows the default values of the form.

I have created this link in "image_menu" function available in image.module file.
<?php
$items[] = array('title' => t('Printing Partners'),
'path' => 'admin/settings/print_partners',
'callback' => 'drupal_get_form',
'callback arguments' => array('print_partners_admin_settings'),
'access' => user_access('administer site configuration'),
'type' => MENU_NORMAL_ITEM,
'description' => t('Printing Service Settings.'),
);
/////////////////Form function and form submit functions/////////////////////////////////
function print_partners_admin_settings() {
$print_api_res = db_query("SELECT pa.*,pad.* from printing_apis pa, printing_apis_details pad where pa.api_id=pad.api_id and pa.api_id='1'");
$print_api_obj = db_fetch_object($print_api_res);

$refer_id = $print_api_obj->refer_id;
$protocol = $print_api_obj->protocol;
$pid = $print_api_obj->pid;
$psid = $print_api_obj->psid;
$puid = $print_api_obj->puid;

Pages

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