How To Solve the LOAD DATA INFILE Error from –secure-file-priv

Author: , June 12th, 2019

The Problem Tried to load a Tab-delimited text file into MuSQL 5.6.43 and got the following error: mysql> LOAD DATA INFILE ‘sample.txt’ INTO TABLE test_table; ERROR 1290 (HY000): The MySQL server is running with the –secure-file-priv option so it cannot execute this statement Solution One mysql> SHOW VARIABLES LIKE “secure_file_priv”; Copy the file into the […]

How To Show Filenames With git log

Author: , June 3rd, 2019

To display the filenames included in each commit, just add the –name-only argument to git log:

How To rsync Only Specific File Extensions

Author: , February 5th, 2017

rsync -avzn –progress –include=’*.png’ –include=’*/’ –exclude=’*’ /the/source/path/ user@theServer:/the/target/path/

How To Fix a “Corrupted index cache file” Error in Dovecot

Author: , June 17th, 2016

Jun 17 00:02:45 inbound dovecot: IMAP(yourName): Corrupted index cache file /home/yourName/Maildir/dovecot.index.cache: invalid record size

As always, YMMV. Proceed with caution.

How To Find the Template File Name per Page in WordPress using SQL

Author: , September 5th, 2015

How To Protect a Single File in Apache

Author: , June 30th, 2013

In order to protect a file, just replace the Directory directive with Files:

How To Clear An HTML File Input Field

Author: , July 19th, 2012

An HTML file input can’t be cleared by normal means (i.e. setting the value to null or an empty string) because of browser security restrictions. In most browsers, setting a null value attribute either will have no effect or cause an error. Creating a new element that clones the old element and swap the two […]