@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info
Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32



Comments:

<0> okay
<1> would be kinda neat if you could interpolate subroutine output into a string
<1> but what if the subroutine returns a list instead of a string?
<1> or a reference?
<1> err a list instead of a scalar, that is
<2> Teratogen: you can get some mileage by overloading ""
<3> Teratogen: join("",mysubroutine()) ?
<0> true
<1> I want subroutine interpolation in Perl 6!
<4> "{ they_already_did_it() }"
<1> cool
<2> perl6 will have a "pretty good" templating system from the beginning
<1> can't wait for Perl 6!
<1> =)
<4> just another year
<3> perl6 will be released just after hurd final



<1> it's gonna be the computer language to end all computer languages, I think
<4> so nearly there really
<5> cfedde, u said, if i'll use server push, i would be possible to ask for the browser is still listening. could u explain how ... or could u give me a keyword, i can google for ?
<4> Teratogen: no, it'll be vastly underused because of perceived complexity
<1> like Perl 5?
<1> =)
<2> synie: if the server gets a socket error you're pretty sure that the browser is gone.
<4> Teratogen: exactly.
<5> okay, i'll have a look :) thanks a lot :)
<2> synie: the problem is that with small pages you're unlikely to get a socket error in time for it to be useful in keeping you from wasting cycles.
<0> sheesh this is too hard
<2> perlmonkey: what are you trying to do?
<3> split the big task into many small tasks and make the browser refresh after each task (<META EQUIV foobar stuf>)
<3> could be just a small frame refreshing every time
<2> the iframe trick or even ajax
<0> cfeddle: I'm trying to make $select on my form subroutine perform a db query (in another subroutine) and return a list of select options and the html code into that form $string
<1> a small frame refreshing can crash some browsers
<3> sort of: print "content-type: foo/bar;" print "<html><head>"; do_task_x(); print "<meta stuff></head><body>...";
<0> I'm making a right pigs ear of this and need to re-think the whole approach
<3> ok, it won't work with lynx
<3> any other browser should be able to manage that
<2> perlmonkey: just bust it up into a small handful of statements.
<0> seems reasonable
<2> Teratogen: there are many thing that can crash some browsers.
<3> perlmonkey: maybe you want to read into this ajax stuff
<2> depends what you realy want.
<0> yes
<0> I'm just having to fight the code every inch of the way and its not fun.
<0> I can't believe that
<2> perlmonkey: work in small testable steps, and write tests.
<0> I moved my db query code block into my form subroutine and now for some reason it craps out!
<0> Can't call method "query" on an undefined value at (tag 'perl') line 75
<0> sheesh
<2> the whole MVC thing lives around here somewhere.
<3> $dbh is not initialized
<3> or $sth or something
<0> yet I can cut and paste that outside the sub and it works fine
<0> oh
<0> doesnt make sense to me
<3> the sub is called before you init $dbh
<0> ah
<3> you can try it with: print "sub called\n"; in the first line of the sub and print "DBH init\n"; right after $dbh = DBI->connect
<5> cfedde, what do u mean with small pages ? the script runs about 5 mins, after the browser was closed, till the process gets killed.
<0> thanks
<3> synie: split it into 10 tasks each running 30 seconds, synie
<2> synie: sorry I guess I have lost track what you are talking about.
<5> cfedde, about server-push. i run a while for about x minutes. but if i close the browser, the process runs anyway ... for about 5 mins.
<5> whoever, do u mean to break the server-push and refresh the site ?
<3> synie: as i said before... make the page refresh after each short process and always change a variable that starts the next process
<5> okay, i know what u mean ...
<6> "perlmonkey" at 82.37.56.210 pasted "works outside sub, but not inside. why?" (8 lines, 327B) at http://sial.org/pbot/17463
<3> <meta equiv:"refresh:foo.pl?step=10"> , next refresh uses step=11 etc
<3> perlmonkey: did you try what i said: print "sub called\n"; in the first line of the sub and print "DBH init\n"; right after $dbh = DBI->connect
<5> but imagine, there r lot of people, running the script. and the server would be bonded, as to use only server-push
<0> whoever: I will try that now
<5> wah, i mean the server would be bonded much more
<3> synie: the server will be dead because all users will click refresh 50 times because the response is so slow :)
<3> so every user will start 50 5minute tasks
<0> whoever: i cant use print statement in my environment
<3> perlmonkey: use something to output... print STDERR to print to apache error log or whatever
<0> ok



<3> or open(LOG,">>mylogfile.log"); print LOG "i'm here"; print LOG "i'm there"; close(LOG);
<0> phew
<0> I can get the sub to print a msg to browser
<3> print to STDERR and check error log later
<0> the rest doesnt work
<3> STDERR works
<0> Can't locate object method "connect" via package "DBI" (perhaps you forgot to load "DBI"?) at (tag 'perl') line 71
<3> that would be a solution to your problem :p
<0> I can do db queries tho using my own code
<0> hehe
<3> i guess you have to check your whole code
<7> if i want to "daemonize" a script, is there a cleaner way than (re)opening STDERR, STDOUT, STDIN (say using /dev/null); fork()ing ; exiting the parent and POSIX::setsid()ing the child?
<0> i can already do queries in this code tho, allbeit in a slightly different way to the usual perl method
<0> this is a special environment im coding in tho
<0> its time to think outside the box eh
<0> maybe I should simplify what I'm trying to do
<3> yup, create the stuff in a normal environment first
<3> THEN adapt it to the special stuff
<0> yes
<8> guys
<8> I use WWW::Mechanize module
<8> how can I remove warning like <input> outside <form> ....
<8> ?
<9> fix your html? :)
<6> "janhaa" at 62.113.132.3 pasted "formating issue" (8 lines, 99B) at http://sial.org/pbot/17464
<10> ^ can someone give me feedback on that?
<0> god dammit
<8> jink, it is not my html
<0> i figured out why my db query was failing
<11> Hi - I am looking at adding a simple GUI to a perl application that currently uses perlcurses. I am thinking Perl/tk - is this still the best choice or are there other alternatives? I'd like to keep it all perl if possible. Thanks
<3> janhaa: does it compile?
<3> (in other words, does it run)
<3> +?
<8> is any way to fix it without editing html ?
<3> perlmonkey: so?
<0> well..
<10> whoever, yes it does run, but i'm mostly conserned about the formatting question. does it _look_ ok? :)
<0> in this special environment im working in, perl code is contained in page with [perl] tag, and if you want to query a db, you have to declare the table with [perl table=dbtable] else it wont work
<3> i've seen worse... don't care about formatting, janhaa....
<10> :S
<10> i do :/
<0> which kinda sux, but I need to query more than one table
<3> janhaa: i prefer paranthesis, split(/foo/,$bar); instead of split /foo/,$bar... but there are about as many opinions about correct formatting in this channel as there are users...
<3> maybe even more opinions than users :p
<10> yeah, but i'm a novice at that point, so i'm open for suggest - but i don't want to start a war :(
<3> just use a style you think you can understand next year
<10> that's my problem :/
<3> start with a style you understand a few minutes later when you re-read the part :p
<3> and use comments :)
<12> perldoc perlstyle
<13> perlstyle - Perl style guide. To access this perldoc please type, at a command line, 'perldoc perlstyle'. You may also find it at http://perldoc.perl.org/perlstyle.html
<9> Sir_J: $mech->quiet(1) ?
<8> I've tried that
<8> it doesn't work
<12> I love "doesn't work"
<8> on warn => undef and onerror => undef also doesn't works :(
<14> Hello, Can I call a SOA function from perl?
<4> what is a SOA function?
<14> http://en.wikipedia.org/wiki/Service_Oriented_Architecture
<14> i dont know really, i have 37k java code... I should do something similar what this java thing does. (in perl)
<15> Buzzword bingo!
<16> hello
<4> vlajos: Are you wanting to call Java code forom perl?
<4> Perl is distributed without any knowledge of current management jargon thus ensuring that it doesn't need continually upgraded.
<7> integral: lol
<14> integral: No. But if there isnt any other solution then i had to.
<4> Solution for doing *what*?
<14> at first i would like create something in perl doing the same as the java does
<4> What do you have other than a buzzword?
<14> 37k java code
<4> okay, learn perl and then write code that does the same things.
<14> :-)
<4> It may take a while.


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #perl
or
Go to some related logs:

iptables: match `ipp2p' v1.3.5
sata_sil subdriver
paligamy
gmail atom C# 1.1
perl strip unprintable characters
super_L doesnt work
akiga voip
#linux
#suse
#gentoo



Home  |  disclaimer  |  contact  |  submit quotes