Changeset 2703 for trunk/wp-admin/upgrade-schema.php
- Timestamp:
- 07/11/2005 10:39:50 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/upgrade-schema.php
r2702 r2703 217 217 add_option('use_trackback', 0); 218 218 219 populate_roles(); 220 219 221 // Delete unused options 220 222 $unusedoptions = array ('blodotgsping_url', 'bodyterminator', 'emailtestonly', 'phoneemail_separator', 'smilies_directory', 'subjectprefix', 'use_bbcode', 'use_blodotgsping', 'use_phoneemail', 'use_quicktags', 'use_weblogsping', 'weblogs_cache_file', 'use_preview', 'use_htmltrans', 'smilies_directory', 'fileupload_allowedusers', 'use_phoneemail', 'default_post_status', 'default_post_category', 'archive_mode', 'time_difference', 'links_minadminlevel', 'links_use_adminlevels', 'links_rating_type', 'links_rating_char', 'links_rating_ignore_zero', 'links_rating_single_image', 'links_rating_image0', 'links_rating_image1', 'links_rating_image2', 'links_rating_image3', 'links_rating_image4', 'links_rating_image5', 'links_rating_image6', 'links_rating_image7', 'links_rating_image8', 'links_rating_image9', 'weblogs_cacheminutes', 'comment_allowed_tags', 'search_engine_friendly_urls', 'default_geourl_lat', 'default_geourl_lon', 'use_default_geourl', 'weblogs_xml_url'); … … 230 232 } 231 233 234 function populate_roles() { 235 global $table_prefix; 236 237 $roles = array ('administrator' => 238 array('name' => __('Administrator'), 239 'capabilities' => array( 240 'edit_posts' => true, 241 'edit_others_posts' => true, 242 'edit_published_posts' => true, 243 'publish_posts' => true, 244 'edit_pages' => true, 245 'manage_categories' => true, 246 'manage_links' => true, 247 'upload_images' => true, 248 'manage_options' => true, 249 'switch_themes' => true, 250 'edit_themes' => true, 251 'activate_plugins' => true, 252 'edit_plugins' => true, 253 'edit_users' => true, 254 'edit_files' => true, 255 'read' => true, 256 'level_10' => true, 257 'level_9' => true, 258 'level_8' => true 259 )), 260 261 'editor' => 262 array('name' => __('Editor'), 263 'capabilities' => array( 264 'edit_posts' => true, 265 'edit_others_posts' => true, 266 'edit_published_posts' => true, 267 'publish_posts' => true, 268 'edit_pages' => true, 269 'manage_categories' => true, 270 'manage_links' => true, 271 'upload_images' => true, 272 'read' => true, 273 'level_7' => true, 274 'level_6' => true, 275 'level_5' => true 276 )), 277 278 'author' => 279 array('name' => __('Author'), 280 'capabilities' => array( 281 'edit_posts' => true, 282 'publish_posts' => true, 283 'upload_images' => true, 284 'read' => true, 285 'level_2' => true 286 )), 287 288 'contributor' => 289 array('name' => __('Contributor'), 290 'capabilities' => array( 291 'edit_posts' => true, 292 'read' => true, 293 'level_1' => true 294 )), 295 296 'subscriber' => 297 array('name' => __('Subscriber'), 298 'capabilities' => array( 299 'read' => true, 300 'level_0' => true 301 )), 302 303 'inactive' => 304 array('name' => __('Inactive'), 305 'capabilities' => array()) 306 ); 307 308 add_option($table_prefix . 'user_roles', $roles); 309 } 232 310 ?>
Note: See TracChangeset
for help on using the changeset viewer.