« first day (465 days earlier)      last day (4490 days later) » 

6:12 PM
Is this any better people who were here the other night
<?PHP
$disabled = false;
if(!empty($_REQUEST['problem']))
{
	$problem = $_REQUEST['problem'];
	$disabled = true;
}
?>
<select name="problem" <?PHP if($disabled) { echo "disabled=\"disabled\""; } ?>>"
 
@Gordon How is that not a real question?
 
6:28 PM
@Gordon typo ;)
 
@stevether "not a real question" = bad question that we can't put anywhere else (imho)
 
6:43 PM
@stevether the answer is rhetorical
@stevether and easily googable
@stevether and we have lots of near duplicates for that anyway
 
Then shouldn't it be marker possible duplicate?
It's a legit question I had asked myself when I was learning.
 
@stevether perhaps but people that dont bother to use SO search or google before asking cant expect to be pointed to a duplicate imo. if they are lazy i can be lazy, too.
 
@Gordon It's reasoning like that which will cause the downfall of society >_>
 
@stevether There is still deeper to fall? On SO, I don't think so.
 
Users have always been lazy. But now the mods are too? I thought they were special...
 
6:54 PM
@stevether none of the closevoters are mods. mods have a diamond next to their name. we dont have any. I just happen to be room owner of this chat room along with @ircmaxell. but nothing more.
 
Oh
 
I guess I meant people with enough rep to control stuff
Whatever that would be called
 
@stevether 3k+ users when it comes to closevoting :)
 
@Gordon what did I do now?
 
7:00 PM
@ircmaxell nothing
 
@ircmaxell everything
 
:-X
 
@ircmaxell you killed Schrödinger's cat
 
@Gordon Yes. yes I did
 
7:03 PM
@Gordon @ircmaxell kills kittens
 
PHP chat; Where questions come to die.
That's all I'm trying to point out.
 
Hii all
 
@stevether Duplicative questions serve no purpose but to distract away from already quality answers. We aren't out to kill the question but make the good stuff easier to find.
 
@stevether Yes, we are very effective. On normal days the PHP room is equivalent to one moderator.
 
7:04 PM
i am trying to code a database driven (not folder driven) Image gallery for my site. I want to know how to better organise the photos
 
@NikiC I don't think effective is the right word.
 
@stevether yes, this is home of the and we are just cleaning up the mess. nothing more nothing less.
 
@Gordon bullying*
 
@Gordon Actually, I'm somewhat disappointed that it's only 280.
 
@stevether the unfortunate fact is that the php tag produces craploads of low quality questions of all sorts
 
cooking now laters
 
Hellooo
 
@PradyumnaSharma Howdy
 
@stevether i dont understand why you are defending low quality answer
 
i am trying to code a database driven (not folder driven) Image gallery for my site. I want to know how to better organise the photos
 
7:13 PM
Is it wrong of me to think that doing this is bad:
 $_COOKIE['location'] = $cookie_loc;
or
 $_POST['somevar'] = 'value';
I mean why would you set a superglobal like this and let others go like: WTF?!?! where does that value come from?
 
Tim
7:33 PM
Does anybody here know of an implementation of Glicko, Glicko2, or Elo in php?
 
8:20 PM
@ircmaxell happens quite often :-)
 
should i buy head first php mysql book?? is it a good book??
 
8:35 PM
@Gordon hello shall i buy head first php mysql??
 
8:51 PM
@lucifer i dont know. should you? Ive got head first design patterns and didnt like it. too chaotic for my taste. but there is people who like it very much. you gotta see for yourself.
 
@HoeHoeHoe Loads of stuff can be bad given the right reason.
To answer your question, it's bad depending on how it is used.
Forcing stuff into get/post is a very convenient way of adding SEF URL support to your existing codebase.
 
@ChristianSciberras Can you give an example of when it is valid to do it, because I can only see bad things coming from it
 
For example, you usually used $_GET['page'] to get the id of the current page.
To add SEF URLs, you just parse the redirect_url (I think?) and get an id out of it.
Then you proceed to $_GET['page'] = $that_id;
Voila, no need to change you existing code that makes use of $_GET['page']
 
@ChristianSciberras I would say: Voila, I have now successfully brainfucked the next developer who tries to use / debug my code
IMHO
 
Uhoh, the cv ring has been discovered.
8
Q: Close vote seeding in PHP chat

stevetherI don't mean to point fingers or cast blame on an individual, but I've noticed that PHP chat has a lot of cv-pls requests on questions that I believe are valid, to varying degrees. See here While I am all for cleaning up questions that don't belong, are off topic, etc, I worry that this cv-pls ...

 
9:05 PM
need help with move_uploaded_file()
 
@Charles You feel like scratching my back? ;)
 
it neither give me an error nor moves the file.
 
@HoeHoeHoe ... yeah, no.
 
@Charles I replied to it :)
 
@LeviMorrison Said about what I was going to say.
@PradyumnaSharma I assume you've turned error_reporting all the way up to -1?
 
9:08 PM
no i am getting other errors
BTW iam using COdeigniter
 
You should probably resolve the other errors first.
 
there are no other errors . i fixed all of them.
there two arguments for move_uploaded_file are 1. The uploaded file name. 2. Path to move directory??
 
The second argument is the complete path and new filename, not just a directory
 
first one is just the filename or its full path??
 
The first one is the full filename, as given in the $_FILES array.
It's "rename this file to that file", not "move this file to that directory"
 
9:13 PM
$data = $this->upload->data();
$file = base_url().'images/a/'.$data['file_name'];
$fnm =$data['file_name'];
move_uploaded_file( $fnm, $file );
 
You should not trust the remote filename.
But otherwise, that looks correct.
 
what would be the code withot any framework
i.e pure PHP
 
5
Q: "not a real question" close trigger happy?

Jeroen PluimersI have a gut feeling that lately questions are very rapidly closed as "not a real question" without the OP giving a chance of modifying the question. Example: import data from Excel I presume the OP is not native English, as I see a lot of influx from non-English people too. Maybe these two ar...

 
Honestly, that code is, outside of using the provided filename, correct looking.
 
Interestingly, the question was improved, reopened by a different fixe, and then closed again by yet another set of 5 people. SO sure is interesting.
 
9:15 PM
Run the provided file name through a validator. Say, permit letters, numbers, spaces. Strip the file extension and add one that is known-good and accurate for the file type.
See mime_content_type if you're targeting 5.2 or lower, or the other finfo functions on the left of that page if you're targeting 5.3 or newer.
 
@LeviMorrison Ain't it though.
 
Wow the whole PHP chat crew in one meta question. That's a first :)
 
@HoeHoeHoe hardly the whole crew, not yet anyway.
 
@HoeHoeHoe Interestingly, the cv-ringers are the only ones to answer . . . :)
 
9:20 PM
@salathe true :)
@LeviMorrison :-)\
 
I just don't understand what he wants to actually do about it.
 
I understand his concern.
However, we aren't acting maliciously.
But the fact that we're acting as a group can give the appearance of maliciousness or groupthink.
The only groupthink in here is about how much PHP sucks.
 
I understand his concern too but he doesn't actually point out a specific question that was closed unfairly and there can be other chat rooms that clean up questions in their tags and not use the and would never be caught in his search.
 
@Charles lol
 
9:22 PM
I understand his concern too but he doesn't actually point out a specific question that was closed unfairly and there can be other chat rooms that clean up questions in their tags and not use the and would never be caught in his search.
 
@stevether We're the Mighty Morphing Meta Rangers.
Join us.
 
soo after (trying to) implement MVC design pattern into my project I have determined I would greatly benefit from a solid framework that also handles things like breadcrumbs, and other nitty gritty things that I would just be re-inventing the wheel at this point if I continue making my own
 
@rlemon Breadcrumbs are easy, as long as you use inheritance. . .
@rlemon But we don' need anotha' PHP framework. :)
 
@LeviMorrison the point is, I only was not using a framework so I could get a better understanding of the design pattern.
now that I (imo) have an acceptable grasp on what it is and how I should use/implement it, i'm not opposed to standing on the shoulders of giants and getting some shit done efficiently.
I like reinventing the wheel, it's the car i'm not interested in reinventing.
My question is; what is a good framework (that follows MVC), keep in mind i'm developing a CMS/CRM
 
@rlemon I'm not familiar with too many frameworks to be a good person to ask. I quite like symphony-cms.com , although I haven't followed nor used it in a few years.
 
9:35 PM
ohh no no i'm not looking for a CMS framework.. i mean like CakePHP or Zend (buzzwords for me, I have never used a php framework)
 
Symfony2 may be your best bet right now.
It's the same type of thing as Cake or Zend Framework.
ZF's pretty decent, but I wouldn't recommend it as anyone's first framework.
Cake 1 is to be avoided at all costs. Looks like they finally released 2.0...
 
Guys
 
/flee
 
That meta question is hilarious
That is all
 
lol, thanks @Charles. Why would you suggest Symfony2 over ZF
 
9:39 PM
@BoltClock :)
 
Someone downvoted all teh answerz. lol
 
@rlemon ZF1 is a design nightmare from a concistency point of view, ZF2 is still in development. Symfony2 is said to have high quality and consistency.
@LeviMorrison Why am I not surprised.
 
@LeviMorrison hehe, I noticed that too. Was a nice little chuckle.
 
> Its like a PHP shark tank. With frikken laser beams. – Won't♦ 1 hour ago
2
 
@all hello i want to embed youtube videos into my website. like there should be a box in which i put youtube video code and it shows video on webpage. how can i do that. i googled it but could not find it
 
9:48 PM
@mann You seem to have a lot of issues with video :)
 
@mann Have you tried clicking the "Share" button on a Youtube video, then clicking the "Embed" option? It gives you HTML...
 
@LeviMorrison haha yah mate. since yesterday stuck with this
@Charles yes mate i know about that but i need fb like functionality where i put code into box and video itself appear
 
Simple then. Extract the video ID from the provided string and substitute it into the embed HTML.
 
yah wondering about that.
@Charles if i store that string into session variable and use it will that work?
this is wot you are suggesting
 
@mann your description to your problem is less than acceptable. " i need fb like functionality where i put code into box and video itself appear" what does that mean?!
 
9:56 PM
Because I took that to mean "a user is submitting a Youtube video ID and I want to display the video to the user"
Sessions have jack to do with that functionality.
You may need to clarify.
 
I think he means he wants a OneBox for youtube videos
 
@rlemon ah sorry. actually i need textbox where i put youtube video share code and click on update . then that youtube video should apear on specified area. in this way i want to make youtube video gallery . hope this helps
i want youtube video gallery uploaded by user
 
@mann that is web dev 101 my man.
simple form...
well, time to go home.
 
if user wants to upload youtube video or i would say embed youtube video or share it
 
He there @rlemon
 
9:59 PM
@edorian be quick i'm on my way out
 
Don't let me stop you
 
lol just saying hi?
or did you have a Q?
 
Just a generic wave
 
\o\
/o/
\o\
/o/
^ generic wave
 
Paul Reinheimer's Blog: Cookies don't replace Sessions as I've seen the posting on phpdeveloper I thought "of course you can't .. why is that even an issue.. what a waste". Then i read into the post a little and got quite sad.. Didn't 'we' learn anything from the failure that is asp session management
 
10:19 PM
@Charles it is working with embed code but not with share code. youtube share code
any suggestion mate
 
w00t, looks like the train is getting into NYC. Getting excited about this Etsy talk coming up :) See you guys later
 
@mann what's the difference between share and embed code?
 
@HoeHoeHoe on you tube videos click on share button. there you will see embed code as well. you will come to know mate
 
can't you just post it here? I'm kinda lazy :)
 
@HoeHoeHoe <iframe width="560" height="315" src="http://www.youtube.com/embed/ypMIhmEfK2w" frameborder="0" allowfullscreen></iframe> this is embed code
youtu.be/ypMIhmEfK2w this is share code for particular video
 
10:28 PM
@mann well as @charles said: Can't you just get the id (ypMIhmEfK2w) and use it in the embed code?
 
yah actually. i can . good point :-)
 
:)
 
thanks mate bit tough task but will do
thanks for giving wonderful suggestion
 
11:08 PM
Wow.
Current PHP test results are dismal, though improved: qa.php.net/reports
 
@LeviMorrison which I could closevote on meta yet :D
 
hey
no one is in the css room, anyone wanna quickly help me?
 
hey @user1079641
 
@user1079641 Sorry, still at work.
 
I have a big container div and I want there to be a gap between the bottom of div and the footer
there should always be a gap
so something like this:
|__|
<--gap always present
___
 
11:14 PM
uhhu
 
anyone?
 
I'm still waiting on the question
 
you know the question
 
i have a big div that, when expands, goes all the way to the bottom and the scroll bar only goes to see the end of that div
i want there to be a fixed space at the bottom
so if the div crosses that space, there are automatically scroll bars
something like margins in the bottom
 
11:18 PM
margin-bottom: 20px;
or whatever space
 
on the div or body?
 
the div
@user1079641 http://jsfiddle.net/SSqJP/
 
but i want the footer to have that
so when for any reason the footer expands down
there should always be a little space between the bottom of the window and the container div
| |
|___|
<<-- that space should always be there and under that should be the end
____
 
yeh
 
11:24 PM
margin-bottom: 20px;
on body
 
apparently it doesn't work when i do it on body
 
Try it on the footer then
 
never mind got it
 
:)
 
i had html{height:100%;}
i removed that and it worked :)
 
11:26 PM
great
 
thanks
 
np
 

« first day (465 days earlier)      last day (4490 days later) »