@# 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 33 34 35 36



Comments:

<0> hehe, that's extensive programming :)
<1> (For those lame enough to not know how to use an image editor.)
<0> I always wondered how those sites make auto-generated texts of specified colors, etc
<0> err, texts = images
<1> What do you mean?
<0> they have sites where you can go in, type in some text, set some styles and background, and click generate
<1> GD...
<2> heh KimmoA, its cool, not open souce nor php :P
<0> and it makes a .jpg with the specifications that you told it to
<3> in creating large-scale websites, has anyone found it useful to have website error codes shown in feedback for debugging purposes? (error codes would be stored in db for admins/programmers to look up)
<1> nonickforme: PHP is server-side...
<2> what im saying
<2> is this site dosnt use php.
<2> not as far as i can see...it uses python
<0> riftdesign- I think that's a matter of opinion rather than design. Some people would write errors to a error log file and than have it accessible by admins, etc
<1> nonickforme: I don't see why it matters. :S



<0> in fact, that would probably be faster than storing them to a sql database.
<1> It's still funky JavaScript == "Ajax".
<0> LOL!
<2> riftdesign, yes and no. I dont put error specific info anywhere the user can see it.
<3> [Ex0r]: I am the only developer of a fairly large (in content) website and sometimes it is difficult to trace errors
<3> nonickforme: understood...that's what i am trying to do with that as well...just didn't know if others have done it
<0> riftdesign- it it's a large website, it would probably be a bad idea to store every log in the database
<1> So... eAccelerator or APC? Zend is out of the question, for obvious reasons. I have used eAccelerator in the past, but it feels "unstable" and its future looks bad. APC is officially supported and feels like the most sane choice IMO. PHP 6 is said to have this built-in (FINALLY!), but when will PHP 6 be GA?
<2> riftdesign, you could make it so that it pops up a generic error report form when they get an error, keep error info in session, then if they submit a report, send that info along with it.
<0> i'd personally store it to a log file outside of the public_html directory, and than setup a php script that admins can use to view the error log.
<3> [Ex0r]: not log...itn's an error code like FC0456 which could be looked up in the database for something like "This is an error caused by a sudden disconnect to the database"
<4> how would i get my directories to print out before my files
<0> ah, I see
<5> when someone has time, I have a programming question
<1> I mean... people still use PHP 4... And likely even 3 (urgh!). :S
<0> I thought you meant storing errors in the database. Error codes would be fine to store in database
<0> SaintCrowdness- what do you need ?
<3> KimmoA: some people have a frustration of trying to run Java + php5 on the same server, so we are stuck with Apache2 and php4
<2> [Ex0r], my thoughts on using a file are that the error log is relativly tiny. It causes no stress what so ever on the database, and its much easier to manage a db table than a flat file.
<6> who wants to see a good example of horrible search programming?
<6> http://tinyurl.com/nu84d
<1> Roar.
<1> Nobody in their right mind would run Java...
<0> nonickforme- not when the website has over 10,000 members, and has alot of errors in it :)
<0> or is coded poorly
<2> its compared to the rest of the traffic that db gets
<7> SaintCrowdness: nobodies going to tell you they have time, just ask - thats the point of the cahn
<2> its microscopic.
<2> also
<5> [Ex0r], I have an html page that posts to a php page... the php page gets data from a sql database and displays it. I then want to be able to click on the titles to sort the data, but not sure how to keep my original search parameters to be used when I click sort on a title and posts to the same page.
<2> one thing on the side of db, you could get all reports on a certain error
<0> nonickforme- Yes, it won't take much time to query it, but storing every single error will make the database very large very fast
<2> and read what they all say.
<2> [Ex0r], if your getting that many errors, scrap it and recode it...
<0> nonickforme- which is why I said on a poorly coded site, or a site with alot of errors, storing the errors to a db would be pointless
<2> not at all
<2> -21:09:10- [nonickforme]: one thing on the side of db, you could get all reports on a certain error
<4> im printing the conents of a directory, and i want all the directories to print before the files, how would i do that?
<2> that right there wins it for me
<2> size is irrelivant...
<0> nonickforme- and you can't do that using a fopen and search string ?
<2> if its a high traffic site, cetainly you dont hurt for disk space
<8> Is there someone here that could explain to me the "cookie" that gets set on the user's system when using session_start()????
<7> probalby, but only if you explain the need of more than one question mark
<4> im printing the conents of a directory, and i want all the directories to print before the files, how would i do that?
<5> I have an html page that posts to a php page... the php page gets data from a sql database and displays it. I then want to be able to click on the titles to sort the data, but not sure how to keep my original search parameters to be used when I click sort on a title and posts to the same page.
<2> Cheryl, iterate the list twice.
<8> itrebal: Sorry, I was emphasizing my degree of confusion ;)
<7> Cheryl: you could loop through them and run is_dir on them, seperate the files and folders and then merge the arrays
<2> print the folders, then print the files
<9> nonickforme: if you have more than 1 front end web server and you were not storing them in a database you would have to fix it so that all the servers where able to write to the 1 file and you might end up with locking issues as well
<2> Rubberneck, good point Rubberneck
<10> Cheryl: keep track of $dirs[] and $files[] in your loop then iterate through $dirs and $files respectfully
<0> and if they are all writing/reading to the database at the same time you might end up with redundency or corruption to data
<2> ...in the database?
<2> never heard of such a thing
<9> [Ex0r]: in theory that is not possible with a real database
<10> or merge would work and have one iteration
<8> nonickforme: If you are using a transactional-type database, you could utilize it's internal locking mechanisms -- sounds like a lot of a headache -- why not just set up an Email account and format the error reports nicely and then for the legitimate ones, run the text through a parser to put it into the database?



<2> Rubberneck, is it possible at all?
<2> err
<4> itrebal: im not using array, i use is_dir and then print out my directories and files with different outputs
<2> wait, you guys are giving me things..i was for the db :P wasnt even my issue it was [Ex0r]
<10> Cheryl: then you need to create two different arrays that keeps track of $dirs[] and $files[]
<11> how do you do relative includes? can you include query strings in them?
<4> then print one, before the other?
<10> Cheryl: and do the output on the array's instead of the directory scan of files
<9> SaintCrowdness: if you don't always know what the query is then you would have to send that with the sort
<4> i dont like the array output, i cant manipulate it like the dir scan
<5> Rubberneck..... how? global vars? put it back in the request/response object?
<9> SaintCrowdness: you could just send it however your sending the sort to the page if your using sessions you could set it as a session var
<10> Cheryl: what ind of manipulating are you doing?
<5> tell me how, Rubberneck.... I'm not sure if I'm use a link to self
<10> iirc, you're just outputing <a> tags
<12> with the ***ociative arrays, there's bound to be collisions right? What happens in the case of a collision?
<10> well, with that /quit i'm going to sleep
<2> anyone have any opinions on using json for ajax interaction, rather than xml?
<12> or is there no hash?
<13> nonickforme: you have to learn yet another set of knowledge to use json
<7> skiddieleet: TIAS
<12> hmm?
<2> heh, shot deadroot
<7> skiddieleet: try it and see
<9> SaintCrowdness: if your going to make a link for the sort like file.php?sort=$sort you could do file.php?query=$query&sort=$sort
<12> I guess my question is do they use the word you put as the index, as the index, or do they hash it?
<7> skiddieleet: they use the work
<7> word*
<12> and if so, if you get another word with the same hash, what happens? overwritten?
<12> ok
<12> nvm then
<9> SaintCrowdness: that is very insecure though but since you letting people p*** query objects your script i am guessing your doing something to secure it
<5> so I would have to dynamically build that part and p*** those in the link?
<12> perl hashes right?
<5> Rubberneck.... I know... that's why I'm trying to do it another way
<5> here's the thing
<2> oh hey, i knew i had another question
<5> The html page allows them to pick their search criteria and does a post
<8> How does PHP store it's session data?
<2> my friend wont use magic quotes because he fears some security risk...is there anything to support his fear? or is it not a problem?
<5> the php page takes the info from the request and displays the data
<5> how else can I have them sort on the data based on the headers?
<5> without making it a link?
<14> DrSpin: Depends. By default, it serializes it into a temp file.
<9> SaintCrowdness: you could do more forms for the sort but just becuase it's a POST and not a GET dosen't make it any safer
<8> mattmcc: is there anyway to determine what temp file and where it's stored???
<9> SaintCrowdness: your still going to have to check everything the only difference is you don't see it in the url
<5> Rubberneck.... I understand that.....
<5> Rubberneck.... what's the best and most secure way to do it?
<9> SaintCrowdness: you just check everything like you would normaly. make sure it dosen't contain any funny stuff and make sure it only matches the choices you have given them
<15> DrSpin, my default, they are saved at /tmp/sess_**SESSION_ID**
<5> that's guaranteed by the choices on the html page, Rubberneck..
<5> The question is the info for the sort
<5> and losing my search criteria
<9> SaintCrowdness: no it's not because someone could just make a form and post it to your script with whatever information they wanted
<16> hey say $var is blabla.jpg how can we strip everything including the . so it only includes jpg but i dont want the last 3 chars because it could be .jpeg
<16> ;)
<5> only if I show the search criteria in the url
<5> which is what I'm trying avoid
<13> surfdue: regex
<16> im sorry deadroot?
<13> surfdue: regular expressions. www.php.net/pcre
<16> ty
<5> so I'm open to suggestions on a better, safer way, Rubberneck
<13> or try using normal string functions, like strrpos
<9> SaintCrowdness: no you are incorrect because i can look at your form and get the names of the fields and then make my own form and post whatever i wanted to your script unless your checking it in your script as well.
<5> I am, Rubberneck
<13> surfdue: or try using normal string functions, like strrpos() http://www.php.net/strrpos
<16> ty
<9> SaintCrowdness: then just do the same for the sort just because it's a GET instead of a POST it won't be any less secure they will just be able to see it in the url
<14> And server log files
<9> SaintCrowdness: if you really don't want it in the url you will have to make forms for the sort or use some kinda ajax to send it and reload the information on the page
<8> rixth: nothing like that -- :/
<5> hmmmm ok... I was hoping to be able to use some php vars to hold the info that I could read


Name:

Comments:

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






Return to #php
or
Go to some related logs:

#css
#css
gnometorrent ports
web irc gateway efnet
dd-wrt change mac
+kde +3.5 +desktop +monitor +dual
linux kernel language
libdvdcss2, k8, deb
+move accounts +Debian
#centos



Home  |  disclaimer  |  contact  |  submit quotes