Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 835

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

8 votes

Should I choose Drupal 6 or Drupal 7?

While Drupal 7 is probably the "right" thing to do, there are a few good reasons to stick with Drupal 6. One is the status of the modules you need. … Drupal 7 versions will be less mature than their Drupal 6. They may have better features, but may also have bugs. Some just don't have Drupal 7 versions yet. …
mpdonadio's user avatar
  • 38.1k
0 votes

Resource for understanding Drupal Core functions?

Drupal 7 Module Development is also a good reference. …
mpdonadio's user avatar
  • 38.1k
0 votes

Will a version 6.x module work in v7.x?

A large portion of the Drupal 7 API has changed from the Drupal 6 API, so it is unlikely that a module will work as-is. … If a module hasn't been ported to Drupal 7, then it is likely that it either isn't needed or it isn't being maintained anyway (which is a warning sign). …
mpdonadio's user avatar
  • 38.1k
8 votes
Accepted

Where do I declare a global variable?

Personally, I would either write module that abstracts away the need for a global variable, or at least has a getter function for retrieving it. Something like function foo_get_the_service () { st …
mpdonadio's user avatar
  • 38.1k
4 votes

How to create a module wide variable that refreshes every page load?

Not only does variable_set persist across pages, it nukes the cache every time it is called. It should only really be used for settings, and similar read-mostly uses. If you read my answer to Where …
mpdonadio's user avatar
  • 38.1k
4 votes

How to tell if a site is using Drupal 7

In Drupal 6, init functions are attached like Drupal.behaviors.foo = function () { // ... } In Drupal 7, it is like Drupal.behaviors.foo = { attach: function () { // ... } } …
mpdonadio's user avatar
  • 38.1k
4 votes
Accepted

redirect sub domain in htaccess file

The piece you are missing is RewriteCond. This should redirect just the subdomain RewriteBase / RewriteCond %{HTTP_HOST} ^red\.sitename\.com$ [NC] RewriteRule ^(.*)$ http://sitename.com/$1 [L,R=301] …
mpdonadio's user avatar
  • 38.1k
6 votes

Should I source control contribed modules in my project?

As a counter to @Letharion's answer, putting everything in SVN makes sense for some organizations and it really depends on how you do your rollouts. Putting contrib modules and themes in SVN can make …
mpdonadio's user avatar
  • 38.1k
1 vote

Modules or install profile for scholarly peer review

Depending on what you would like to do, there are two potential approaches. On the simple end, you have fields on content types that only certain roles can edit. For example, you can have a field ca …
mpdonadio's user avatar
  • 38.1k
2 votes
Accepted

project version/revision module

As part of your build script and/or revision control checkin script, write out a version number to constant in an include file. Write a custom module that does something with this include file, such …
mpdonadio's user avatar
  • 38.1k
3 votes

Drupal 7: Variables in external file access

If doing Drupal 7, you may also want to take a look at the files directive for .info files: Drupal now supports a dynamic-loading code registry. …
mpdonadio's user avatar
  • 38.1k
3 votes

inheriting fields from a base content type

A non-ideal option, and not truly a base content type, is to use the Field Collection module. You can create one or more field collections for your common fields, and then attach the collection(s) to …
mpdonadio's user avatar
  • 38.1k
2 votes
Accepted

How to handle GET parameters in the proper Drupal way

In many cases, there are standard Drupal functions that do validation. For example, for email addresses there is valid_email_address. Otherwise, there is the standard PHP Data Filtering library (man …
mpdonadio's user avatar
  • 38.1k
1 vote

Drupal 7 subtheme location best practice

Drupal 7 Module Development says (pg 28) says that this is the current best practice, but I have never see this cross-referenced to official docs on drupal.org. …
mpdonadio's user avatar
  • 38.1k
2 votes
Accepted

Separate frontpage per domain?

In my mind, the big advantage of using Panels is so that you can extend/alter sites like this in the future, without needing a lot of rework. In a lot of ways, Panels provides a framework for futurep …
mpdonadio's user avatar
  • 38.1k

1
2 3 4 5
20
15 30 50 per page