miércoles, agosto 31, 2005

Modificar el "Mozilla Rich Text Editing" para que permita copy + paste

Setting Prefs for the Mozilla Rich Text Editing Demo

To protect users' private information, unprivileged scripts cannot invoke the Cut, Copy, and Paste commands in the Mozilla

rich text editor, so the corresponding buttons on the Mozilla Rich Text Editing demo page will not work. To enable these

functions for purposes of the demo, you must modify your browser preferences.

1. Quit Mozilla. If you have Quick Launch running (in Windows, an icon in the toolbar), quit that too.

2. Find your Mozilla profile directory. On Windows, this is often located in c://WINNT/Profiles//Application Data/Mozilla. (See also editing configuration files for more info on locating your profile folder.)

En mi caso es: C:\Documents and Settings\Alejandro\Datos de programa\Mozilla\Firefox\Profiles\4unkc087.default

3. Open the user.js file from that directory in a text editor. If there's no user.js file, create one.

Por default no existe, yo cree uno

4. Add these lines to user.js:

user_pref("capability.policy.policynames", "allowclipboard");
user_pref("capability.policy.allowclipboard.sites", "http://www.mozilla.org");
user_pref("capability.policy.allowclipboard.Clipboard.cutcopy", "allAccess");
user_pref("capability.policy.allowclipboard.Clipboard.paste", "allAccess");

Cambiar el url de la segunda linea por el url que corresponde, en mi caso: http://claroline.uc.edu.py

5. Save the file, and restart Mozilla. The Clipboard buttons should now function.

Etiquetas: ,

USO DE GBAK (INTERBASE / FIREBIRD)

# para backupear una base de datos interbase.
# -B(ACKUP_DATABASE) backup database to file
# -T(RANSPORTABLE) transportable backup -- data in XDR format
# -V(ERIFY) report each action taken
# -Z print version number
# -Y redirect/suppress status message output
# -C(REATE_DATABASE) create database from backup file
# -R(EPLACE_DATABASE) replace database from backup file



# Ejemplos:

# Hacer BK
rm /tmp/backup.log; gbak -b -t -v -user SYSDBA -pas xxx-y /tmp/backup.log localhost:/opt/interbase/data/tape-rk.gdb /tmp/tape-rk.gbk
gbak -b -t -v -user SYSDBA -pas xxx-y /tmp/backup.log localhost:/opt/interbase/data/tape116-5.gdb

/tmp/tape-backup-116-5.gbk

#verificar
cat /tmp/backup.log


# Restaurar BK
gbak -r -c -v -z -user SYSDBA -pas xxx -y /tmp/restore-preparar-lapatria.log /tmp/tape-backup-preparar-lapatria.gbk

localhost:/opt/interbase/data/tape114-1.gdb

#para reemplazar bd
gbak -r -c -v -z -user SYSDBA -pas xxxx -y /tmp/restore-116-5.log /tmp/tape-backup-116-5.gbk

localhost:/opt/interbase/data/tape-desarrollo.gdb

#para crear bd
rm /tmp/restore-116-5.log;
gbak -c -v -z -user SYSDBA -pas xxxx -y /tmp/restore-116-5.log /tmp/tape-rk.gbk localhost:/opt/interbase/data/tape-desarrollo.gdb

gbak -r -c -v -z -user SYSDBA -pas xxx -y /tmp/restaurar-toluca.log toluca.gbk

localhost:/opt/interbase/data/TOLUCA.TRAIDO.GDB

gbak -c -v toluca.gbk weallgodown.gdb

Additionally, there is a command-line tool gsplit that filters the
output of gbak and writes to multiple files on disk. This permits you
to back up a multifile database when the backup file is larger than
the operating system maximum.

Etiquetas: , ,