內容簡介
這是一個 CSS 即時編輯器,可以讓您預覽 CSS 的即時變化並保存它的變更。
它會保存每次儲存的日期備份,因此如果它破壞了網站,您可以回到先前的版本。您也應該定期清除這些備份。
這是由 Drupal 模組 Live CSS 的 guybedford(http://drupal.org/user/746802)移植而來。
現在使用 ACE 編輯器(http://ace.ajax.org/)。
測試於 WordPress 3.6,但需要進一步的測試!
=capabilities.php 的問題(非錯誤)已解決 !=
現在我正確地建立了一個 wp_loaded 鉤子動作來初始化插件,再檢查使用者是否可以「刪除主題」(僅限管理員功能),因此插件僅在您是管理員時才能使用。
無需修改 capabilities.php 或任何其他內容。
某些用戶在安裝插件後經歷了無法訪問他們的網站的問題。
所有這些都似乎是與 capabilities.php 檔案的問題有關,該檔案在此處進行了討論:
https://wordpress.org/support/topic/fatal-error-call-to-undefined-function-wp_get_current_user-4?replies=32
它適合我,而且完美無缺,但仍然需要測試!
Hola Mundo!
此插件基於[guybedford](http://drupal.org/user/746802) 的 [Drupal Live CSS](http://drupal.org/project/live_css) 模組。
這是一個 CSS 編輯器,可讓您即時編輯您網站的所有 CSS 樣式,預覽更改並即時保存。
它旨在用於設計網站,因此建議您在完成後將其停用或卸載。每次保存更改都會生成一個日期備份,以便在需要時可以返回先前的版本。
使用 ACE 編輯器。
只有管理員才能使用該插件。
重要!
在測試插件之前,請務必備份 CSS 文件!
儘管插件會在修改的文件所在目錄中自動生成日期備份,但最好還是在開始進行更改之前創建一個通用狀態的備份。
如果儲存或備份時出現任何問題,將顯示該文件的路徑、備份的路徑和任何錯誤消息。最有可能的問題是權限。您想要編輯的 CSS 應該具有 755 的寫入權限。
安裝
安裝與 WordPress 插件的典型安裝方式相同。將 ZIP 文件解壓到 wp-content/plugins 中即可。不需要更改主題或進行其他操作,只需從管理面板啟用它即可。
它沒有任何選項或面板頁面。
在 WordPress 3.3.2 上進行測試,您必須是管理員才能使用它。
現在使用 wp_loaded 鉤子解決了先前版本中在此處進行了討論的問題:https://wordpress.org/support/topic/fatal-error-call-to-undefined-function-wp_get_current_user-4?replies=32
更多資訊
http://drupal.org/project/live_css Live CSS
http://drupal.org/user/746802 guybedford
http://drupal.org/user/78427
http://mozillalabs.com/skywriter/2011/01/18/mozilla-skywriter-has-been-merged-into-ace/
http://www.ajax.org/
http://ace.ajax.org/
https://codex.wordpress.org/AJAX_in_Plugins
http://briancray.com/2009/08/19/wordpress-head-element/
http://www.devlounge.net/code/using-ajax-with-your-wordpress-plugin
http://amiworks.co.in/talk/simplified-ajax-for-wordpress-plugin-developers-using-jquery/
http://drupal.org/project/cssedit Realtime CSS Editor
http
外掛標籤
開發者團隊
原文外掛簡介
A CSS live Editor that allows you to preview realtime CSS changes and then save your changes.
It saves dated backups of each save, so you can go back if it breaks, and you should erase backups once on a while.
It’s a port from a Drupal module Live CSS http://drupal.org/project/live_css by guybedford http://drupal.org/user/746802
Now using ACE editor http://ace.ajax.org/
Tested on WordPress 3.6. But needs more testing !
=capabilities.php problem (not bug) SOLVED !=
Ok, now I did the correct thing and created an action to the wp_loaded hook to init the plugin, then,
check whether the user can “erase themes” which is an Admin capability only, so the plugin only works if you are an admin.
No need to modify the capabilities.php nor anything else.
Some users have had problems in former 12.05 release with their site being inaccesible after installing the plugin.
It all seemed to be part of the same problem with the capabilities.php file that is discussed here:
https://wordpress.org/support/topic/fatal-error-call-to-undefined-function-wp_get_current_user-4?replies=32
It works nice and perfect for me, but still needs testing !!!
Hola mundo !
Este plugin está basado en el módulo de [Drupal Live CSS] (http://drupal.org/project/live_css) de [guybedford] (http://drupal.org/user/746802)
Es un editor de CSS que te permite editar en directo todas las hojas de estilo CSS de tu web, ver los cambios y guardar sobre la marcha.
Está pensada para usarla al diseñar la web, por lo que conviene desactivarlo o desinstalarlo una vez terminada. Cada vez que se guardan los cambios se genera una copia de seguridad fechada, para que puedas volver atrás si hace falta.
Utiliza ACE como editor.
Sólo los administradores pueden usar el plugin.
Importante !!!
Hacer copia de respaldo de los archivos CSS antes de probarlo !
Aunque el plugin genera automáticamente copias de seguridad fechadas en el mismo directorio en que estén los archivos modificados, siempre conviene tener una copia del estado general de la cosa antes de empezar a trastear.
Si no funciona al guardar o hacer la copia de seguridad aparece un mensaje con las rutas del archivo que se intentaba modificar, la de la copia de seguridad y tal vez un mensaje de error. Lo más seguro es que el problema sea de permisos. Los CSS que quieras editar deberían tener permiso de escritura 755.
Instalación
La instalación es la típica de cualquier plugin de wordpress. Desempaquetar el zip en wp-content/plugins, y listo. No hay que tocar los temas ni hacer nada más que activarlo desde el panel de administración.
No tiene opciones ni página propia en el panel de administración.
Probado en WordPress 3.3.2, tienes que ser un administrador para poder usarlo.
Utiliza ahora el hook wp_loaded que arregla el problema de la versión anterior que se discutía aquí: https://wordpress.org/support/topic/fatal-error-call-to-undefined-function-wp_get_current_user-4?replies=32
Más información
http://drupal.org/project/live_css Live CSS
http://drupal.org/user/746802 guybedford
http://drupal.org/user/78427
http://mozillalabs.com/skywriter/2011/01/18/mozilla-skywriter-has-been-merged-into-ace/
http://www.ajax.org/
http://ace.ajax.org/
https://codex.wordpress.org/AJAX_in_Plugins
http://briancray.com/2009/08/19/wordpress-head-element/
http://www.devlounge.net/code/using-ajax-with-your-wordpress-plugin
http://amiworks.co.in/talk/simplified-ajax-for-wordpress-plugin-developers-using-jquery/
http://drupal.org/project/cssedit Realtime CSS Editor
http://drupal.org/user/78427 tjholowaychuk
