Insert source code in Google Docs

First,  you’d better disable the  auto-capitilization as follow: go to Tools > Preferences and UN-check “Automatically capitalize words.” then, Google docs has many add-on. try to use the Code Pretty Reference

Modify Windows Console Color using C++

Using function SetConsoleTextAttribute() to modify。 Following are the color code and output sample image。  

Linux: HowTo Identify Server ECC Memory Modules

You can get this information by visiting your BIOS setup menu. Another option is to use dmidecode command to dump bios memory information from a shell prompt: # dmidecode –type 16 # dmidecode 2.11 SMBIOS 2.5 present. Handle 0x0016, DMI type 16, 15 bytes Physical Memory Array Location: System Board Or Motherboard Use: System Memory Error Correction Type: Single-bit ECC Maximum Capacity: 64 GB Error Information Handle: Not Provided Number…

OwnCloud Change Data Directory

Stop your webserver Check if your config.php already contains a datadirectory entry. If it does, remember that location (let’s assume it’s ‘/var/www/owncloud/data’ for now). Change or create the “datadirectory” entry in config.php file, so that it points to wherever you want to have your data from now on. Assuming the directory you want to move the data folder to is ‘/media/usbdisk/ocdata’, your config.php should look like this after the change:…

How do I find out what ports are listening on?

sudo lsof -i -P | grep -i “listen”

RGB color table

Basic colors Color HTML / CSS Name Hex Code#RRGGBB Decimal Code(R,G,B) Black #000000 (0,0,0) White #FFFFFF (255,255,255) Red #FF0000 (255,0,0) Lime #00FF00 (0,255,0) Blue #0000FF (0,0,255) Yellow #FFFF00 (255,255,0) Cyan / Aqua #00FFFF (0,255,255) Magenta / Fuchsia #FF00FF (255,0,255) Silver #C0C0C0 (192,192,192) Gray #808080 (128,128,128) Maroon #800000 (128,0,0) Olive #808000 (128,128,0) Green #008000 (0,128,0) Purple #800080 (128,0,128) Teal #008080 (0,128,128) Navy #000080 (0,0,128)


ASCII printable code chart

Primes Table

The First 1,000 Primes

OwnCloud cURL is using an outdated NSS version (NSS/3.19.1 Basic ECC)

Enable Web DAV nano /usr/local/apache/conf/httpd.conf #Include conf/extra/httpd-dav.conf (Uncomment This Line) #LoadModule dav_module modules/ (Uncomment This Line) #LoadModule dav_fs_module modules/ (Uncomment This Line) #LoadModule auth_digest_module modules/ (Uncomment This Line) nano /usr/local/apache/conf.d/owncloud.conf <Limit GET POST> order allow,deny allow from all </Limit> <Limit PUT DELETE> order allow,deny allow from all </Limit> Save and restart apache service httpd restart Upgrade CURL rpm -Uvh yum clean all yum install libcurl and then restart the…

OwnCloud Enable MS Office Online Edit Support

1. Previews currently are only supported on non-windows systems 2. LibreOffice/OpenOffice needs to be installed Ubuntu/Debian -> apt-get install –no-install-recommends libreoffice-writer CentOS -> … entos-6-3/ 3. The correct path to your libreoffice / openoffice binary needs to be configured (check the manual of your system how to find it) 4. Make sure that the user running your webserver/PHP process is allowed to execute this binary 5. The PHP functions…