IRC Networks
Irc Logs Stats
Start date: 2007-09-27 02:48:27
Last update: 2008-10-24 20:19:38
Channels: 41
Logged Lines: 6230436
Size: 1982.49 MB
Powered by
Channel Info
Network: freenodeChannel: #php |
Search in www.irclog.org
Log from #php at freenode 2006-06-01
[00:00]<wjlllrws>Kartagis: I edon't know... Is it?
[00:00]<axzjgjs-wjzc>hi people.
[00:01]<kzzvzrys>Wolfpaws: I guess not because it says URL not found
[00:01]<kzzvzrys>how should it be?
[00:01]<wjlllrws><?php echo $yourstuffhere ?>
[00:02]<axzjgjs-wjzc>I need to use preg_replace to put one div after my body tag like as vim.
[00:02]<czcnzlzvvyz>is it possible
[00:02]<kzzvzrys>oh, right
[00:02]<wjlllrws>no
[00:03]<czcnzlzvvyz>if in class isn't defined var foot;
[00:03]<kzzvzrys>thanks
[00:03]<axzjgjs-wjzc>s/\(<body.*>\)/\1<div>/
[00:03]<czcnzlzvvyz>can it be defined outside?
[00:03]<wjlllrws>!+enter
[00:03]<lxl-2jv>Don't use the enter key as punctuation. Think in complete thoughts, then type.
[00:03]<czcnzlzvvyz>outside from class?
[00:03]<wjlllrws>CakerLatvia: no.
[00:03]<axzjgjs-wjzc>but, I don't know special char to use in preg_replace that identify search string, somebody can help me?
[00:03]<czcnzlzvvyz>Wolfpaws so it must be defined in class like var $foo; ?
[00:04]<wjlllrws>CakerLatvia: No, you can declare it outside the class, but when you do, the variable is not usavle within the object.
[00:05]<czcnzlzvvyz>Wolfpaws i can check all class vars with get_class_vars() ok?
[00:05]<wjlllrws>chronos-work: have you read the manuals?
[00:05]<axzjgjs-wjzc>I helping friend
[00:05]<wjlllrws>CakerLatvia: yes
[00:05]<czcnzlzvvyz>Wolfpaws so if some vars doesn't exist, i cannot define them outside class?
[00:05]<wjlllrws>chronos-work: Meaning...?
[00:05]<axzjgjs-wjzc>but I test on regex-coach and see that char is \&
[00:05]<axzjgjs-wjzc>correct?
[00:05]<wjlllrws>CakerLatvia: N.O.
[00:10]<svglxrgyg>Classic bash.org quote of the day: http://bash.org/?309397
[00:11]<wjlllrws>steph: ouch
[00:12]<svglxrgyg>Not the best one ever, but still great.
[00:12]<tml>Stephanie: I've always been a fan of the meta-argument one
[00:13]<svglxrgyg>Yeah, that's by far the best.
[00:13]<svglxrgyg>But you have to admit...the ones where people leave out words/mistype things are also rather amusing. :D
[00:15]<suzpmun>how do i get the ip of the user?
[00:15]<rrdrdr>$_SERVER['REMOTE_ADDR']
[00:16]<suzpmun>ty
[00:20]<lrmmdq707>hello chan. i have a hopefully rather simple question: im including the part of a website, of which i have no control, and its every line starts with document.write (". so i try to do $tarife = strtr($tarife, "document.write \(", ""); but it doesnt do anything at all. i first thought it was because of the empty replace string, but even setting a value there doesnt solve the problem
[00:21]<wjlllrws>TML: http://storm.homeunix.org/misc/bts/sonorabattle.jpg
[00:22]<wjlllrws>document.write? javascript?
[00:22]<lrmmdq707>right. normally tis script is being included by a js
[00:23]<lrmmdq707>(fyi - heres it is: http://www.tariftip.de/besttarif-mini.asp) and i want to include it into a js-free website, just by "including" it
[00:25]<kzzvzrys>what should I use instead of NOW() so that datetime is stored at the time of query?
[00:25]<wjlllrws>*how* "doesn't do anything"?
[00:25]<wjlllrws>Kartagis: #mysql.
[00:25]<kzzvzrys>okay
[00:26]<lrmmdq707>Wolfpaws, it just leaves the code unchanged
[00:26]<d00cyn_>is there a way to get php to execute something as another user?
[00:26]<lrmmdq707>Wolfpaws, I echo the result once before executing strtr and once afterwards
[00:26]<d00cyn_>im having conflicts with php and sendmail :(
[00:27]<lrmmdq707>m00kie_, suphp or php via fcgi
[00:27]<d00cyn_>suphp?
[00:27]<d00cyn_>im running php as an apache module
[00:28]<wjlllrws>paddy2706: Are you *sure* you're using the function in the right way?
[00:28]<d00cyn_>im editing a file: /maillist.dat - php requires 757 to edit, sendmail refuses to touch it if it's group writable
[00:28]<wjlllrws>because strtr *isn't* str_replace
[00:28]<lrmmdq707>Wolfpaws, well, im not ;) thats why im asking here. this is the very line:$tarife = strtr($tarife, "document", "a");
[00:29]<azdjzyaas>m00kie_: chwon it to your user associated with php?
[00:29]<azdjzyaas>Wolfpaws: That's a boolean return. Not a replacer. See http://php.net/strstr (for what you're using) and http://php.net/str_replace (for what you should use)
[00:29]<wjlllrws>!tell Donkano about away
[00:30]<wjlllrws>kamoricks: any ideas, why are you telling *me* that?
[00:31]<azdjzyaas>Whoops, sorry.
[00:31]<lrmmdq707>kamoricks, lmc
[00:31]<wjlllrws>let's see...
[00:31]<azdjzyaas>paddy2706: Read the thing I sent to Wolfpaws...
[00:31]<wjlllrws>!+func str_replace
[00:31]<lxl-2jv>mixed str_replace(mixed search, mixed replace, mixed subject): Replaces all occurrences of search in haystack with replace
[00:31]<wjlllrws>!+func strtr
[00:31]<lxl-2jv>string strtr(string str, string from, string to): Translates characters in str using given translation tables
[00:31]<wjlllrws>looks fine to me :)
[00:31]<bzrdgdzjg>Is there a builtin function to check if a number is even or odd? I'm browsing the manual but can't find any reference to this.
[00:31]<azdjzyaas>Hmm? That's new... sorry bout that, I'll just... walk over here. Sure.
[00:32]<wjlllrws>hehe
[00:32]<azdjzyaas>BrainyRon: $val%2==0.
[00:32]<azdjzyaas>BrainyRon: Returns true if even, false if odd.
[00:32]<wjlllrws>BrainyRon: yes... It's called a "modulus" operator... php.net/operators
[00:32]<vnsvycrffs>kamoricks.. what about 0
[00:32]<vnsvycrffs>:P
[00:32]<azdjzyaas>TestiCalls: 0 is even.
[00:33]<||aw>kamoricks: actualy it returns the remainder
[00:33]<vnsvycrffs>(-1) 0 is ?
[00:33]<||aw>which with %2 can only be 0 or 1
[00:33]<wjlllrws>0 is special number.
[00:33]<azdjzyaas>||cw: Ehm, I put the ==0 on it...
[00:33]<azdjzyaas>TestiCalls: 0.
[00:34]<vnsvycrffs>;)
[00:34]<azdjzyaas>TestiCalls: It's even, though. Between two odd numbers and evenly divisible by two. Unless there's some new standard for even...
[00:34]<vnsvycrffs>nah
[00:34]<vnsvycrffs>just saying 0 is a funny number
[00:34]<vnsvycrffs>;)
[00:34]<zzymnsn>what does this mean? Warning: touch(): Unable to create file htaccess.php because Permission denied in /home/spellta/public_html/clanmct/database/index.php on line 81
[00:34]<zzymnsn>that i don't have write access to the folder?
[00:34]<vnsvycrffs>check your priviledges?
[00:34]<drvvdaa>Or the file.
[00:34]<azdjzyaas>aridese: Yep.
[00:35]<wjlllrws>actually... 0 is 0...
[00:35]<||aw>aridese: it means the user apache runs as can't make files there
[00:35]<zzymnsn>ok, if i try to make "../htaccess.php" it still can't make files -- but i know i have the rights to do that







