Skip to main content

Posts

bulk download from archive.org cache - wget

--random-wait  - random wait to go slower. -r recursive to recurse in all the subfolders/pages -p we get all images needed to display the page -e robots=off - ignore robots.txt rules -E set as html files with html content -np don't recurse up to parent folders  -U "Opera/9.80 (Windows NT 6.0) Presto/2.12.388 Version/12.14" - useragent mozilla --no-check-certificate - do not check ssl certificates for https connections  ----------------------archive.org.bat---------------------- #random wait, recursive, get all images needed to display the page, #ignore robots.txt rules, set as html files with html content, #don't recurse up to parent folders, useragent mozilla, #do not check ssl certificates (for https). wget --random-wait -r -p -e robots=off -E -np -U "Opera/9.80 (Windows NT 6.0) Presto/2.12.388 Version/12.14"  --no-check-certificate %1  ---------------------- ---------------------- ----------------------  Run: archive.org.bat  https:...

error #1146 - Table 'phpmyadmin.pma__recent' doesn't exist

#1146 - Table 'phpmyadmin.pma__recent' doesn't exist It could happen that the phpmyadmin database doesn't exists and/or phpmyadmin is misconfigured. To fix the problem we just need to import the file "create_tables.sql" that can be found in (any) the phpmyadmin package inside the "examples/" folders. mysq -u root --password=mypassword < create_tables.sql

css centering image in a div in the middle of the page - dirty method

Sample css to center blocks, images within divs. I'm not sure if it's a good method. -css- .centering{ text-align: center; } .centering img{   display: inline-block; /*inline block so that we can align it*/ /*vertical*/ position: absolute; top: 0; bottom: 0; left: 0; right: 0; margin: auto;   /*vertical*/ } ----------- -html- <div class="centering"> <img src="your_image.png" /> </div>

batch script - alert with sound for smart hdd probelms fix

batch script - alert with sound for smart hdd probelms fix smartmontools detect failure at boot This is a small batch script that starts an alert if  a "FAILED" string is found in the smartctl report. @Echo on SET SMARTBIN=smartmontools\smartctl.exe SET REPORTFILE=smartinfo.txt %SMARTBIN% --scan > smartdrives.txt for /F "tokens=1" %%i in (smartdrives.txt) do %SMARTBIN% -s on %%i > %REPORTFILE% && %SMARTBIN% -i %%i >> %REPORTFILE% && %SMARTBIN% -H %%i >> %REPORTFILE% findstr /m "FAILED" %REPORTFILE% if %errorlevel%==0 ( sound\cmdmp3win.exe sound\alert.mp3 ) I personally cannot suggest smatmontools "as is" without the parsing of the S.M.A.R.T. data or full test with smartmontools. After creting this sample script I have faced the reality that my HD smart report was not correct . I prefer to manually check with crystaldisk because it reports as "good" or "problematic" without wasting time a...

IIS 7 Mime type modification without iis 7 manager | fix svg wrong mime type | svg not appearing

I'm quite ignorant about IIS 7 but after using ii7 manager I've noticed that it's easier than expected to modify the preconfigured mime types and *any* (I don't know exactly what can be modified or not) other configuration by adding/modifying "web.config" in the root directory. This sample file web.config is a modification for the svg that have a wrong mime type and the svg are not showing correctly. web.config -------------------------------------------------------------------------- <configuration>     <system .webserver="">         <staticcontent>             <remove fileextension=".svg2">             <remove fileextension=".svg">             <mimemap fileextension=".svg" mimetype="image/svg+xml">       ...