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-05-13
Pages: < Prev
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
33
34
35
36
Next >
[20:59]<wdcys_>ICY 404 Resource Not Found icy-notice1:"
[20:59]<wdcys_>eh ups..
[21:00]<ajdlu61zr11c>is there a way to have the gd library not use anti aliasing and make the font pixelated?
[21:00]<wdcys_>quintin: http://php.net/readdir and http://php.net/fwrite
[21:01]<fuygvyg>surfdue: would you know how to do that?
[21:01]<crlsj>If I have repeated values that have been key indexed in an array that was set within a foreach() ... is there any sort of function to remove the duplicate values from the array?
[21:01]<suzpmun>quintin, if I did I would help sorry :P
[21:01]<fuygvyg>wykis_: I'll look and see if I put together. thanks :D
[21:01]<wdcys_>quintin: it is very simple
[21:01]<wdcys_>oh, an easier way, i recalled
[21:02]<fuygvyg>wykis_: I hate programming :P that's why I play poker for living now instead of IT
[21:02]<wdcys_>;]]
[21:03]<wdcys_>$list=glob("*.jpg");$h=fopen("index.html","a");foreach($list as $i => $v) {$t="<img src=\"{$v}\" alt=\"\">\n";fwrite($h,$t);}fclose($h);
[21:04]<fuygvyg>wykis_: that will work as index.php? I want index dynamically loaded whenever page is viewed. that looks like i twrites to file each time executed?
[21:04]<suzpmun>so wykis_ did you get it?
[21:04]<wdcys_>hm
[21:04]<fuygvyg>the directory is jpgs captured from webcam for security purposes.
[21:04]<wdcys_>allright
[21:04]<wdcys_>do a simple cache then
[21:04]<fuygvyg>if you wanna see what my laptop is doing... http://cyanite.org/~quintin/security/ :D
[21:05]<wdcys_>$list=glob("*.jpg");if ( filemtime("list.html") < (time()+60)) { $h=fopen("list.html","a");foreach($list as $i => $v) {$t="<img src=\"{$v}\" alt=\"\">\n";fwrite($h,$t);}fclose($h); } echo file_get_contents("list.html");
[21:05]<wdcys_>that caches for 60 seconds
[21:05]<crlsj>Any ideas anyone?
[21:06]<wnnmzz>I keep getting the error "Can't connect to local MySQL server through socket '/var/www/var/run/mysql/mysql.sock' (2)", the socket exists and I able to logon to the mysql server locally with the password/username supplied
[21:06]<wnnmzz>Any guess as to why I can't connect?
[21:07]<wdcys_>Capso: http://php.net/array_remove_duplicates or soemthing like that
[21:08]<fuygvyg>wykis_: what about looking in directory every time index is loaded?
[21:08]<msxrmjw>wykis_: array_unique(), perhaps? That function doesn't exist.
[21:08]<wdcys_>DShadow: maybe
[21:08]<wdcys_>i don't recall
[21:09]<pgzl_mjgk>hello
[21:09]<wdcys_>Capso: yes, DShadow is right: array_unique() :|
[21:09]<wdcys_>hi PerL_MonK
[21:09]<crlsj>Alright.
[21:10]<crlsj>Wykis_ and DShadow: Thanks.
[21:10]<zxsdzzvyn>this is pretty cool
[21:10]<zxsdzzvyn>where did you find this?
[21:10]<yzg>jhsmartie: yup channel for anything.
[21:10]<pgzl_mjgk>does anyone have an idea, if if ($var === "\x4D") will be converted to if ($var === "M") and then compared or it'll be faster ?
[21:11]<crlsj>DShadow: How would I then reset the index of the array?
[21:11]<pgzl_mjgk>like PHP will notice it's hex and convert $var to hex and make some binary operation on it
[21:11]<zxsdzzvyn>how do you find channels
[21:11]<wdcys_>Capso: array_values()
[21:15]<azdjzpysv>http://hashphp.org/pastebin?pid=6676
[21:15]<crlsj>Wykis_: Ah, neat. Thanks.
[21:21]<sugsxdgnlrmd>Hello
[21:21]<fuygvyg>wykis_: that seems to kind of work... all image links are broken though !
[21:22]<fuygvyg>wykis_: http://cyanite.org/~quintin/security/
[21:23]<wdcys_>quintin: maybe the files don't exist..
[21:23]<fuygvyg>wykis_: of course they exist!
[21:23]<fuygvyg>-rw-r--r-- 1 quintin users 12K 2006-05-13 20:08 webcampic_1405470513.jpg
[21:23]<wdcys_>does /~quintin/security/webcampic_1242040513.jpg exist?
[21:23]<sugsxdgnlrmd>The requested URL /~quintin/security/webcampic_1242280513.jpg was not found on this server.
[21:23]<wdcys_>http://cyanite.org/~quintin/security/webcampic_1242040513.jpg
[21:24]<fuygvyg>http://cyanite.org/~quintin/security/webcampic_1405470513.jpg
[21:24]<fuygvyg>it's some funny guy reading a book
[21:24]<fuygvyg>and no doubut eying my laptop! =)
[21:25]<wdcys_>wow strange
[21:25]<wdcys_>quintin: you at least need quotes in <img src="">
[21:26]<fuygvyg>wykis_: they're not needed, it'll just render in quirks mode. It seems the images referenced in the index don't actually exist (?)
[21:27]<wdcys_>yep
[21:27]<wdcys_>weird
[21:27]<wdcys_>what is in your glob(); ?
[21:28]<fuygvyg>hell if I know. put printf("$list); at end
[21:28]<wdcys_>:][
[21:28]<wdcys_>quintin: are you using glob() or opendir/readdir ?
[21:29]<fuygvyg>and it didn't print anything
[21:29]<wdcys_>quintin: $list is an array. use print_r($list); to print it
[21:29]<fuygvyg>wykis_: http://cyanite.org/~quintin/security/index.phps
[21:31]<fynzzms_jgfygn>quintin - I've just saved a couple of images quoted the src="" on one and left the others unquoted. and added <html><body> tags - it now works on my machine
[21:31]<evyfguzu>is there an easy way to return a string with the last two letters chopped off
[21:31]<fynzzms_jgfygn>at least, the "" quoted img works ;)
[21:32]<fynzzms_jgfygn>evil - check out substr
[21:32]<yvzn2rf>and strlen
[21:32]<2a22daan>?
[21:32]<2a22daan><afsafsafa> i
[21:32]<2a22daan>whoops my fault
[21:33]<suzpmun>hey guys i need to take this file http://72.232.27.132:8060/7.html and turn everything between the ,'s into a varialbe how?
[21:33]<lnvnzwo>http://pastebin.com/715661 are there any easier ways to do this
[21:34]<fuygvyg>wykis_: huhm
[21:35]<azdjzpysv>does limiting bandwidth with fread($file,packetsize) and sleep(1); consume alot of resorces when say, 50 users are downloading at the same time?
[21:36]<suzpmun>i currently have this code it dosnt output anything though http://pastebin.com/715668
[21:37]<fuygvyg>lizards_online: uhm... what? the images don't eist as referencded in in index
[21:37]<wdcys_>hm
[21:37]<wdcys_>sorry
[21:37]<wdcys_>quintin
[21:39]<fuygvyg>wykis_: wykis. someone will steal my laptop if we don't get this owrkin !
[21:39]<wdcys_>quintin: it works for me ;]
[21:39]<fuygvyg>wykis_: on my server?
[21:39]<ndlvdvnn>hi all. i'm building a php ext, trying to get a static lib compiled in but PHP_LIBRARY_ADD does not seem to pick it up from the config.m4. Anyone have experience with this and a spare 2 cents?
[21:40]<wdcys_>i improved it a bit :|
[21:40]<fynzzms_jgfygn>quintin - I copied your page, copied a couple of your images, added the <html><body> tags and quoted one <img src="whatver.jpg"> and left the others unquoted, the quoted one worked, that's what I'm saying - it's an html problem
[21:40]<fuygvyg>wykis_: uhm.. pastebin? :)
[21:40]<wdcys_>somethign is working strangely here :\
[21:41]<fuygvyg>lizards_online: I copy the names in the index.php and then paste and those files don't eixst it seems
[21:41]<fuygvyg>lizards_online: that really makes no sense since browser would just use quirks mode.
[21:41]<fynzzms_jgfygn>quintin - I'm telling you to "" quote them and add <html><body> tags - if it worked for me it will work for you ;)
[21:42]<fuygvyg>lizards_online: uhm, no it won't. the references in the index are to files that don't exisit.
[21:42]<fuygvyg>lizards_online: you changed something
[21:42]<wdcys_>quintin: http://rafb.net/paste/results/drH1Df65.html







