Author Archives: alain

Page redirection javascript – keep session values

header(“Location:./comehere.php?”.session_name().”=”.session_id()); Use along with session_write_close();

Posted in Uncategorized | Leave a comment

Joomla – Content Encoding Error

After updating php, I got: “Content Encoding Error” for some Joomla site. configuration.php: public $gzip = ‘0’;  

Posted in Uncategorized | Leave a comment

removing files starting with hyphen “-” , from console

rm — —-myfile The “–” after rm prevents processing of more options, so everything after it will not be taken as option.

Posted in Uncategorized | Leave a comment

Javascript – refresh on resize

You need to refresh the browser window automatically when it is resized. You can find plenty of complex solutions for this issue, with javascript, and preferably using jquery, the bigger the library the better. Or you can also put this … Continue reading

Posted in Uncategorized | Leave a comment

Timezone – Debian

Another old one to remember for the road… simple question: How to reconfigure / set the timezone in Debian, without rebooting? dpkg-reconfigure tzdata Soooo annoying to find plenty of solutions on the net that just tell about setting up the … Continue reading

Posted in Uncategorized | Leave a comment

PHP 5.4 on Squeeze DTC GPLHost hosting server

Old stuff, update PHP for squeeze Before going into distribution upgrade for my hosting server: DTC GPLHost running on Squeeze (yeah, I know.) I will update php, using dotdeb repositories https://www.dotdeb.org/instructions/ deb     http://packages.dotdeb.org squeeze all deb-src http://packages.dotdeb.org squeeze all deb     … Continue reading

Posted in Uncategorized | Leave a comment

Java SDK install on Debian, the one from Oracle

And Debian flavored distros.. tested on Mint. This may be a good idea, for example for Android Studio. Found from: http://www.webupd8.org/2014/03/how-to-install-oracle-java-8-in-debian.html First uninstall all Java related previous stuff you may have: apt-get update apt-get upgrade apt-get autoremove apt-get purge ca-certificates-java … Continue reading

Posted in Uncategorized | Leave a comment

Linux auto orient photos with exif data

Easy when you know it: for file in *.JPG; do convert $file -auto-orient oriented-$file; done If you want to apply this to only one image: convert imageinfile -auto-orient imageoutfile

Posted in Uncategorized | Leave a comment

IPTABLES, block IP quick

Very basic IPTables reference How to block an IP address in Linux from ssh: DROP anything coming from the IP address 1.2.3.4: append will put this new rule at the end of your ruleset: iptables -A INPUT -s 1.2.3.4 -j … Continue reading

Posted in Uncategorized | Leave a comment

Windows wireless connection issue – cannot see my router / ssid

I’ve got my wireless setup at home working just fine with my Linux machines (Debian) and for some laptop running Windows 7 could not connect. The SSID is not hidden (better not to), and still could not find it. I … Continue reading

Posted in Uncategorized | Leave a comment