Questions tagged [6]

Version tags should be used for questions that apply to a version only, not to merely say what version a site is using.

Filter by
Sorted by
Tagged with
3
votes
1answer
1k views

Why this code doesn't send an email with drupal_email()?

I am developing a Drupal 6 module that should send an email after a form is submitted. So far, I wrote the following code. function mailform_mail($key, &$message, $params) { $headers = array( ...
4
votes
1answer
431 views

Node access user reference

Main Modules: Node access user reference Node access node reference Flags Rules I'm trying to give access to a user that clicks on a Join Project flag link. I have a User Reference Field attached ...
-1
votes
0answers
16 views

Programatically export data to CSV from custom field [closed]

I have content type e.g EXAMPLE I want to export data to CSV, but in the view I cannot find the custom field i have created in content type i.e FIRTNAME and LASTNAME, so I want to create a module for ...
0
votes
1answer
497 views

how to use hook_webform_submission_presave on a site with multiple webforms

I've got a question on the use of the hook_webform_submission_presave function for D6/webform 6.x-3.4 I've got a multi-lingual D6 site that has one webform for each language, I'm trying to create a ...
0
votes
1answer
425 views

How do I load external JavaScript before local JavaScript?

I try to load JavaScript with drupal_add_js(), but it's not easy, and after fixing the loading of external JavaScript, I faced off a loading order issue: My external JavaScript is loaded after my ...
0
votes
1answer
1k views

Expose views as JSON

I'd like to expose data/views coming from 6.19 as json. What I tried so far are the JsonRPC/REST service modules, but none of them worked for me.
2
votes
2answers
556 views

Loading specific bootstrap mode in hook_menu

There is a way to define a specific bootstrap mode for a hook_menu URL (MENU_CALLBACK)? I just want the request returns to me a result of a simple query in JSON and for that, I don´t need load the ...
1
vote
1answer
2k views

Parse error on JSON response containing URL value

In my code it is making Ajax request for json data. For JSON output I am using drupal_json() function. But on browser side it is invoking error handler instead of success handler and getting '...
1
vote
1answer
302 views

How do I render a node queue as custom JSON?

What would be the most sensible way to render a nodequeue queue in a custom JSON format (using Drupal 6) We have a nodequeue that is both included in the UI in various places and served in a RSS feed....
1
vote
1answer
79 views

Why isn't the page cal back needed in Ajax jQuery?

In the following code, I didn't set any page arguments, but I can still tse the parameter in example_result(). Why it works? function example_menu() { $items['example-menu'] = array( 'page ...
0
votes
3answers
378 views

Passing global variables to alter hooks

The problem I have is that it seems that I can use global variable created inside another module, only if I use it inside callback function. I successfully tested it by inserting code inside existing ...
5
votes
1answer
219 views

Updating content after major upgrade from 5 to 6 (changes to production site need to be reflected in dev environment)

I have been tasked with a major upgrade from D5 to D6. The upgrade is now complete and fully themed on my development server. The current production site is very busy, with dozens of nodes being ...
6
votes
1answer
1k views

Programmatically insert webform result

I'm using drupal 6 with the webform module installed. I need to be able to remotely POST, from PHP results to a webform. Pseudocode: <?php //File: ...
3
votes
2answers
2k views

Creating a node using Services 6.3 REST

I am trying to create a node using the rest service. I am hitting /myendpoint/node using a post. My header is application/json. I am not sure what I need to post as the data.
2
votes
0answers
642 views

Retrieve site menus using REST API [closed]

I have a site where menus are created using Site building -> Menus -> List menus -> Primary links -> Add item option. Some of them have sub-menus under them. I want to retrieve these menus ...
1
vote
1answer
565 views

unable to get custom service to return result using services module

I'm learning about web services and implementing it in drupal 6 and am trying to use Services module with its REST server for implementing a web service to add a user. Since there is an existing ...
2
votes
1answer
1k views

How do I enable CORS?

I want to use services 3 module to create node of a content type in my Drupal 6 website. I have enabled Services 3 module and configured the Rest Server properly. But when I make a post call to it, ...
1
vote
0answers
161 views

How do I use services on server that does not support CORS?

I am using Drupal 6 for my current website. I have confirmed that the server(Pantheon) running my Drupal 6 website on nginx does not support CORS as of now. I want to interact with this site using ...
5
votes
3answers
5k views

Problem installing REST Server module

When I attempt to enable the REST Server module, I get the following error message: A library is missing for rest_server to work (Currently using Missing library Please download spyc and create a ...
0
votes
1answer
664 views

Variable in html.tpl.php

This seemingly simple task proved more difficult than I imagined.. I'm trying to get a variable from themename_preprocess_html to my html.tpl.php. The code I have in my template.php file: <?php ...
1
vote
1answer
886 views

Change ID of webform hidden element

How can I change the ID of a hidden element (created with the Drupal 6 webform module) using hook_form_alter()? The ID that it outputs is something like '#edit-submitted-component-name'. I need the ...
1
vote
1answer
492 views

Override theme function for menu callback

What I am looking for: I have a custom node link which, when clicked, displays a custom HTML content (option selections) in a lightbox. I need to pass an argument to the HTML content to generate the ...
2
votes
2answers
895 views

Programmatically set the number of Multiple Value CCK fields in node edit form

I have a filefield multi-value CCK field and I want to be able to set the number of values that can be added based on some condition when the user is editing the existing node. Is there a way to ...
1
vote
1answer
619 views

Menu Block won't display when a page has a View Block on it

I have Menu Block installed to provide some contextual menus for certain areas of a site. These generally work great. But I have a few pages where I'm adding a Views generated block to the bottom of ...
1
vote
1answer
2k views

“b.handleError is not a function” on image remove/upload

I was not able to upload/remove CCK field images from the UI; when I looked at the console in Firebug, it said, "b.handleError is not a function." When I look for this error on Internet, I keep ...
1
vote
2answers
598 views

Programmatically embed fields of one content type in the create/edit form of another content type and store all

I have drupal 6.x. How to programmatically (with a custom module) embed fields of one content type (content type X) in the create/edit form of another content type (content type Y) and store all ...
1
vote
1answer
667 views

How to add multiple items to cart?

I came across this other question and wondered whether it was compatible with Drupal 6/UC 2: Add multiple items to cart I would like to create a page that shows the thumbnail and title of all ...
1
vote
1answer
493 views

How to update taxonomy term of a node using services

I have created a new node using Services 3 module successfully, the code is below { "type":"page", "title":"New test page", "taxonomy": { "tid" :"367928" } } Configuration: Drupal ...
0
votes
2answers
2k views

Fatal error: Maximum execution time of 240 seconds exceeded in sites/all/modules/memcache/memcache.inc on line 353

I am using multidomain site . After adding a new domain record, I was asked as follows: Content access permission needs to be rebuilt on this page. When I clicked on Rebuild Permissions button, the ...
1
vote
1answer
909 views

how to validate minimum age in webform

I've got a question about webform and webform validation. I'm in D6.19 with webform 6.x-3.4 and webform validation 6.x-1.3 I'm adding a date field to capture age, and I need to validate that the age ...
2
votes
2answers
579 views

Assign a node to an organic group

Programmatically assign a node to an organic group is following my previous question which I have found the solution for Drupal 7, but I am now looking for the same issue in Drupal 6. How can I ...
0
votes
2answers
1k views

How to set body content using preprocess_node?

I need to alter the body html for a specific content type which will be processed by the Pagination module. I think preprocess_node will work, but I'm having trouble figuring out how to change the ...
3
votes
1answer
687 views

What are the appropriate configurations for the Subdomain module on Window 7 running XAMPP?

I have installed the Subdomain module (v 6.1.7), and I'm configuring a subdomain for testing on localhost. I have been tearing my hair out for days now, trying to get this module to work on my PC - ...
1
vote
1answer
766 views

Get Order Object on Checkout Complete Page

I'm trying to develop a new module but just can't get the correct solution, I hope you can help me. On the checkout complete page i need the order object with all information of the just created ...
0
votes
1answer
568 views

CCK checkbox or dropdown widget as a field?

I am trying to setup a new CCK field for a content type to display as a checkbox but I see I don't have that option in the widgets type. Shouldn't that be included in the default CCK? I am using the ...
0
votes
2answers
926 views

Creating Primary Sub menu's programmatically

I want to display the latest 10 nodes of node type 'ABC' as a sub menu link under my primary menu. Are there any modules for Drupal 6 to help me achieve it. I have created a view which gives me a ...
4
votes
1answer
1k views

How to make a calendar tab for every user showing user's events?

I followed the tutorial Calendars for Organic Groups - A simple tutorial for D6, and successfully created a calendar for every group in my site showing its events. I also managed to show the calendar ...
0
votes
1answer
599 views

How to make Ubercart Ajax Attribute Calculations work with Fusion theme?

I have a website set up with the Fusion theme, and Ubercart Ajax Attribute Calculations is not working as expected. I switched my theme momentarily to Garland and it did work then, so it's definitely ...
0
votes
2answers
818 views

Adding CCK field to solr index

We have a cck field called "keywords". We need to add this field to the solr index so we can search on it from outside of drupal. How are CCK fields managed in the solr index? UPDATE: I created a ...
1
vote
2answers
795 views

How to add a confirmation form after the user clicks “Save” on a node edit form?

On a site I'm building, a user can edit certain fields on a node that cause a chain reaction to happen (which I've implemented using hook_nodeapi's "update" op). Since this chain reaction potentially ...
0
votes
1answer
364 views

db_fetch_object returning null

This is the line: $row = db_fetch_object($result); While $result is valid but $row is getting a null value which I've checked with is_null. As per this function's @return value, it can only return ...
1
vote
1answer
2k views

Adding the video field to a content type

We've been using an SWF player for a while. I added the Video module without adding a new content type, just to see if the HTML5 tag worked. It does. However, that obviously doesn't give us an SWF ...
1
vote
2answers
2k views

print field in views row template

I try to make a custom view using templates. I need to print one certain field at the last row, after all other fields have been printed like so: --1st row field1 field2 --2nd row field1a field2a --...
2
votes
1answer
776 views

How do i add Meta Tags on panels page?

I want to generate meta tags on panels node pages. I am adding Meta tags using nodewords module, it works fine on other node pages except panels generated layout. Any workaround for this?
0
votes
3answers
759 views

check for multiple roles

This code I use when checking if user has a role if (in_array('administrator', array_values($user->roles))) How to check for multiple roles? I tried something like this if (!in_array('...
3
votes
1answer
382 views

Change the sorting order used for Book nodes

How can I change the order used for Book nodes, which by default is based on weight and title? I have a set of nodes displayed inside a page that use a structured book. I want to display them ordered ...
2
votes
2answers
1k views

Convert special characters to normal characters

? and = will be used as parts in my url. In generating the url, I use <?php echo l('node/'. $someID .'/delete?destination=chapter/'. $anotherID);?>. When I check on Firebug, the href attribute ...
2
votes
3answers
878 views

How to use curly braces in schema default value?

I have a long varchar field that I'm using to save serialised data with drupal_write_record. I'd like to set the default value of the column to "a:0:{}" (which is serialize(array())). However, when ...
4
votes
1answer
1k views

Additional Configuration to disable anonymous session cookies?

I am running a clean install of Pressflow 6.28. I have set the following configurations: Cache Mode: Normal; Min Cache Lifetime: 5 minutes; Page Cache Max Age: 1 day; I have installed no contributed ...
4
votes
2answers
1k views

Adding new rows on a draggable table via jquery

I have a draggable table with preloaded "new items" - sorta like the Power Edit feature of the menu_editor module. Everything works perfect. However, I want to have a button that adds a new row via ...

1
2 3 4 5
56