« first day (447 days earlier)      last day (4498 days later) » 

1:07 PM
@ircmaxell reads okay to me
 
nav
can any one help me on that issue?
 
@nav no. there is no context, nor any details.
 
@nav how are they encoded in the DB?
 
nav
we have created two databases in sql.1 is for users and 2 database is for storing Images.Just i want to retrieve images from 2nd database.This is my query.
 
@Gordon ah ok. Couldn't tell if it was a good or bad view on it
 
nav
1:23 PM
it's displaying image path like this:D:\Images\220px-Lillium_Stamens(1).jpg
but i want displaying of image.
 
@ircmaxell it just summarized your main points. there was no judgement call in it.
 
hi all
I just had an insight
A really big one
 
nav
i have created two databases,names are userdb and userextradb and i have inserted one table in userdb and inserted values.At the same time i have inserted images in userextradb.The question is for every users it will show th e image.
 
Namely that PHP's code is not the only one that sucks
I tried to find out how Ruby randomizes the string hashing function and I wasn't able to find it (oh and their code is so #define-y...)
 
@Gordon ah ok. thanks
@NikiC yeah, their source code is really fubar
 
1:33 PM
@ircmaxell btw, how much views did you get eventually?
 
@NikiC up to 10k so far
 
@ircmaxell It's somewhat of an insight to me because I though that only PHP's implementation sucks. And that Ruby's sucks too (or even more) is something new to me.
 
I'm psyched for my next post (goes live in about 1.5 hours). That should be somewhat decent of a response as well (hopefully at least)
@NikiC yeah, I can see that.
 
@ircmaxell Has restored some of my belief in PHP ;)
 
none of mine :-P
 
1:35 PM
@ircmaxell Should go up to 20k today then.
@ircmaxell You already lost all of it? :P
lunch
 
Cool. Take it easy, I'm off to work too
 
hi @ircmaxell, @NikiC, @nav, @JasonLotito
 
nav
@h
@hakre hi
@BenjaminBrizzi hi
@Gordon hi r u there?
can anybody help me?
 
You need to help for help.
Otherwise it's not possible.
 
nav
@hakre i did not understand.
 
1:51 PM
Let's say I have a database.
I store text in there.
How do I get the text out of it? Please tell me.
 
@nav yes
@nav D:\Images\220px-Lillium_Stamens(1).jpg is a local path on the filesystem. If you put that into an <img src>attribute, it will only work when the page is viewed on the server. You need to put the path from the webroot.
 
nav
@Gordon shall i send that code what i have written.
 
@nav no, just change the image path to be relative to the webroot
 
nav
@Gordon just check it where i have to change i am new to php
 
@nav sorry, i dont want to read code right now. im busy.
 
nav
1:57 PM
@Gordon how to do the webroot?
 
@nav the webroot is the top most directory where your publicly accessible html files are located
 
nav
@Gordon here we are using WAMP server and it was installed in c drive.Do i need to copy image files in that folder.
 
@nav no, like i said you need to find out where the webroot is and make the path to the image relative to that
 
@nav: Please look into your WAMP documentation what a webserver actually is and how it is used. That should tell you all the details.
@nav: To understand what a relative link is, it's specified here: tools.ietf.org/html/rfc3986
 
@nav if its on a different drive you likely need to copy it or put a symlink on your c drive to d.
 
nav
2:04 PM
@hakre that image files has been stored in database
 
An NTFS symbolic link (symlink) is a filesystem object in the NTFS filesystem that points to another filesystem object. The object being pointed to is called the target. Symbolic links should be transparent to users; the links appear as normal files or directories, and can be acted upon by the user or application in exactly the same manner. Symbolic links are designed to aid in migration and application compatibility with POSIX operating systems, and were introduced with the modifications made to the NTFS file system with Windows Vista. Unlike an NTFS junction point (available since Window...
 
nav
@hakre you want me to change permissions to NTFS or what?
@hak
@hakre shall i give my code to you?
 
@nav we have given a number of explanations and pointers now. please try to understand the explanations and follow the links. Dont expect us to give you a step by step explanation.
 
nav
@hakre are you there?
i am exacting path loaction and where i have to store images.
 
I'm really getting annoyed lately by people posting these "please check my code" questions, where they don't even list an error, and first comments are always "show code / whats the error?". Anybody else think we should have a quick close option for these things?
 
hi all
 
hi @neal
 
@hakre wassssup?
 
writing mails, chatting a bit and porting a static website into a CMS.
While trying to get a new graka because the old one had one month left for guarantee :)
 
2:31 PM
And I'm back
 
wb..
 
@Jakub just close as a not a real question or too localized. please fix my code for me questions are unwelcome anyway
20
Q: Do "fix my code pleeese!" questions qualify for closure as "too localized"?

user145842There are many questions that contains only some code and a remark like "it doesn't work." Php and MySql Update problem is one example. Judging by "extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet," I'd say that these questions are inde...

 
@Gordon, yeah I've been marking for close
My beef with it is basically people will sneak in to answer the question, and in most cases I've seen the questions just remain open or become 'answered' before enough people vote on it, its just sad that PHP is the area where we get the majority of these things.
 
@ircmaxell check out my Model addition: github.com/maniator/SmallFry
 
eih, still leaking too much information. Why does the controller have SQL in it at all
 
2:41 PM
@ircmaxell ?
That way you do not have to use the Model
 
Cake allows you to do raw mysql if you want
 
@ircmaxell In what sense?
 
@Neal using Cake as an example is futile. That's like saying that Playboy is an example of fine journalism. Sure, they may get it right from time to time, but as a whole, you're missing the point
5
 
I.e. do you agree or disagree?
 
2:43 PM
@ircmaxell :-p
Well i did add a model
and made some code changes elsewhere
Like I removed the Database.php from the whole app
 
eih
@NikiC blog.ircmaxell.com/2012/01/how-we-interview-developers.html (I pushed up the publication because of that post)
http://news.ycombinator.com/item?id=3433436
http://www.reddit.com/r/PHP/duplicates/o5g77/how_we_interview_developers/
 
thx will read
@ircmaxell I'm not sure though whether it's good to judge programmers mainly by personality
It is the common cliche that programmers don't really like to socialize and I'm sure that this is not just a cliche ;)
 
No?
@NikiC it's not about social interaction, but team interaction. Someone that can work well in a team is infinitely more valuable to me than someone who can only do good on their own
 
0
Q: Small PHP MVC Template

Neal The following is a new question based on answers from here: Small PHP Viewer/Controller template I have written a small MVC template library that I would like some critiques on. The library is located here If you are looking for where to start, check out the files in the smallFry/applicat...

 
can anyone take a look at this?
 
2:56 PM
Well, my /. comment is at +5 Interesting already...
 
1
Q: mod proxy not working on apache

JohnMerlinoI am trying to install Mod_Proxy Apache module on WHM/CPanel CeEntOS Linux Server. Here is system info: CentOS release 5.6 (Final) Server version: Apache/2.2.21 (Unix) Cpanel::Easy::Apache v3.7.2 rev9999 The purpose of me installing is so that when on site abc.com, when I click a link to site ...

thanks for any responses
 
@ircmaxell ?
 
@ircmaxell oh, btw I think that shouldn't be on /r/php but on on /r/programming instead
It doesn't reference PHP at all ;)
 
@Neal :-D
 
3:01 PM
@NikiC It's on both
 
@ircmaxell Re: your blog post, while I've seen it done, I feel that any interviewee should be given some kind of programming test - even if it's a really easy one. My favorite test in an interview was given 14 years ago. It was a pseudocode test. The interviewer just wanted to see how I thought through a simple programming problem.
 
I can understand that, but in my experience it doesn't tell a whole lot
I'll learn what I need to know usually from just talking with them. And if they can't do the job after a few days after hire, then we can let them go...
 
While I've experienced the exact opposite. ;) I guess my point is that there isn't one correct way of doing things.
 
Absolutely not. Find what works best for you, and stick with it
 
@ircmaxell It is, but it shouldn't be imho ;) You'll get a much larger audience on programming anyways :)
 
3:03 PM
@NikiC Well, we do mainly hire PHP devs, so that's why I put it there as well
Hacker News is still only at +1
 
@ircmaxell You got a point (though I don't think it's much PHP specific)
now at +2 ;)
 
@NikiC It's not...
 
@ircmaxell btw the post doesn't show up on programming, so probably spam queue again
 
mods pinged
so all of them are at +2 now...
 
I think I'll work a bit on the datastructures now
 
3:14 PM
Morning all
 
Good morning
 
@Bracketworks morning
 
How're you folks doin?
 
@ircmaxell I would think that you would not want to see your candidates get frustrated. Puzzled, sure. I'd prefer calm candidates, especially ones who are calm when they don't know exactly how to solve something.
@NikiC Which part?
 
@LeviMorrison Right, but I want to see them outside of their comfortzone (dealing with a problem they may not know the answer to)
 
3:22 PM
@LeviMorrison Hm?
 
Hello!
 
@NikiC Of the datastructures?
 
@LeviMorrison ah. adding tests for Queue right now
 
looks like that post isn't going to gain much traction :-(
+10 Geek Cred Points :: Subscribe to a prominent magazine dedicated exclusively to php, namely php|architect
+25 Geek Cred Points :: (per certification) Get certified with recognised certifications like the Zend Certified Engineer program
how do either of those make you an awesome developer?
 
@ircmaxell Seems like most of the things listed there are for people with a lot of free time on their hands.
 
3:33 PM
hey guys
i got a question
I'm using this
$i++;
give error that its undefined
 
Hm, if I call ->toArray() twice the second time the array recurses into itself :(
 
@Crontab it seems like only one or two things on that list is really going to do anything
 
@HarryBeasant You need to do $i = 0; first.
 
yeah i dud that =L
WTF
 
@HarryBeasant paste your code that's giving the problem to something like codepad.viper-7.com
 
3:35 PM
Works now =L
Sorry and thanks
 
@ircmaxell The "link to your SO profile" is probably the best one on there.
 
@Crontab best as in what? best advice? or best failure?
 
@ircmaxell Best advice. At least it's a measuring stick of what you're capable of.
 
@Crontab disagree completely. I've seen plenty of high rep users who don't know their rear end from a hole in the ground. And likewise I know several low rep users who know a lot more than you'd think...
 
@ircmaxell Screw rep, I'm talking about being able to actually look through questions asked and answers given. You can see if the user gives shit advice with your own eyes.
 
3:38 PM
fair enough
 
Hello!
 
Hey, he's back
 
@ircmaxell playboy's articles are not bad. some even won awards.
 
@Gordon :-P
@Gordon best illustrated article?
 
@Robik Oh noes! We lost a donut :(
 
3:43 PM
Is that bad?
 
Yes
I liked @Donut
 
Well, you have a month before we can get him back
 
@NikiC Stop it! I've thought of changing it again now :/
 
@Robik You should :)
 
Not really a month, Neal told me a hack :P
 
3:45 PM
Can I get any upvote love on the post: news.ycombinator.com/item?id=3433436 ?
 
@ircmaxell ha ha :P no. im not saying they are the top of journalism but to claim they are just some alibi add-on to the pictures is not giving them proper justice.
 
@Gordon No, I know. I'm just poking fun
 
@Gordon And they are probably much more respectable and reputable than things like Bild ^^
 
@NikiC thats not difficult :)
Stoimen Popov's Blog: PHP Performance: Bitwise Division: Stoimen Popov has a new post to his blog today compari... http://bit.ly/w0qY95
@NikiC relative?
 
@Gordon no
 
3:51 PM
5
freaking cool
 
howdy all
 
Hey there
wth. That cforcoding post is up on reddit, but mine still isn't (I pinged the moderators an hour ago)
 
4:11 PM
I posted that back in october ^_^
 
eih
still cool
 
haha but yes, it is friggin cool ^_^
 
@ircmaxell @NikiC I just realized that I have a use for a tree class already and I never saw it before.
Menus.
 
sure...
 
@LeviMorrison Which?
 
4:13 PM
Well, and DOM modeling...
or any hiearchical data structure
but how do you abstract away the tree part of that (the logic for inserting a node)
 
You would have to expose the nodes, I think.
I'm not sure that would be useful.
 
me neither
 
@Robik Jesus did you make a sport out of it :P
 
That was system one.
 
4:23 PM
@Robik Defrag? What is this 1995?
 
What 1995?
 
boo, reddit thread still not approved
 
Disk Defragmenter is a utility in Microsoft Windows designed to increase access speed by rearranging files stored on a disk to occupy contiguous storage locations, a technique called defragmentation. Defragmenting a disk minimizes head travel, which reduces the time it takes to read files from and write files to the disk. Beginning with Windows XP, Disk Defragmenter also reduces system startup times. History Early history As early as the end of 1982, the IBM PC DOS operating system that shipped with early IBM Personal Computers included a Disk Volume Organization Optimizer to defragment...
 
0
A: function to append "a" or "an" to the front of a number as appropriate

NealI don't know if you have noticed but all numbers that start with an an have the numbers in the array before the comma. So what you can do: function prefixAAnToNumber($num) { $prefixAn = array(8, 11, 18, '8', '11', '18'); $number = number_format($num); $numberSplit = explode(',', $nu...

 
@Robik maybe because it's specific to windows.
 
4:29 PM
Oh, right.
 
@Robik I haven't defragged a disk in many many years. Modern filesystems won't benefit from it (or benefit much)
 
> Modern filesystems
Yeah
 
Or SSD drives :)
 
NTFS is not that modern...
 
@NikiC SSDs actually benefit from fragmentation...
 
4:34 PM
It its better for the lifetime right?
 
@ircmaxell Nice post. From the way it was written I hope my future interviewers have a similar philosophy.
 
@PeeHaa For SSDs? No. You'll kill your SSD by defraging it
 
Not just that, but the way they use multiple controllers (in the sense that each controller has very limited bandwidth, so by having the file split across multiple controllers it increases speed significantly)
 
@ircmaxell k
 
@CharlesSprayberry Thank you very much. I thought it would be interesting, but apparently the reddit and hacker news crowds disagree :-(
 
4:35 PM
@ircmaxell what post?
 
@ircmaxell Looks like it just showed up on reddit.com/r/PHP
 
:-P
 
@CharlesSprayberry yeah, but it's still not approved for programmers, I pinged the moderators almost 2 hours ago
 
@ircmaxell Wow, only time I pinged the mods it seemed like the article was up before I hit the refresh button.
 
4:38 PM
@CharlesSprayberry What did you put on reddit?
 
@CharlesSprayberry Yeah, when I had to on Wednesday for /r/php it was almost instant as well. This one has had no response at all... which kind of sucks...
 
I was actually surprised that I got a few comments and even some people watching my github repo. Since I'm just starting out I'm still kinda stoked about that :P
 
@CharlesSprayberry I liked your post a lot (aside from the one tiny pedantic criticism I gave the other day)...
 
@CharlesSprayberry Hm, never saw that post on reddit
 
4:42 PM
@ircmaxell once again a great post and so true!
 
@PeeHaa Thanks!
 
@ircmaxell Well I was talking about "MRC" with @hakre the other day and he asked for a better explanation and I didn't really have one for him. I think the post was as much about me really understanding what I was thinking...
@NikiC It is on reddit/r/PHP
I think I titled it on reddit as "Interpretation of the MVC design pattern"
 
@CharlesSprayberry Have you read: peej.co.uk/articles/rmr-architecture.html
 
@ircmaxell I have and it looks like a very interesting concept. I'm thinking that once I have more groundwork laid out for my project I may start looking at incorporating some of his ideas.
 
Yeah, it feels like it's not fully there in concept (there's something that feels off), but it is interesting enough to warrant further thought...
 
4:47 PM
@CharlesSprayberry Responder could probably better be Representation because that's more close to what it is called in HTTP/REST terms. At least when we assume that the Response contains a representation of a domain model / Resource.
 
@ircmaxell Definitely and since this is as much an educational project as anything else I don't mind going "off the reservation", so to speak.
 
Absolutely
I was never afraid of failure, for I would sooner fail than not be among the best. -- John Keats
 
@Gordon Interesting, I will have to give that some thought. At this point there is certainly nothing set in stone.
 
hi guys i have a question regarding directory security
 
@JMRboosties Shoot
 
4:50 PM
if i have a directory containing media (ie pictures), how can i protect the files in the directory so someone cant enter the URL and view the file?
i understand using sessions and other things to control pages being viewed using php, but i dont know where to begin on this
 
@JMRboosties and server the files through php
 
use something like that (Apache and NginX both have similar modules)
 
ok, because i want people to be able to access the files, just only when i allow it, if that makes sense
if its out of the webroot will people still be able to access them when i want them too?
 
@JMRboosties sure if you server them through php
 
4:52 PM
@JMRboosties That's how you control access
 
ok, im gonna read this link you sent @ircmaxell
thanks a lot guys, im sure i will have some questions in a bit
 
:-D
 
you guys think it will be ok if I ask a question on stackoverflow trhat I asked on serverfault yesterday?
 
is it programming related or server related? :P
 
5:03 PM
this was question:
1
Q: mod proxy not working on apache

JohnMerlinoI am trying to install Mod_Proxy Apache module on WHM/CPanel CeEntOS Linux Server. Here is system info: CentOS release 5.6 (Final) Server version: Apache/2.2.21 (Unix) Cpanel::Easy::Apache v3.7.2 rev9999 The purpose of me installing is so that when on site abc.com, when I click a link to site ...

 
@JohnMerlino if you think it belongs on StackOverflow you could rather flag it and ask it to be migrated. but no, that question shouldnt be on SO at all.
 
@JohnMerlino that's not SO related
 
I have a form, and when I submit, I want to load files of other server, but right now other server does not respond to request, depsite reverse proxy being setup
 
@JohnMerlino I have a form, but when I start my browser I don't have a working internet connection. Still not programming related IMO :P
 
so you using that it was posted in right place?
 
5:06 PM
either that, or SuperUser before StackOverflow. it doesn't really have anything to do with programming directly...
 
SO I need to ask for it to be migrated or can I have it posted on both sites?
 
@JohnMerlino If you crosspost it might get closed
 
try to word the question a bit clearer. It's a little hard to tell what the problem is (you have a lot of info, which is good, but you don't get to the problem until the last paragraph)...
 
@ircmaxwell just weighing my options here... would the mod_secdownload library which you linked me to be the same thing as server via php?
 
5:21 PM
similar, but consumes less resources since PHP isn't booted for those requests
 
ok, so in your opinion mod_secdownload is the better option.
in their example, the URL is yourserver.com/bf32df9cdb54894b22e09d0ed87326fc/435cc8cc/secure.tar.gz, what would happen if a user entered that exact string into their web browser?
 
depends on what you're doing, but I've used it to great effect
@JMRboosties it would work for them. Up until the timeout
 
ok, so basically what this does is generates a working URL for a limited time based on the timestamp generated via php
 
yup
 
great, i think i understand it. you can set timeout as well i see, thats nice.
 
5:25 PM
Hello all, I'm new to the chat! If you have questions, I may help you...
 
Hey there @FrederickMarcoux, welcome
 
@ircmaxell i see how you would generate the link via php, but via what mechanism would you tell your server to allow that generated URL to link to a given file, and work?
 
Is it just me, or are moderated comment threads (where all comments need to be approved) really annoying
@JMRboosties It's a server config. It knows how to decode the URL to check to see if it's valid based on the config (explained in that post for lighttpd)...
 
No, it's not just you, I have some comments that was delete...
 
5:29 PM
@ircmaxell It is not just you and why I specifically setup my comments to allow anybody to post without moderation. I have a filter on some choice words but I hate having to wait around for some random web admin to come say that my thoughts are worthy of the Internet.
 
@FrederickMarcoux what is your favourite animal?
 
@salathe Cat, why this question?
 
@CharlesSprayberry Same here, I have a basic spam filter, and ocasionally flag comments as spam, but it's set to auto-publish
My comment on stoimen.com/blog/2012/01/05/php-performance-bitwise-division/… still isn't published (for over an hour)...
Talk about a Micro-optimization…

Also notice that a / 2 is not equivalent to a >> 1. It is somewhat like floor(a / 2) , but there are plenty of cases where it’s different (such as if a is negative).
@FrederickMarcoux Why not, you said if you have any questions, you didn't specifiy php ones... :-D
 
Indeed, lol
 
@ircmaxell oh ok i see that. would this be compatible for a system in which you have hundreds of these files? you enter the directory you are protecting and the passphrase in web options, then anything they request inside that directory goes through the process and is delivered, correct? just making sure i understand correctly
 
5:35 PM
@JMRboosties exactly
 
cool, now to figure out how to get my server to implement this. ive never imported a library before in php, only in diff languages
 
Unfortunately, I need to go... If someone have a question, you can email: fmarcoux96@me.com or just ask on the website...
 
good morning everyone
 
evening :P
@FrederickMarcoux One question is it ok if I spam that address?
 
ROTFL
:getout: RT @jmccree @funkatron Is wordpress a micro framework?
 
5:40 PM
@ircmaxell hah, I chuckled at that myself :P
 
lol
 
@JMRboosties you there?
 
@ShaunBrasington yea whats up
 
This is Pyrodante, please go to the android chat room and get merlin to approve me
 
5:45 PM
h/o
 
wait what am i doing once in there
just telling him to approve you?
 
get @Merlin to approve me and say this is pyrodante, I dont know whats going on with my profile
 
OT: Is this a rip-off? lockergnome.net
 
oh i see what you mean, approve to get in
 
5:48 PM
... ok, I see it's open source...
 
@ShaunBrasington no response
 
I see that, sad to I have an answer to that guys question
thanks anyways
 
you can post it here and i can forward it over
what happened to your regular account?
 
nah I don't want to hijack this chat
 
@ŠimeVidas There are tons of rip-offs
 
5:53 PM
This IS my regular account, if you go look at it it leads to my pyrodante account, its just... messed up, I dont know why
 
weird
 
It started when I tried to post in Area 51, that got messed up and the chaos cascaded
 
quite odd
 
I don't know who to go to to fix it though
 
@ShaunBrasington drop a post on Meta, or pop into the chat on Meta
 
5:56 PM
@ShaunBrasington Maybe make a post on meta.stackoverflow.com ?
 
oddly that profile is in tact :D
 
@ircmaxell could you direct me to a resource that explains how to add a library to an apache server
im having trouble finding a good link
 

« first day (447 days earlier)      last day (4498 days later) »