Weitere ähnliche Inhalte Ähnlich wie New in Drupal7 Ähnlich wie New in Drupal7 (20) Kürzlich hochgeladen (20) New in Drupal71. !"#$%&'()*'
+,'-./0#1'2'
3#.4'56.76,'
8")'3")..4'9+11'36:0#,4'
";0<==>"+11>6?>6:''
2. !"6':#@)&'-./0#1'
•! A.6B)>$'1)#7'
–! -.+)&'C/4$#).$' Committers
•! C.#,>"':#+,$#+,).'
–! D,E)1#'C4.6,'F-./0#1'2G'
–! 5HI6.'96B$&4'F-./0#1'JG'
–! ()+11'-./::'F-./0#1'KG'
•! 36,$.+I/$6.&'
5. -2LM'
http://www.d7ux.org/
6. ()*'N,O6.:#P6,'D.>"+$)>$/.)'
•! ()*'ND'&)0#.#$)&'#7:+,+&$.#PQ)'$#&@&'
+,$6'R>6,$)S$&T<'
–! N%:'7)#1+,E'*+$"'>6,$),$?'
–! N%:'I/+17+,E'6/$'&+$)'&$./>$/.)?'
–! N%:'>"#,E+,E':4'&+$)%&'#00)#.#,>)?'
–! N%:':#,#E+,E'$")'0)601)'*"6'>6:)'$6':4'
&+$)?'
–! N%:'>6,UE/.+,E':67/1)&'#,7'&)V,E&?'
7. Drupal 6 -)O#/1$'O.6,$'0#E)'
Drupal 7
12. 8661I#.'Y'X"6.$>/$&'
Toolbar shows new User account-related
IA along the top info easily accessible
User specific admin shortcuts
23. N,$).,#P6,#1+]#P6,'
•! ()*'$.#,&1#P6,'+,$).O#>)'
•! X)#.>"':67/1)'&/006.$&'1#,E/#E)^
#*#.)'&)#.>")&'
•! N,7+Q+7/#1'U)17&'>#,'I)':#.@)7'
$.#,&1#$#I1)=/,$.#,&1#$#I1)'
•! X/006.$'O6.':)&&#E)'>6,$)S$&'F:&E>$S$G'
$6':#@)'$.#,&1#P6,'6O'&"6.$'*6.7&'1+@)'
R[+)*T':/>"')#&+).?'
26. X)>/.+$4'
•! A.6:0$)7'O6.')^:#+1',6PU>#P6,&'6O'
&)>/.+$4'/07#$)&'/06,'+,&$#11#P6,?'
•! A9A'U1$).':67/1)',6*'E16I#1'R@+11^&*+$>"T'
O6.'R),$).'&6:)'A9A'").)T'O/,>P6,#1+$4?'
•! 3.6,?0"0'.)_/+.)&'@)4'+,'L`a'$6'I)'./,?'
•! ()*'0).:+&&+6,'O6.'./,,+,E'&+$)'/07#$)&?''
•! a+:+$'16E+,'#;):0$&b'I);).'c667'>6,$.61?'
•! X$.6,E).b'01/EE#I1)'0#&&*6.7'"#&"+,E'
#1E6.+$":?'
28. d+)17'840)&'+,'36.)'
•! C661)#,'
•! -)>+:#1=d16#$=N,$)E).'
•! d+1)'
•! N:#E)'
•! a+&$'
•! 8)S$=8)S$#.)#'
•! 8#S6,6:4'$).:'
•! (67)'C674'F16,E'$)S$'#,7'&/::#.4G'
36. `)^Q#:0)7'f?$01?0"0'
•! Re-engineered XHTML structure to facilitate CSS-only design.
•! Standard, semantic class/ID names (.section, #navigation, etc.)
•! Improved consistency throughout
•! Enables designers to create CSS-only themes without touching PHP
•! No more box.tpl.php
38. 5.#,/1#.'$"):+,E'6O'>6,$),$'
Drupal 6
•! g>6,$),$'*#&'#'I+E'&$.+,E'6O'M98a'
•! d+,)^E.#+,)7'>6,$.61'6Q).'*").)'f6,)f'
0#.$'6O'>6,$),$'E6)&':)#,&'I)+,E'
.)&06,&+I1)'O6.'f#11f'0#.$&'6O'>6,$),$'
•! X)>/.+$4'#Q).&)'
•! WQ),'>6::),$&'#.)'+,'$"+&':+S'
39. 5.#,/1#.'$"):+,E'6O'>6,$),$'
Drupal 7
...
•! g>6,$),$'+&',6*'#,'#..#4'6O'0#E)'
0.60).P)&'$"#$'@))0&'$.#>@'6O'*"#$%&'
I)),'0.+,$)7'&6'O#.?'
•! X)1)>PQ)14'"+7)'0#.$&'/,P1'46/%.)'.)#74'
$6'0.+,$'$"):'*").)'hZL'*#,$?'
40. `-d#'
Default mapping for nodes:
<?php
$type->rdf_mapping = array(
'rdftype' => array('sioc:Item', 'foaf:Document'),
'title' => array('dc:title'),
'created' => 'dc:created',
'changed' => 'dc:modified',
'body' => 'content:encoded',
'uid' => 'sioc:has_creator',
'name' => 'foaf:name',
);
?>
44. $)&P,E?7./0#1?6.E'
•! RA#$>"'F>67)',))7&'.)Q+)*GT'#,7'RA#$>"'
F.)Q+)*)7'Y'$)&$)7'I4'>6::/,+$4GT'
&$#$/&)&'>#,',6*'I)'$./&$)7?'
•! `)Q+)*).&',6'16,E).'E)V,E'>#.0#1'$/,,)1'
>1+>@+,E'$".6/E"'#11'$")'I#&+>'&$/o?'
•! `/,,+,E'$")'O/11'$)&$'&/+$)'$#@)&'#'16,E'
P:)p'1)$'#'>6:0/$).'76'+$'O6.'46/q'
•! (6PU)&'#/$"6.'*+$"+,'mr'"6/.&'+O'0#$>"'
,6'16,E).'#001+)&'6.'I.)#@&'$)&$&?'
46. 8")'*"6'+,'$")'*"#$',6*s'
•! -#$#I#&)'#I&$.#>P6,'1#4).'/P1+]+,E'A9A%&'
-#$#'ZIB)>$&'FA-ZG'
•! 8")6.)P>#1'&/006.$'O6.'#,4'A9A'
&/006.$)7'7#$#I#&)'
•! :4&_1b'&_1+$)b'#,7'0E&_1'7.+Q).&'+,>1/7)7'
•! X/006.$'O6.':#&$).=&1#Q)'.)01+>#P6,b'
$.#,&#>P6,&b':/1P^+,&).$'_/).+)&b'7)1#4)7'
+,&).$&b'#,7'6$").'O)#$/.)&'
47. X$#P>'X)1)>$'j/).+)&'
Drupal 6:
$result = db_query("SELECT nid, title FROM {node} !
WHERE type = '%s' AND nid = %d", array($type, $nid));"
$node = db_fetch_object($result);"
Drupal 7:
$node = db_query('SELECT nid, title FROM {node} !
WHERE type = :type AND nid = :nid', array(':type' =>
$type, ':nid' => $nid))->fetchObject();"
48. -4,#:+>'X)1)>$'j/).+)&'
Drupal 6:
$result = pager_query(db_rewrite_sql('SELECT n.nid FROM {node} n
WHERE n.promote = 1 AND n.status = 1 ORDER BY n.sticky DESC,
n.created DESC'), variable_get('default_nodes_main', 10));"
Drupal 7:
$select = db_select('node', 'n')"
->fields('n', array('nid'))"
->condition('promote', 1)"
->condition('status', 1)"
->orderBy('sticky', 'DESC')"
->orderBy('created', 'DESC')"
->extend('PagerDefault')"
->limit(variable_get('default_nodes_main', 10))"
->addTag('node_access');"
49. Drupal 6:
"66@n_/).4n#1$).FG'
function hook_db_rewrite_sql($query, $primary_table, $primary_field, $args) {!
switch ($primary_field) {!
case 'nid':!
$return = array();!
if ($primary_table != 'n') {!
$return['join'] = "LEFT JOIN {node} n ON $primary_table.nid = n.nid";!
}!
$return['where'] = 'created >' . time() - 3600;!
return $return;!
break;!
}!
Drupal 7:
function hook_query_alter(&$query) {!
if ($query->hasTag(‘node_access’)) {!
$query->condition(‘created’, time() - 3600, ‘>’);!
}!
}!
52. X$.)#:'*.#00).'&/006.$'
•! `#$").'$"#,'.)O).),>+,E'U1)&'I4'0#$"b'46/'
,6*'.)O).),>)'$"):'I4'L`N<''
&>"):#<==U1)=0#$"=U1)?)S$'
•! D116*&'46/'$6'>"#,E)'16>#P6,'6O'U1)&'
7+.)>$6.4'*+$"6/$'#'7#$#I#&)'/07#$)?'
•! 0/I1+><==b'0.+Q#$)<==b'$):0<=='&/006.$)7'+,'
>6.)?'
•! 36,$.+I/$)7':67/1)&'>#,'#1&6'>.)#$)'
&l<==b'c+>@.<==b')$>?'
54. DAN&'
•! `61)&=A).:+&&+6,&'DAN'
•! d+1$).=d6.:#$'DAN'
•! 3),$.#1+])7'&$#P>'>#>"+,E':)>"#,+&:'
•! a6>@+,E'O.#:)*6.@'
•! i6I'_/)/)'
55. d+)17'DAN'
•! (6$',67)^&0)>+U>'
•! -)>1#.)'#,4'),P$4'+,'-./0#1'#&'RU)17#I1)T'
•! X*#00#I1)'&$6.#E)'I#>@^),7&'F>/..),$14b'Xja'
I/$'06$),P#114'*)I'&).Q+>)&b')$>?G'
•! X/006.$&'$.#,&1#$#I1)'>6,$),$?'
56. N:#E)'DAN'
•! N:#E)'$661@+$&',6*'+:01):),$)7'#&'
:67/1)&b'.#$").'$"#,'?+,>'U1)&'$"#$'/&).&'
,))7'$6'>604'6Q).?'
•! X/006.$&'+:#E)':#,+0/1#P6,')o)>$&<'&>#1)b'
>.60b'.)&+])b'.6$#$)???'
•! 3#,'>6:I+,)'$")&)'+,$6'R+:#E)'&$41)&T'$"#$'
>#,'I)'#001+)7'$6'#,4'+:#E)'F/&).'0+>$/.)&b'
U1)'/016#7&???G'
59. X0))7'#,7'&>#1#I1+$4'
•! A.6S4'#,7'.)Q).&)^0.6S4'&/006.$<'&).Q)'
#,6,4:6/&'0#E)'.)_/)&$&'),P.)14'Q+#'
0.6S4'
•! #,4':+>.6^60P:+]#P6,&'$".6/E"'
M-)I/E'0.6U1+,E'
•! X:#.$).'166@^#")#7'&4&$):'O6.'E.#II+,E'
0#$"'#1+#&)&'
•! N,,6-C'7)O#/1$'&$6.#E)'&4&$):'F4XjaG'
•! 3-('&/006.$'O6.'U1)&'
60. (67)'D>>)&&'N:0.6Q):),$&'
•! R#7:+,+&$).',67)&T'#,7'RI40#&&',67)'
#>>)&&T'$*6'&)0#.#$)'0).:+&&+6,&'
•! D1$).'"66@n,67)nE.#,$&'#,7'
"66@n,67)n#>>)&&n.)>6.7&'
•! (67)'#>>)&&'#001+)&'$6'/,0/I1+&")7'
,67)&'
•! "66@n,67)n#>>)&&FG'#116*&':67/1)&'$6'
+,c/),>)'#>>)&&'6,',67)&'7)U,)7'I4'
6$").':67/1)&'
63. 8")'I6;6:'1+,)'
•! W#&+).'$6'E)$'&$#.$)7'
–! 3")>@'.)_/+.):),$&'
–! -6*,16#7'-./0#1'2'
–! 3.)#$)'7#$#I#&)'
–! N,&$#11'
–! D77'$"):)&'Y':67/1)&'O.6:'+,$).O#>)'
•! W#&+).'$6'I/+17'6/$'
–! N:0.6Q)7'#7:+,+&$.#P6,'
–! 8"):).'O.+),714'
•! W#&+).'$6'7)Q)160'
–! 6.)'>6,&+&$),$'#,7'c)S+I1)'
•! W#&+).'$6'+,$)E.#$)'
–! `-d#'