60 PerlMonks - Newest Nodes New nodes appearing on PerlMonks http://perlmonks.org/index.pl?node_id=30175 http://blogs.law.harvard.edu/tech/rss PerlMonks Newest Nodes XML Generator 961 PerlMonks 2014-12-22 16:44:51 rss,clean Mon Dec 22 05:44:51 2014 30 20141222054451 Mon Dec 22 05:44:51 2014 http://perlmonks.org/ Anonymous Monk HTML encoding UTF-8 characters in an HTML block lilalfyalien http://perlmonks.org/index.pl?node_id=1111038 Hi, I have the following scenario: I have some XML like (psuedo- not real data): ... perlquestion Mon, 22 Dec 2014 16:23:15 +0000 http://perlmonks.org/index.pl?node_id=1111038 1111038 1111034 2014-12-22 11:23:15 lilalfyalien maybe, a corrupt selected entry in Tk::BrowseEntry igoryonya http://perlmonks.org/index.pl?node_id=1111024 The basic representation of my prog: my %file_system = ( '/path/subpath1/'=><a href="?node=%27file1%27%2C%20%27file2%27%2C%20%27file3%27">&#39;file1&#39;, &#39;file2&#39;, &#39;file3&#39;</a>, '/path/=><a href="?node=%27fil01%27%2C%20%27fil02%27%2C%20%27fil03%27%2C%20%27fil04%27%2C%20%27fil05%27">&#39;fil01&#39;, &#39;fil02&#39;, &#39;fil03&#39;, &#39;fil04&#39;, &#39;fil05&#39;</a>, '/'=><a href="?node=%27f001%27%2C%20%27f002%27">&#39;f001&#39;, &#39;f002&#39;</a> )... perlquestion Mon, 22 Dec 2014 14:40:17 +0000 http://perlmonks.org/index.pl?node_id=1111024 1111024 810715 2014-12-22 09:40:17 igoryonya How to handel sqlplus error in perl script. Ankur_kuls http://perlmonks.org/index.pl?node_id=1111016 Hi, I have a perl script which uses sqlplus for data processing. below is a part of my code... ##### Generating log file--- my $logfile = "${basePath}/VoucherStateChange.$filedate.l... perlquestion Mon, 22 Dec 2014 12:51:32 +0000 http://perlmonks.org/index.pl?node_id=1111016 1111016 1084250 2014-12-22 07:51:32 Ankur_kuls Re^3: maybe, a corrupt selected entry in Tk::BrowseEntry Corion http://perlmonks.org/index.pl?node_id=1111037 Most likely, you have two strings that are similar in how they display but are different in how they are encoded. The easiest way to get two such strings is by reading one from a file and the other... note Mon, 22 Dec 2014 16:22:46 +0000 http://perlmonks.org/index.pl?node_id=1111037 1111037 5348 2014-12-22 11:22:46 Corion Re: simple as math LanX http://perlmonks.org/index.pl?node_id=1111036 It's time again... <a href="?node_id=1068332">UP!</a> =) Cheers Rolf (addicted to the Perl Programming Language and &#91;http://i.dailymail.co.uk/... note Mon, 22 Dec 2014 16:17:56 +0000 http://perlmonks.org/index.pl?node_id=1111036 1111036 708738 2014-12-22 11:17:56 LanX Re^4: maybe, a corrupt selected entry in Tk::BrowseEntry Anonymous Monk http://perlmonks.org/index.pl?node_id=1111033 hash keys... or array values :)... note Mon, 22 Dec 2014 15:45:14 +0000 http://perlmonks.org/index.pl?node_id=1111033 1111033 961 2014-12-22 10:45:14 Anonymous Monk Re^3: maybe, a corrupt selected entry in Tk::BrowseEntry Anonymous Monk http://perlmonks.org/index.pl?node_id=1111032 Dump array keys too. So far it looks like an encoding issue to me, btw...... note Mon, 22 Dec 2014 15:43:22 +0000 http://perlmonks.org/index.pl?node_id=1111032 1111032 961 2014-12-22 10:43:22 Anonymous Monk Re^2: maybe, a corrupt selected entry in Tk::BrowseEntry igoryonya http://perlmonks.org/index.pl?node_id=1111031 Yea, I will check out, what Devel Peek will Dump for me. Thanx. I will edit the original question to post my results.... note Mon, 22 Dec 2014 15:39:37 +0000 http://perlmonks.org/index.pl?node_id=1111031 1111031 810715 2014-12-22 10:39:37 igoryonya Re^2: maybe, a corrupt selected entry in Tk::BrowseEntry igoryonya http://perlmonks.org/index.pl?node_id=1111030 Please show us what $cpath actually contains, instead of describing it as "visually the same". See $Data::Dumper::Useqq for how to make Data::Dumper output invisible characters. ... note Mon, 22 Dec 2014 15:31:20 +0000 http://perlmonks.org/index.pl?node_id=1111030 1111030 810715 2014-12-22 10:31:20 igoryonya Re^5: Can't install LWP::Protocol::https::Socket jimhallsun http://perlmonks.org/index.pl?node_id=1111029 Hi, I just wanted to confirm (due to paranoia) that this problem is still outstanding as identified in https://rt.cpan.org/Public/Bug/Display.html?id=67001 I modified that test apach... note Mon, 22 Dec 2014 15:15:08 +0000 http://perlmonks.org/index.pl?node_id=1111029 1111029 992078 2014-12-22 10:15:08 jimhallsun Re^4: Edit XML through XML Compile chenino http://perlmonks.org/index.pl?node_id=1111028 Well, maybe does not work out wasn't the right choice of words, i am sorry for this. Yes, my question is as General as you answered it, but you seemed to got me wrong in one point. I... note Mon, 22 Dec 2014 15:10:24 +0000 http://perlmonks.org/index.pl?node_id=1111028 1111028 1110858 2014-12-22 10:10:24 chenino Re^11: Private temporal files on Windows BrowserUk http://perlmonks.org/index.pl?node_id=1111027 <a href="?node=salva">salva</a>, I strongly suggest you add FILE_ATTRIBUTE_HIDDEN to the existing FILE_ATTRIBUTE_TEMPORARY on the CreateFile(). Also, if you add: ... note Mon, 22 Dec 2014 14:59:18 +0000 http://perlmonks.org/index.pl?node_id=1111027 1111027 171588 2014-12-22 09:59:18 BrowserUk Re: maybe, a corrupt selected entry in Tk::BrowseEntry Anonymous Monk http://perlmonks.org/index.pl?node_id=1111026 If I iterate keys %file_system, I see the path, that's in $cpath var, but for some reason, it doesn't match. Well, this is what <a href="http://perldoc.perl.org/Devel/Peek.html">Devel::Peek</a> is for... I'd try ... note Mon, 22 Dec 2014 14:50:32 +0000 http://perlmonks.org/index.pl?node_id=1111026 1111026 961 2014-12-22 09:50:32 Anonymous Monk Re: maybe, a corrupt selected entry in Tk::BrowseEntry Corion http://perlmonks.org/index.pl?node_id=1111025 Please show us what $cpath actually contains, instead of describing it as "visually the same". See $<a href="http://search.cpan.org/perldoc?Data%3A%3ADumper">Data::Dumper</a>::Useqq for how to make Data::Dumper output invisible charact... note Mon, 22 Dec 2014 14:47:19 +0000 http://perlmonks.org/index.pl?node_id=1111025 1111025 5348 2014-12-22 09:47:19 Corion Re: Deleting records from an array Lotus1 http://perlmonks.org/index.pl?node_id=1111023 You could avoid the loop within a loop issue if you would loop through the array one time and lookup the hash elements as you go. Instead of doing if ($fields<a href="?node=3">3</a> =~ $key) { you can d... note Mon, 22 Dec 2014 14:20:11 +0000 http://perlmonks.org/index.pl?node_id=1111023 1111023 922586 2014-12-22 09:20:11 Lotus1 Re^3: Redefined import method and EXPORT not working Corion http://perlmonks.org/index.pl?node_id=1111022 Please, don't inherit from <a href="http://search.cpan.org/perldoc?Exporter">Exporter</a>. Just use use Exporter 'import';. Inheritance as a way of getting access to methods of a module is not what I consider a clean approach.... note Mon, 22 Dec 2014 14:10:57 +0000 http://perlmonks.org/index.pl?node_id=1111022 1111022 5348 2014-12-22 09:10:57 Corion Re: Need help ! BillKSmith http://perlmonks.org/index.pl?node_id=1111021 You can use the 'state' feature' (refer: perldoc perlfunc) rather than the extra block to limit the scope of $last. use feature 'state'; sub do_stuff { state $last=999;... note Mon, 22 Dec 2014 14:10:48 +0000 http://perlmonks.org/index.pl?node_id=1111021 1111021 957973 2014-12-22 09:10:48 BillKSmith Re^2: Deleting records from an array Anonymous Monk http://perlmonks.org/index.pl?node_id=1111020 Also, it's very efficient. I was curious about that and decided to test it. Splice is more efficient then I thought but it's still not as fast as undef with big arrays. ... note Mon, 22 Dec 2014 14:10:42 +0000 http://perlmonks.org/index.pl?node_id=1111020 1111020 961 2014-12-22 09:10:42 Anonymous Monk Re^5: Using Perl FTP to write a string variable as a file toohoo http://perlmonks.org/index.pl?node_id=1111019 Dear poj, many thanks, this works in my test script now. will try to move this to my live script. Thanks again and best regards, Thomas PS: I guess a : binmode( $... note Mon, 22 Dec 2014 13:52:05 +0000 http://perlmonks.org/index.pl?node_id=1111019 1111019 835787 2014-12-22 08:52:05 toohoo Re: Why Makefile.PL uses uppercase extension? MidLifeXis http://perlmonks.org/index.pl?node_id=1111018 In the context of building perl things for installation, .PL files are executed to generate their respective targets. On the other hand, .pl files are just copied. References: ... note Mon, 22 Dec 2014 13:45:21 +0000 http://perlmonks.org/index.pl?node_id=1111018 1111018 272364 2014-12-22 08:45:21 MidLifeXis Re^4: Using Perl FTP to write a string variable as a file poj http://perlmonks.org/index.pl?node_id=1111017 Try using a lexical filehandle open( my $FH, "put( $FH, $remotefilename ) or die "put... note Mon, 22 Dec 2014 13:25:33 +0000 http://perlmonks.org/index.pl?node_id=1111017 1111017 221725 2014-12-22 08:25:33 poj Re: Deleting records from an array igoryonya http://perlmonks.org/index.pl?node_id=1111015 Use splice, although, some might not recommend it. I use it extensively, when working with arrays, since, it greatly simplifies and shortens your code. Also, it's very efficient. Your code... note Mon, 22 Dec 2014 12:29:34 +0000 http://perlmonks.org/index.pl?node_id=1111015 1111015 810715 2014-12-22 07:29:34 igoryonya Re^11: Private temporal files on Windows BrowserUk http://perlmonks.org/index.pl?node_id=1111014 BTW, I am unable to make the latest version of ActivePerl (64bits) work together with the latest VisualStudio in order to build modules. Looking at perl -V it looks as if they wer... note Mon, 22 Dec 2014 12:13:57 +0000 http://perlmonks.org/index.pl?node_id=1111014 1111014 171588 2014-12-22 07:13:57 BrowserUk Re^10: Private temporal files on Windows salva http://perlmonks.org/index.pl?node_id=1111013 I have pushed a new version with your fixes. BTW, I am unable to make the latest version of ActivePerl (64bits) work together with the latest VisualStudio in order to build modules. Lookin... note Mon, 22 Dec 2014 12:03:01 +0000 http://perlmonks.org/index.pl?node_id=1111013 1111013 446266 2014-12-22 07:03:01 salva Re: comma(or fat comma) in 'use' directive Anonymous Monk http://perlmonks.org/index.pl?node_id=1111012 As <a href="?node=AnomalousMonk">AnomalousMonk</a> and <a href="?node=LanX">LanX</a> already mentioned above, the parameters after the module name (and optional version) in <a href="http://perldoc.perl.org/functions/use.html">use</a> are just the parameters to the import method from the packag... note Mon, 22 Dec 2014 11:20:26 +0000 http://perlmonks.org/index.pl?node_id=1111012 1111012 961 2014-12-22 06:20:26 Anonymous Monk Re^3: Using Perl FTP to write a string variable as a file toohoo http://perlmonks.org/index.pl?node_id=1111011 Hello again ... I have tested it with a testscript. It does not work. The error message is: Cannot open Local file FH: No such file or directory at test-ftpscalar.pl line 54 ... note Mon, 22 Dec 2014 11:16:42 +0000 http://perlmonks.org/index.pl?node_id=1111011 1111011 835787 2014-12-22 06:16:42 toohoo Re^2: Redefined import method and EXPORT not working tobyink http://perlmonks.org/index.pl?node_id=1111010 That seems like an over-complicated way of doing: use Exporter (); sub import { print "Imported\n"; goto \&Exporter::import; } ... note Mon, 22 Dec 2014 11:03:20 +0000 http://perlmonks.org/index.pl?node_id=1111010 1111010 757127 2014-12-22 06:03:20 tobyink lilalfyalien lilalfyalien http://perlmonks.org/index.pl?node_id=1111034 user Mon, 22 Dec 2014 15:55:38 +0000 http://perlmonks.org/index.pl?node_id=1111034 1111034 1111034 2014-12-22 10:55:38 lilalfyalien