Now I could add addition field in user page by the following user_hook() function, but the main problem I have is how can I erase everything first so that I could totally customized it?
When ever I echo eg. $op in this function (function uc_product_table) in 'fields' case. It renders "fields" two times. "fieldsfields" ? Why is that so. Can It also disturb the GET and if statements ? Because what ever I do I can't get IF statement to work. It works when I do test 1==1 but when I type $node->nid == exact node id it doesnt work.
Hi guys,
I'm trying to edit the book module to add a custom field. So far I've:
- Edited book.install and added the extra fields to the db_query statement
- Updated hook_form() to include the fields (this part works)
- Updated hook_insert() to store the values in the db (this part doesn't!)
I have created a custom field, just think of it as a square with some text in it.
I would like to place this square next to the title and body, something like the below. Any suggestions?
many thanks.
In my module I receive a value from another application via a $_POST['testvalue'] that redirects to a drupal site.
This is allocated to a variable $somevalue=$_POST['testvalue']
I can then display this value using print_r or whatever.
The problem is that i want to save this information into a database with the piece of code below but for some reason i cant.
$somevalue=$_POST['testvalue'];
db_query("INSERT INTO {datasubscriber} (subscriber) VALUES ('%s')", $somevalue);