@# 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



Comments:

<0> Jymmm: that still leaves you with two times as much information as crc32 ;)
<1> et_ shush you
<2> I just leave'em 32 chars long for the time being
<3> It's a question of how important it is to you that there are going to be collisions.
<2> TML: it was more the idea of producing shorter file names in a caching system
<4> soo
<1> kombi XOR the two halves of md5 results?
<3> kombi: So how bad is it if you get two files resulting in the same hash for your caching system?
<5> kombi: str_rot13() on a filename? Less chances of a sane filename to be insane?
<2> true..
<6> join #0,0 :P
<5> Although that made no sense at all
<5> But you get the idea
<2> do..
<1> kuja shut up and go to 7-11 or something!
<5> NO!



<1> kombi what about epcoh?
<2> TML: not so very bad, it is a quick an dirty hack to cache screenshots of websites, I think I am sorted
<2> Jymmm: never heard, I'll look that up
<1> kombi current date/time in seconds since 1970
<2> Jymmm: then uuid could come in handy, files need to be retrievable by the original strings though
<1> kombi then why did yo uask in the first place? lol
<2> Jymmm: point taken..;)
<3> kombi: My point was simply to educate you on why answers may have seemed vague. It's hard to answer that when we don't know how bad a collision is. If it's not so bad, you can take a subset of md5 or sha1 (such as MSDN does now, using the last 8 hex of the sha1 of the URL)
<2> TML: that makes perfect sense, thanks!
<7> The Microsoft P***port Network requires JavaScript to sign in.
<7> fork you.
<2> fork?
<8> kuja,how does str_rot13() lower the character length
<8> i don't get it
<1> mazzanet I'm going to be making that a requirement too
<5> section31: It doesn't. that's the whole idea behind my answer. It's not more or less in length of the original filename.
<7> die.
<1> mazzanet for legit reasons
<7> ...
<8> kuja,then why not leave the same...is he trying to obfuscate it
<8> i don't think so
<5> section31: I kind of got the impression he was.
<8> kuja,i don't think so
<8> normally in a caching system
<2> trying to turn full urls into file names
<5> But I'm going here and there not paying much attention. I see md5(), filename, caching purposes. I go, OBFUSCATION?
<9> php > echo str_rot13("kuyalikesgoats");
<9> xhlnyvxrftbngf
<9> that works..
<9> kombi: uuid only for mysql..
<5> fhpx n qvpx
<2> str_rot13("http://www.foo.bar?foo=bar";) might not result in a usable file name though..
<2> likewhoa: pecl has it
<5> kombi: Ah, that it won't.
<5> I thought you were doing something *entirely* different
<2> should have expressed myself better
<9> kuja: waht you making in python? :D
<9> kombi: funny you mention a screenshot tool in php, i got one in python :D
<5> likewhoa: Learning purposes
<9> kuja: rgr
<10> hay guys, why would my sessions stop working between two pages?
<5> stuntcock: The most common reason I can think of is a missing session_start()
<10> kuja: that's what I thought, but it's there on both pages.
<11> lota useless bans in here
<12> In a GET variable I'm getting %u201C and other unicode escape sequences... shouldn't that be decoded for me?
<12> anyway to fix that?
<13> afaik it should be decoded
<1> http://us2.php.net/manual/en/ref.unicode.php
<1> i *THINK* that would be an apache thing
<14> Hi is there any object/component/set of functions that will log into a website using their login form, accepting the cookies and all, then downloading a web page from that site?
<14> like a http user agent for php
<14> it needs to support ssl
<14> I will then convert the document to xhtml and run xquery on it, but ive already figured out how ill do that, I just need a user agent
<14> that I can control from code
<14> like a web bot or something?
<15> robbie__ you can do php spider search on google, or you can lookup http//pear.php.net/ for something, as well as http://php.net/curl for connecting to http servers
<15> robbie__ what you are trying to do is fairly simple
<14> ok
<10> for regular expressions will "\b" catch numbers?



<16> stuntcock: why don't you look up what \b matches?
<17> hi
<10> aidan: I did, but the stuff I found wasn't very helpful.
<17> I'm wondering if something like this exists in php:
<17> makeImage("myEmailAddress");
<17> so i feed php my plaintext email address and it turns it into a gif image
<17> so harvesters dont grab it :)
<1> php.net/image
<16> laurens_: well, obviously that's not a native php function, but PHP supports the GD image manipulation library, and writing text on an image is trivial
<16> stuntcock: you obviously did not look. I googled "regular expressions \b" and the first link explained it
<16> http://www.regular-expressions.info/wordboundaries.html
<10> aidan: thanks. I'm so happy you were so nice about it.
<16> stuntcock: you are disrespecting the channel by being lazy, don't expect us to be nice
<18> what php function do I use to get a random number (decimal) between 0 and 1?
<12> is there any way to dump the settings of my php install? I'm trying to grok mbstrings
<16> glimmung: how many decimal places?
<18> 2
<18> rand(0,99)/100?
<16> glimmung: echo rand(0, 100) / 100;
<18> lol
<16> burtonator: phpinfo()
<12> aidan++;
<19> oi
<20> man talk about weird
<20> i put a jpg in a particular directory.. and it refuses to work from there
<20> apparently the directory called advt doesnt wanna work..
<20> but i rename it to adhere it works fine
<20> scary
<18> whats the symbol for logical "and" in php, isnt it &&?
<18> or is it just &?
<21> this doesn't seem to work -- i'm wondering what is wrong --> if ($v == 1 or 21 or 31)
<21> i've tried || instead of or
<1> ($v==1 or $v==21 or $v==31)
<21> ah!
<21> k thanks Jymmm
<22> join
<22> err
<16> minDscrm: probably best to use || rather than or
<16> minDscrm: and you should be using === to compare things, not just ==
<21> ok
<21> aidan .. i didn't realize
<16> minDscrm :)
<21> why is it best to use || ?
<16> minDscrm: it's higher up on the precidence table, so you're less likely to have wild side effects ... and it is what everyone else uses
<21> alright
<21> i thought == was to compare things, why is it better to use === ?
<23> it's not "better to use ===".. it depends on what you want
<24> yes, use '='
<25> lol
<23> == compares the 2 values, and changes the datatype automatically
<23> === compares 2 values and the datatype
<24> well, after you use = no need to question equality anyway
<23> so "1" === 1 is false
<18> what the newline escape character?
<23> but "1" == 1 is true
<24> \n
<1> !+nl
<26> Newlines are hidden (not normally visible) control characters that distinguish the end-of-a-line of text and are different for each platform as follows: [Windows=\r\n] [*nix=\n] [Mac=\r] And can be seen as: [LF (linefeed) = \n, 10d, 0x0A, 0001010b] [CR (carriage return) = \r, 13d, 0x0D, 0001101b]
<16> niraj: right, but you should almost always be using ===
<21> niraj !! rad thanks for that explanaion
<25> gees
<25> that is a -complicated- answer
<25> :P
<24> kyelewis: ;-)
<18> i tried \n but its still putting everything together on one line
<23> aidan: that really depends on what you're coding :)
<1> nl2br
<24> glimmung: put enter then!
<25> glimmung: a web page or a cli app?
<16> niraj: give me an example where it's not the right thing to do
<25> glimmung: or something else?
<24> or use <pre> !!!
<24> <pre> is da saviour


Name:

Comments:

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






Return to #php
or
Go to some related logs:

gentoo orbit TTypeCode Error
#css
#lisp
#bash
#ubuntu
#perl
nview dapper como
debian usbfs: interface claimed by usbfs while 'scanimage' sets config
aoss realplayer sound choppy
mysql string_to_date



Home  |  disclaimer  |  contact  |  submit quotes