http://digitalpbk.com/perl/how-remove-element-hash-or-array
= ('a','b','c','d','e');
print @array;
map {delete $array[$_] if $_ eq 'c' } @array; #All 'c' would be deleted.
print @array;
PERL
Software ...
Published 2 years, 1 month ago
http://digitalpbk.com/utorrent/utorrent-22-utp-slow-downloads-disable
management (uTP).
Illustrated below:
Hope uTP is redesigned to get better results for both users.
Software ...
Published 1 year, 4 months ago
http://digitalpbk.com/less-css/less-css-compiler-windows-lesscexe
of things.
Like it adds a less extension to the filename you passed, even though you dont have a less extension to the actual file.
Source code
The source code is forked on github, Check it out
https://github.com/madaboutcode/dotless
:)
Thanks to Ajeesh Mohan for the new code that accepts less from std input.
Django
CSS
Software ...
Published 1 year ago
http://digitalpbk.com/perl/script-fetch-pnr-status-reservation-train-indian-railways
,3);
$part2 = substr($pnr,3);
print " Fetching for PNR $part1-$part2 \n\n";
$mech->submit_form(
form_number => 1,
fields => {
lccp_pnrno1 => $part1,
lccp_pnrno2 => $part2,
}
);
$content = $mech->response->content;
$content =~ s|(.*?)|$1|si;
$content =~ s|||sig;
if($content =~ m|(Passenger [1-6].*?)Chart|sig) {
print $1;
}
PERL
Software ...
Published 2 years, 3 months ago
http://digitalpbk.com/code-ignitor/removing-indexphp-url
"No input file specified." error on all pages, (such as on Dreamhost hosting), the error can be resolved by changing the Htaccess rules to
RewriteEngine on
# Rewrite URLs of the form 'x' to the form 'index.php?q=x'.
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ index.php?/$1 [L,QSA]
:)
PHP
Code Igniter
Software ...
Published 2 years, 2 months ago
http://digitalpbk.com/perl/solve-netmysql-hang-problem-if-database-result-has-only-1-row-or-empty
the following function to replace the MySQL.pm function : _has_next_packet.
sub _has_next_packet
{
my $self = shift;
return (substr($_[0], -5) ne "\xfe\0\0\x02\x00" and substr($_[0], -5) ne "\xfe\0\0\x22\x00");
}
Now the script with Net::MySQL module should not hang :)
PERL
MySQL
Software ...
Published 2 years, 1 month ago
http://digitalpbk.com/hardware/sony-vaio-cw-vpccw26fg-edid-extended-display-identification-data
1D 38 0B 00 00 20 20 20 20 20 00 00 48
This file is used by drivers to detect monitor capabilities. This file can be used in linux Xorg.conf to detect this monitor, in case the monitor doesnt get detected as in the case of Sony Vaio CW on Ubuntu.
Attached is the binary format EDID file.
Sony Vaio
Software ...
Published 2 years, 1 month ago
http://digitalpbk.com/stock/google-finance-get-stock-quote-realtime
every 30 seconds.
Meanwhile all ye mates try something interesting with the stock quotes
(Than making profits and losses :) )
Dont forget to ping me on your updates. Post a comment.
Thank you Google.
Google
Python
Finance
Software ...
Published 1 year, 1 month ago
http://digitalpbk.blogspot.com/2009/05/ssh-proxy-windows-linux-orkut-bypass.html
, such as Orkut, Facebook, YouTube or any other website, you name it :).On WindowsSetting up an SSH Tunnel on Linux is obvious and I will describe it anyway, but lets see how it is done on Windows first. For Windows you needPuttyA BrowserThat's about it. Putty is a free
software you can download for free.Next run "Putty.exe", You can see a screen as shown below:In the Hostname (or IP Address) textbox, provide the IP or Domain of the SSH server. You can get some free SSH servers out ...
Published 2 years, 12 months ago
http://digitalpbk.blogspot.com/2009/04/jwgkvsqvmx-conficker-virus-manual.html
Conficker disables the Background Intelligent Transfer Service (BITS) and Windows Automatic Updates. So If you find these services disabled, be alert. (To checkout what services are running and their statuses Run > services.msc.Follow these steps to detect and remove Conficker virus:Run regedit.exe registry editorGoto HKEY_LOCAL_MACHINE\
Software\Microsoft\WindowsNT\CurrentVersion\SvcHost\netsvcsDouble click the key to see if there is a random value at its end.Note the "zbtthjd" at the end ...
Published 3 years, 1 month ago