按順序安裝好Apache、MariaDB和php,啟動Apache和MariaDB,創建一個UTF-8字符集的數據庫。
> create database if not exists drupal default character set utf8;在Drupal官網下載Drupal core文件:drupal-7.36.tar.gz
$ tar xzvf drupal-7.36.tar.gz$ cd drupal-7.36拷貝所有文件到web目錄,包括2個隱藏文件。
# cp -R * .gitignore .htaccess /var/www/html創建settings.php文件
# cp /var/www/html/sites/default/default.settings.php /var/www/html/sites/default/settings.php改變web目錄下所有文件的所有者和所屬組群
# chown -R apache:apache /var/www/html/* /var/www/html/.gitignore /var/www/html/.htaccess防止SElinux搗亂
# chcon -R -t httpd_sys_content_rw_t /var/www/html/sites/default/ /var/www/html/sites/all/modules/ /var/www/html/sites/all/themes/瀏覽http://localhost開始安裝。
使drupal的.htaccess文件起作用
<Directory "/var/www/html"> AllowOverride All</Directory>啟用發送郵件支持
SMTP Authentication Support module。啟用中文環境
Localization update module。Locale module(Localization update module依賴Locale module)。安裝常用modules
Administration menu module,之后disableToolbar module。Back To Top module。Backup and Migrate module。Theme developer module。安裝CKEditor
Wysiwyg module,Wysiwyg原生支持CKEditor。CKEditor,注意版本有限制,3.6.6版本OK,放到/var/www/html/sites/all/libraries/ckeditor中。安裝UEditor
Ueditor for wysiwyg module。Wysiwyg module(Ueditor for wysiwyg module依賴Wysiwyg module)。Libraries API module(Ueditor for wysiwyg module依賴Libraries API module)。UEditor,放到/var/www/html/sites/all/libraries/ueditor中。打開/var/www/html/sites/all/libraries/ueditor/ueditor.all.js,刪除以下代碼。
if(holder.id){ newDiv.id = holder.id; domUtils.removeAttributes(holder,'id');}安裝Views
Views module。Chaos tool suite (ctools) module(Views module依賴Chaos tool suite (ctools) module)。安裝Firefox add-ons
Web Developer。Firebug。新聞熱點
疑難解答