- Page 1 and 2: www.allitebooks.com
- Page 3 and 4: Drupal 7 Module Development Copyrig
- Page 5 and 6: Foreword Drupal has its roots in th
- Page 7 and 8: About the Authors Matt Butcher is a
- Page 9 and 10: Larry Garfield is a Senior Architec
- Page 11 and 12: John Albin Wilkins has been a web d
- Page 13 and 14: Jojodae Ganesh Sivaji has been invo
- Page 15 and 16: Why Subscribe? • Fully searchable
- Page 17 and 18: Table of Contents Tools for develop
- Page 19 and 20: Table of Contents A shortcut for sy
- Page 21 and 22: Table of Contents Using hook_node_a
- Page 23 and 24: Table of Contents Creating a task 3
- Page 25 and 26: Preface Chapter 5, Building an Admi
- Page 27: Preface The system for handling thi
- Page 31 and 32: Developing for Drupal 7 As fantasti
- Page 33 and 34: Developing for Drupal 7 However, fo
- Page 35 and 36: Developing for Drupal 7 The precedi
- Page 37 and 38: Developing for Drupal 7 For example
- Page 39 and 40: Developing for Drupal 7 The theme s
- Page 41 and 42: Developing for Drupal 7 The node sy
- Page 43 and 44: Developing for Drupal 7 Using this,
- Page 45 and 46: Developing for Drupal 7 The API sit
- Page 48 and 49: Creating Your First Module The focu
- Page 50 and 51: Module names It goes without saying
- Page 52 and 53: Chapter 2 Creating the module direc
- Page 54 and 55: Chapter 2 CVS is going away, and so
- Page 56 and 57: Now we have created our first.info
- Page 58 and 59: Chapter 2 Source code standards Dru
- Page 60 and 61: Chapter 2 The initial doc block in
- Page 62 and 63: Notice that Help now shows up under
- Page 64 and 65: So the t() function should always b
- Page 66 and 67: There are half a dozen hooks in the
- Page 68 and 69: Chapter 2 This defines a block name
- Page 70 and 71: Chapter 2 The next few chapters wil
- Page 72 and 73: The output from our module is a sim
- Page 74 and 75: Writing a test case There are a few
- Page 76 and 77: Chapter 2 } public function getInfo
- Page 78 and 79:
Chapter 2 DrupalWebTestCase::setUp(
- Page 80 and 81:
Chapter 2 This function does three
- Page 82 and 83:
Chapter 2 To run the test, go to Co
- Page 84 and 85:
Drupal's Theme Layer The most obvio
- Page 86 and 87:
Chapter 3 After the data has been r
- Page 88 and 89:
Chapter 3 As you can see in the pre
- Page 90 and 91:
Chapter 3 Second, the theme functio
- Page 92 and 93:
Chapter 3 First let's look at the f
- Page 94 and 95:
Chapter 3 The preceding exam
- Page 96 and 97:
Chapter 3 Here's an example that sh
- Page 98 and 99:
[ 75 ] Chapter 3 Process functions
- Page 100 and 101:
Chapter 3 By the way, does your bra
- Page 102 and 103:
Lastly, the kitten element's #type
- Page 104 and 105:
Chapter 3 As you can see, the link
- Page 106 and 107:
Chapter 3 We've actually already di
- Page 108 and 109:
Chapter 3 Theme registry So all of
- Page 110 and 111:
A module's hook_theme implementatio
- Page 112 and 113:
Chapter 3 to simply implement a spo
- Page 114 and 115:
Theming a Module Now that you've le
- Page 116 and 117:
Chapter 4 Common theme hooks links
- Page 118 and 119:
Chapter 4 In Chapter 5, Building an
- Page 120 and 121:
Chapter 4 Our single_blog_block_inf
- Page 122 and 123:
Chapter 4 The following is a screen
- Page 124 and 125:
Chapter 4 into these lines: 'data'
- Page 126 and 127:
Chapter 4 .block-single-blog .conte
- Page 128 and 129:
Chapter 4 After all these modificat
- Page 130 and 131:
Chapter 4 Before we begin building
- Page 132 and 133:
Chapter 4 Preprocess functions Our
- Page 134 and 135:
Chapter 4 } return $query; /** * Im
- Page 136 and 137:
Chapter 4 } // single_blog_block_vi
- Page 138 and 139:
Chapter 4 // Only display the wrapp
- Page 140 and 141:
Chapter 4 .block-single-blog .conte
- Page 142 and 143:
Building an Admin Interface In this
- Page 144 and 145:
Chapter 5 The Drupal menu system Dr
- Page 146 and 147:
Chapter 5 This is used in a variety
- Page 148 and 149:
Chapter 5 This is all the informati
- Page 150 and 151:
Chapter 5 In past versions of Drupa
- Page 152 and 153:
Chapter 5 '#size' => 40, '#maxlengt
- Page 154 and 155:
The following is how this text fiel
- Page 156 and 157:
Chapter 5 Drupal also offers a Form
- Page 158 and 159:
Chapter 5 '#default_value' => varia
- Page 160 and 161:
variable_set('user_warn_e-mail_subj
- Page 162 and 163:
Chapter 5 '#description' => t('Indi
- Page 164 and 165:
Chapter 5 Forms generated by confir
- Page 166 and 167:
Chapter 5 • The second argument,
- Page 168 and 169:
Chapter 5 As discussed earlier, it
- Page 170 and 171:
Chapter 5 Tokens can also be 'chain
- Page 172:
Chapter 5 That's it! The text retur
- Page 175 and 176:
Working with Content • We may be
- Page 177 and 178:
Working with Content 'default' => '
- Page 179 and 180:
Working with Content Note here as w
- Page 181 and 182:
Working with Content Once again, ou
- Page 183 and 184:
Working with Content Because our pa
- Page 185 and 186:
Working with Content As a general r
- Page 187 and 188:
Working with Content 'access argume
- Page 189 and 190:
Working with Content 'access argume
- Page 191 and 192:
Working with Content There are a co
- Page 193 and 194:
Working with Content } '#submit' =>
- Page 195 and 196:
Working with Content Saving your ar
- Page 197 and 198:
Working with Content } catch (Excep
- Page 199 and 200:
Working with Content Viewing artwor
- Page 201 and 202:
Working with Content drupal_set_tit
- Page 203 and 204:
Working with Content watchdog('artw
- Page 205 and 206:
Working with Content Summary This h
- Page 207 and 208:
Creating New Fields 3. We want to p
- Page 209 and 210:
Creating New Fields Like most "info
- Page 211 and 212:
Creating New Fields Since measureme
- Page 213 and 214:
Creating New Fields } } } } } ); ),
- Page 215 and 216:
Creating New Fields } 'behaviors' =
- Page 217 and 218:
Creating New Fields In this simple
- Page 219 and 220:
Creating New Fields } } } $element[
- Page 221 and 222:
Creating New Fields During the vali
- Page 223 and 224:
Creating New Fields Formatters foll
- Page 225 and 226:
Creating New Fields Recall from a m
- Page 227 and 228:
Creating New Fields } $row[] = t('@
- Page 229 and 230:
Creating New Fields hook_field_extr
- Page 231 and 232:
Creating New Fields Always use Enti
- Page 233 and 234:
Creating New Fields Again, there's
- Page 235 and 236:
Drupal Permissions and Security In
- Page 237 and 238:
Drupal Permissions and Security If
- Page 239 and 240:
Drupal Permissions and Security To
- Page 241 and 242:
Drupal Permissions and Security The
- Page 243 and 244:
Drupal Permissions and Security 3.
- Page 245 and 246:
Drupal Permissions and Security $it
- Page 247 and 248:
Drupal Permissions and Security Res
- Page 249 and 250:
Drupal Permissions and Security fun
- Page 251 and 252:
Drupal Permissions and Security Whe
- Page 253 and 254:
Drupal Permissions and Security The
- Page 255 and 256:
Drupal Permissions and Security The
- Page 257 and 258:
Drupal Permissions and Security } }
- Page 259 and 260:
Drupal Permissions and Security Usi
- Page 261 and 262:
Drupal Permissions and Security In
- Page 263 and 264:
Drupal Permissions and Security Sum
- Page 265 and 266:
Node Access • The {node_access} t
- Page 267 and 268:
Node Access ->limit(variable_get('d
- Page 269 and 270:
Node Access The access whitelist Th
- Page 271 and 272:
Node Access Here we see a distinct
- Page 273 and 274:
Node Access This clause is primaril
- Page 275 and 276:
Node Access Instead, core returns t
- Page 277 and 278:
Node Access Using hook_node_access(
- Page 279 and 280:
Node Access And we are done, right?
- Page 281 and 282:
Node Access If the $diff array is e
- Page 283 and 284:
Node Access The reasoning behind th
- Page 285 and 286:
Node Access When executed, the foll
- Page 287 and 288:
Node Access The {node_access} table
- Page 289 and 290:
Node Access Creating the role acces
- Page 291 and 292:
Node Access From here, we are requi
- Page 293 and 294:
Node Access Note that we do not hav
- Page 295 and 296:
Node Access Once we have these perm
- Page 297 and 298:
Node Access Domain Access keeps tra
- Page 299 and 300:
Node Access 'title' => t('View role
- Page 301 and 302:
Node Access This code will grant an
- Page 303 and 304:
Node Access This permission will in
- Page 305 and 306:
Node Access Now we have an advanced
- Page 307 and 308:
Node Access // Get a list of user r
- Page 309 and 310:
Node Access • How to write your o
- Page 311 and 312:
JavaScript in Drupal • jQuery For
- Page 313 and 314:
JavaScript in Drupal This provides
- Page 315 and 316:
JavaScript in Drupal The preprocess
- Page 317 and 318:
JavaScript in Drupal Settings shoul
- Page 319 and 320:
JavaScript in Drupal Defining a lib
- Page 321 and 322:
JavaScript in Drupal API Documentat
- Page 323 and 324:
JavaScript in Drupal The keys to th
- Page 325 and 326:
JavaScript in Drupal Drupal.theme()
- Page 327 and 328:
JavaScript in Drupal The behavior i
- Page 329 and 330:
JavaScript in Drupal t('Los Angelas
- Page 331 and 332:
JavaScript in Drupal The page callb
- Page 333 and 334:
JavaScript in Drupal ajax_command_b
- Page 335 and 336:
JavaScript in Drupal ajax_command_s
- Page 337 and 338:
Working with Files and Images We wi
- Page 339 and 340:
Working with Files and Images File
- Page 341 and 342:
Working with Files and Images $node
- Page 343 and 344:
Working with Files and Images Creat
- Page 345 and 346:
Working with Files and Images /** *
- Page 347 and 348:
Working with Files and Images The t
- Page 349 and 350:
Working with Files and Images Image
- Page 351 and 352:
Working with Files and Images */ fu
- Page 353 and 354:
Working with Files and Images The s
- Page 355 and 356:
Working with Files and Images You c
- Page 357 and 358:
Working with Files and Images Creat
- Page 359 and 360:
Working with Files and Images ); }
- Page 361 and 362:
Working with Files and Images Once
- Page 363 and 364:
Working with Files and Images This
- Page 365 and 366:
Working with Files and Images Defau
- Page 367 and 368:
Installation Profiles Drupal distri
- Page 369 and 370:
Installation Profiles The name and
- Page 371 and 372:
Installation Profiles The install t
- Page 373 and 374:
Installation Profiles In this case
- Page 375 and 376:
Installation Profiles The form func
- Page 377 and 378:
Installation Profiles There are som
- Page 379 and 380:
Installation Profiles 'module' => '
- Page 381 and 382:
Installation Profiles Text filters
- Page 383 and 384:
Installation Profiles The profile w
- Page 385 and 386:
Installation Profiles 'update_statu
- Page 387 and 388:
Database Access Basic queries Most
- Page 389 and 390:
Database Access Dynamic queries Alt
- Page 391 and 392:
Database Access Finally we execute
- Page 393 and 394:
Database Access Update queries Upda
- Page 395 and 396:
Database Access Advanced subjects W
- Page 397 and 398:
Database Access Summary Although in
- Page 399 and 400:
Security Always assume that incomin
- Page 401 and 402:
Security For output to the browser,
- Page 403 and 404:
Security • Send a detailed descri
- Page 406 and 407:
Index Symbols $account parameter 25
- Page 408 and 409:
core libraries 13 core modules 14 C
- Page 410 and 411:
artwork types, managing 163-165 new
- Page 412 and 413:
hook_node_grants_alter() about 275
- Page 414 and 415:
node system 12, 17 non-field data m
- Page 416 and 417:
TDD 26 technologies, Drupal about 8
- Page 418 and 419:
Thank you for buying Drupal 7 Modul
- Page 420:
Drupal 6 Performance Tips ISBN: 978