All Questions

Filter by
Sorted by
Tagged with
3
votes
2answers
15k views

Example for $form_state[‘rebuild’]

May anyone give me an example of rebuilding the form using $form_state['rebuild'] after user's input?
4
votes
1answer
2k views

“Add link” in my account menu

The user account page (http://example.com/user) consists of some default tabs like "View," "Edit," etc. I want to add my menu link over there. The content to be returned should depend on the user ...
4
votes
1answer
3k views

Blocks not visible when I log out

In Administration -> Structure -> Blocks I have defined Search box region with search box block and Left sidebar region with navigation block. These blocks are visible when I'm logged in but ...
3
votes
1answer
3k views

Change blog comments display order

I have a Drupal 7 site with blog and comments enabled for certain user groups and the users complain that in longer discussions like this one the order of comments is totally chaotic, they just can't ...
3
votes
1answer
96 views

How to access past DrupalCon website that requires password?

I want to browse DrupalCon websites to learn stuff from past DrupalCon. Below is partial list: Chicago 2011 March http://chicago2011.drupal.org/ Copenhagen 2010 August http://cph2010....
5
votes
4answers
12k views

Image field is not showing up in view/block

I am currently using Drupal 7, and I am trying to get my images to be displayed in a view on the main page. So far I have created: Created a content type containing a title, body and image field ...
1
vote
2answers
1k views

How do I get the rate vote number?

How do I get the rate vote number, e.g. the number after "funny," "angry," or "mad"? I looked for the values in the database, but I didn't find a column that stores it.thank you.
5
votes
1answer
496 views

How do I include ? and = in a form redirection?

I have a form and I would like to take the value from it, and use it as input for a page view which is created using exposed filters. I have created a submit handler for my first form. I then redirect ...
5
votes
1answer
2k views

How do I check whether a node is flagged when it is being deleted?

I'm using the Flags module for some functionality on my site. When a node is deleted, I need to check whether it's flagged or not and take additional action based on that. I've implemented ...
35
votes
5answers
16k views

Bulk field update?

I added a new (text) field to a Drupal 7 content type that already has many nodes. How can I fill the field with a default value for all these nodes?
8
votes
2answers
13k views

How do I create an AJAX filter for a view?

I have created a page using Views and it works fine. I want to add an AJAX filter to this page to allow visitors to filter the contents based on PubDate or by Taxonomy/Vocabulary for this content type....
3
votes
1answer
873 views

How do I use CCK fields with the form API?

Does anyone know how to use OpenLayers CCK fields with the form API? I want to get a coordinate and some other data from users in my custom form.
5
votes
5answers
1k views

Is it possible to add CSS to theme without a subtheme?

I am using a contributed theme and I would like to add a bit of CSS. The theme uses a lot of stuff that isn't inherited by sub-themes (settings, colors, etc), and I don't want to create a sub-theme ...
3
votes
1answer
238 views

Manipulate search results on site

We have a few scenarios on a project where we want results to be presented at the top of the of the page despite not having any keywords in the body copy related to the search keyword. For instance, ...
5
votes
2answers
2k views

Autocomplete term widget (tagging)

I was using the "autocomplete term widget (tagging)" as widget type for a term reference field. I found out that the when I set the maximum number of allowed values to more than one (i.e multiple ...
3
votes
1answer
1k views

Override forum topics list

The forum topics list has this in the table header: Topic, Replies, Created, Last Reply. I just want to remove the Created heading. Template file forum-topic-list.tpl.php prints the table header with ...
5
votes
1answer
497 views

Comet implementation

Does anyone know how to implement comet in Drupal? I saw a rudimentary PHP implementation on Stack Overflow. Is there any module which does this?
1
vote
2answers
111 views

Same CCK field in one content type

I have a content type named "school;" this content type has the "teacher" CCK field, but the number of teachers is not same for any school. I need a thing like "add new teacher" button, which can be ...
18
votes
7answers
5k views

Change the input format for 3000+ nodes

I have a lot of nodes that need to get their input format changed - I could do that by hand, but then I won't be done before Christmas 2014. Where is Drupal storing that information? How can I ...
2
votes
2answers
3k views

How can I activate a horizontal tab?

Drupal 7 has the field group module which contains a horizontal_tab.js file. Inside this file i found this written // If the current URL has a fragment and one of the tabs contains an // element ...
3
votes
2answers
643 views

How to set the permission for particular role user to access the user profiles of users with a particular role?

I have two user roles: business_users company_users I want to set the permission for all users to see the user profile of users in "business_users" role only. User with the "company_user" role ...
2
votes
1answer
163 views

How to alter each article's comment setting by PHPMyAdmin

After I updated my site, I found out that all the node comments are set to "disabled." I then went to the specific content type setting page, and changed the default comment setting to read/write, ...
3
votes
3answers
2k views

How to get latitude and longitude from user with Form API

I want to create a database-driven website with Drupal 6 to gather some information from users that is related to the location; I want to create a form (and I don't want to use Webforms, or CCK) to ...
4
votes
3answers
3k views

Is it safe to purge the /files/styles directory?

I use Image Styles to automatically generate thumbnails (for teasers and views). I have a lot of images, so I end up with a lot of cached thumbnails in the /files/styles directory. Is it safe to ...
4
votes
4answers
2k views

How do I change the layout of the fields used in a node?

I have a content type which has a large number of fields, for example: first name last name company By default, when a user adds a new node, these fields will appear one under the other. I want to ...
2
votes
1answer
609 views

Something I can't understand in Acquia Marina theme

I have downloaded the Acquia Marina theme yesterday. I cannot understand well the following code; there is a lot of code like the following, in page.tpl.php. <?php print theme('grid_block', $...
0
votes
1answer
151 views

How do I use the field API?

Someone told me that most of the time I will probably want to use the field API (CCK module in D6), rather than adding custom tables or modifying nodes by myself. How do I use the field API? Could ...
7
votes
4answers
4k views

Is there a easier way to disable and enable module for module development?

I'm finding that every small change I make to the hooks I have to disable and re-enable a module. Is there a easy way to do this than having to go through to the module menu, uncheck the module, click ...
4
votes
2answers
4k views

How can I add an extra button & submit handler to an exposed view form?

I would like to add a second button to an exposed view form. I am able to get the button to display, but not to have it call the button submit handler. Instead, it behaves just like the standard ...
2
votes
1answer
860 views

Custom token replacement

I am using Notification to subscribe to different content types so that I can receive emails when a user creates/updates a particular content type. The following is an email I generally receive from ...
1
vote
1answer
2k views

Problem configuring the Calendar module

I'm having trouble with Drupal 7 and the calendar (version 7.x-1.0-alpha3) module. The default view is working. It is showing the nodes based on the time they were updated. I added a date field ...
1
vote
1answer
411 views

Adding custom module pages to the Solr index

We're using Drupal 6. I have written several custom modules that generate a number of pages. All the paths are "given" to drupal using hook_menu() so the system is fully aware of how to access them. ...
1
vote
2answers
414 views

Views generated block - how to override filter on some pages?

On every page of his new site, the client would like a block with four featured links. This will be fairly consistent throughout the site, but on some pages he'd like to override and display four ...
3
votes
1answer
2k views

Organizing uploaded files in folders created by date

This could be very trivial, but I haven't been able to find a good solution. I have an image field associated with a content type called article, and I wish to organize the files uploaded during ...
5
votes
1answer
936 views

How to define another data table to join for views (ie from csv file)?

I successfully created two Views query plugins by learning from XML Views. My plugins query a YAML, and CSV file; they are both base view types on their own. Now I want to learn how to join tables. ...
4
votes
1answer
604 views

how to give edit permission content to new user in drupal?

I have a content type called "company." I have uploaded a lot of company details to the site by myself. Now I want that people employed by these companies create new accounts in my site, and they ...
46
votes
3answers
18k views

How to migrate from test environment to production environment?

The migration is from the local environment to the production environment. The production environment has run some time and created a lot of articles. In order to add new things to my site, I added ...
2
votes
1answer
572 views

Getting Views to use custom aliases

I have the following custom URL aliases that point to specific Views paths: /california/los-angeles maps to /locations/los-angeles /username/listing/post maps to /item/post Views still uses the ...
1
vote
2answers
1k views

Problem blocking users in Drupal 6

I have encountered a weird problem in a Drupal site. Whenever I try to ban an abusive user, by going to the user's profile, change his status from active to blocked, and click save, the change does ...
0
votes
3answers
2k views

How can I point to an internal anchor using core menu?

We have a navigation menu created using Drupal's built-in menu system. One of our menu items has the path set to "node/100770#digital-anchor," but when the menu is rendered, it strips off everything ...
1
vote
2answers
2k views

Can't Remove Image from CCK File Field when editing node (Throbber just spins)

I was able to upload an image, but the thumbnail didn't appear until I hit save on the form. When I try to remove the image, it just sits there spinning the throbber; if I click on "Save" in the form,...
14
votes
6answers
13k views

How do I use URL aliases in menus?

I am kicking the tires on Drupal 7 by spinning up a test site. I chose the Danland theme and created various pages with URL Aliases for each, but when I create the Menu link for each, I can only ...
1
vote
1answer
1k views

My custom preprocess function works as soon as the cache is cleared, then stops working

I have a custom Drupal 6 module, with a custom theme function. I have implemented hook_theme in my mymodule.module (main module file) as follows: function mymodule_theme() { return array( '...
5
votes
2answers
9k views

Date value to different date format

I have a date field. In my template I want to display the date in two different ways. I know in display I can set the format used for a date. To print the date in my template I am doing. <?php ...
3
votes
2answers
1k views

Concatenate $base_url and path_to_theme()

I'm used to write this kind of code in .tpl.php files in order to display images (for instance) : <?php echo $base_url .'/'. path_to_theme();?> I wonder if it would be possible to concatenate $...
2
votes
1answer
758 views

Send mail to users including receiver's username

I have searched settings of Contact (in Drupal core), Simple news and Mass contact modules but haven't found a way to include receiver's username in the mail body. Any suggestions how to do this?
2
votes
5answers
4k views

Overlay and jQuery don't work, what should I do?

I have installed Drupal 7 on a local computer on stack called Denwer (similar to WAMP) and Windows 7; I see that all pages load without Overlay module (it is on, on modules page). I guess that jQuery ...
7
votes
6answers
4k views

Hide a view if less than N results

I wonder if it's possible to hide a view (as block view) if it has less than X results.
3
votes
2answers
3k views

Creating a form

I am new to Drupal 6. I have been playing around with the settings and have been able to create a static website. What I can't seem to figure out is how I create a form with some input fields and a ...
1
vote
1answer
1k views

How to add a node field to a database table in a custom module

When I am writing my own custom module, and designing a database table, if I want to use the field nid to refer to a node, because I want my module to adding something to each node, how should I ...

15 30 50 per page