« first day (1823 days earlier)      last day (3107 days later) » 

7:00 AM
@Orangepill I am thinking the same way guys thanks for you suggestions.
 
@RahulThakur that probably should be done in the router (and/or http abstraction). Looks at that part of code, see what options do you have.
 
@Duikboot ... for a truely random number set a unique key constraint on the field and when you insert catch any duplicate key exceptions and generate a new value and try again
 
@Mubeen1992 that's all very nice, but do you still get a failure if you run your import script using CLI? Because if there is no error, then the problem is caused by firefox.
 
7:02 AM
That process should be handled in the back-end because I want to add a user, and add a random generated string in a field but it must be absolutley random.
 
I just want something as simple as this
$app()->options("/", function() use ($app) { return response("", 200); });
 
There will be stored 10000ds of records. So it's not allowed to be duplicated
 
@RahulThakur did you actually looks at the code?
 
@tereško It takes too much time instead it is reading same size CSV file very quickly
 
Need a simple backend api. Don't have experience in this sorry.
I am getting a 405.
 
7:04 AM
Hey all; is an event listener run as a separate thread or synchronously? Specifically referring to Laravel's events system.
 
But why I do not understand, GET requests are working fine. The POST is generating an OPTIONS from the browser and then I get 405.
 
@Orangepill What about generating a random string based on a date/time( current ) value?
Won't that be always unique?
 
@RahulThakur have you enabled cors support?
 
@Duikboot but that's not random
 
Yes, as I said, GET is working fine.
 
7:06 AM
.. Is random ever random?
 
random != unique
 
@EchoLogic depends; are you running event:listen in a separate process and using a broadcaster?
 
in the all of these, "ab" is perfix:
abyrt
abgcx
abloe
abpqw
 
@EchoLogic this is not a Laravel support chat. Try on IRC.
 
now what it "ab" in these:
 
7:09 AM
@Sajad yes?
 
sfetab
gewab
preab
sadfab
 
@Sajad suffix (also sometimes termed postfix or ending or, in older literature, affix) is an affix which is placed after the stem of a word.
 
@NullPoiиteя tnx :-)
 
@Amelia, not sure yet, just trying to architect something right now. High frequency app using websockets, but I also have to interface with a 3rd party API that I cannot guarantee will always be running speedily.
 
@Duikboot maybe you are just looking for a uuid
 
7:09 AM
@Sajad suffix
 
tnx
 
@EchoLogic broadcast all of your events separately (out of the box you can use redis)
 
So the 3rd party API interfacing needs to be run asynchronously so the app doesn't fall over.
 
then listen to them in another process
 
@NullPoiиteя ah
 
7:10 AM
See it as a campaign where users are able to win something, but I don't want 2 the same codes being generated for 2 users. Because... that's not 1 winner but two :P
 
Abe
mornings o/
 
@EchoLogic if you have question about Laravel, please ask them here: laravel.io/forum
 
@EchoLogic by default, you'll use pub/sub in redis
 
@Abe morning \o
 
Also, ignore him.
 
7:11 AM
@Abe \o
 
@Amelia right.
@tereško "Discussion for all things PHP"
 
(Also, this is probably substantial enough for an actual question if you need to scale up eventing)
 
Amelia. That's the thing, I want to try and narrow down my correct architecture before I go an ask questions that are misguided.
 
@EchoLogic if you broadcast your event, the normal queue will then take care of it in a job outside of normal execution, making sure it doesn't tank the web-app
 
7:16 AM
I need too use both "MATCH()" and "LIKE()" in one query, but it has syntax error, anybody can debug it ...
SELECT * FROM table WHERE MATCH(col) AGAINST($var) OR col LIKE '%$var'
 
@Amelia okay, thank you for your help!
 
Abe
@Orangepill congrats for the new job!
 
@Abe lol :D
 
@Sajad I hope you're using a prepared statement there, or that wont look too pretty
 
I love the smell of Java stack traces in the morning … NOT
 
7:17 AM
@Amelia yes I use PDO
 
@Gordon it's better when they're JIRA
because then you get the morning off
 
@Amelia, would an architecture question best be suited for Programmers or CodeReview SE? I've seen a mix of both.
 
@Abe If only it tasted bad right away... that's the problem with the frameworks...
@Abe thanks
 
@EchoLogic codereview is for full, complete programs
 
@Amelia unless you are the Jira admin
 
7:18 AM
@Amelia bullshit
 
@Gordon then you cry to support, reinstall jira and then give up, taking up fishing
 
codereview is for anything that is intended to be merged into master
 
@Amelia I see you'be been there, done that ;)
 
ew, JIRA
why does anyone use Atlassian products
 
@tereško code review is for sissys. commit and break the build like a man
 
7:19 AM
@tereško CR isn't for theoretical questions, was my point
 
@Andrea they are not that bad once you learned how to use them tbh and they integrate nicely
 
@Sajad what error did you actually get? Also, why are you concatenating the query?
 
Pretty much every company I've worked for has used bitbucket purely because it has free private orgs + repos, so they naturally just start using all the other products
@Gordon and yes, I have :p
 
@Andrea because that's what other project managers use ...
 
jira isn't as horrible as it could be. try salesforce some time.
 
7:22 AM
Hrm, If I have a issue, that I have found a solution to myself, but believe that it is not the smartest solution, would the question be on- / off-topic for SO, or would it perhaps be better suited for the codereview site?
 
@PaulCrovella you should try integrating jira with salesforce
 
we did that
 
ouch
 
Integrating service desk with salesforce was fun
And by fun I mean horrifying
Rule #1: never let marketing or the CFO hold the reins for development. They will crash a bugatti into a wall, try to douse the flames with diesel, and then blame someone else
 
@tereško oh! I have not error anymore! I don't know how it is right!!! it is odd!
 
7:24 AM
@Sajad then now you just have to get rig of the injection vulnerability
 
@tereško why are you concatenating the query? Because I need to search in multiple columns and MATCH() does not support suffix. then I have to use LIKE()
@tereško in reality I use question mark ? and PDO
 
oh
 
this sentence is correct?
 
btw, in PDO it is more common to use named parameters instead of question marks
 
How to search for the data that has suffix?
@tereško ah ok
 
7:27 AM
like some% ?
 
@NullPoiиteя I want to select "test" in this: ttttest
 
what you really wanted to ask is: "How do you search for data based on it's suffix?"
 
@tereško yes tnx
 
Question: has anyone used PuPHPet configs in production?
 
@Sajad yeah, well, I get a feeling that you are trying to solve the wrong problem
 
7:29 AM
so there is any better solution ?
 
@Amelia is that some Puppet port?
@Sajad it depends on what exactly are you looking for with that query.
 
@tereško I have a small table (for example) in here, please take a look at it and tell me your solution
 
@tereško puphpet.com – it's a puppet config generator, I was wondering how sane it is, so I could suggest it as a starting point for an org that doesn't even have config stored anywhere
 
morning
 
@Sajad well, I gathered that much already. But that's not what I was asking about. What I need to know is what problem do you intend to solve by searching those suffixes.
 
7:32 AM
@tereško ah, as I said in the quesiton, I need to search for suffixes data using MATCH() instead of LIKE()
 
why?
 
because MATCh() is more optimized and really faster
 
and now I am utterly confused
 
look, I have 3 columns
column-1 and column-2 are fulltext
and I have a index like this: match(col1,col2)
now, I want to instead or col3 like '$anything', add col3 to that match, something like this match(col1,col2,col3)
 
@Sajad Both LIKE and MATCH will result in a full table scan in your case. They're equally slow.
 
7:37 AM
@Sherif unless you know something that I dont, I am tempted to call bullshit on that
 
yes, but which one is better:
match(col1,col2) against('$var') or col3 like '%$var'
 
@Sajad use whatever you want than cache result with memcached and you can become nerd :D
 
or
match(col1,col2,col3) against('$var')
@NullPoiиteя :)
 
this whole thing feels like another XY problem, but he refuses to tell what he is actually trying to do
 
ok, I will tell you my structure in reality (in 5 more minuts) and you tell me a good query ...
 
7:41 AM
that probably won't change anything
 
so, what is your question exactly ?
 
@tereško Well, he wants to match the suffix of a word, not a prefix, which means MATCH does you no good. At that point you're no longer performing a boolean naturual language search. (i.e. you can't take advantage of the full-text index).
 
@Sajad what is the problem that you are trying to solve?
what you have given us are variations in your devised solution (the query) and not the problem that you were trying to solve by writing that query
 
@tereško the output is not what I want, then I need to change that query
actually I'm creating a search engine, something like google, and I need to search in all columns of database for everything, so in my query, does not select a word it a dot be behind it, like this: hello .how are you?
I need to select that sentence if $var = 'how'
 
I'm creating a search engine, something like google :D
 
7:48 AM
You have a long way to go learning about search my friend.
 
yes I know ...
 
What you're looking for is called a suffix-tree. That is the fastest way to do suffix-based substring search.
MySQL doesn't support it.
It only uses prefix tries in full-text search.
 
oh really?! shit
 
Which do you no good in this particular use case.
Hence why I said they're both going to result in a full table scan in the query plan anyway.
Anyway, boring problems are boring use Sphinx.
 
FULLTEXT index stores a list entries for each full word .. for example, if would have a list of all rows that contain "foobar", but it will be a different list of rows containing "bar"
 
7:50 AM
but really I can not change my database, I think ignoring the problem and continue with MySQL is better
@tereško can you define a full word ? every word that is between space?
 
you've got "management material" written all over you
 
@Sajad basically, yes
 
@PaulCrovella He's going to make a lot of employees very sad one day :)
 
Aug 29 at 20:59, by tereško
though, @Sajad, I would recommend using Sphinx search engine.
besides, Sphinx is not a replacement for MySQL server in same way as PHPMyAdmin is not a replacement for MySQL server
 
@tereško my teacher threatens me all the time and tells me your time is over ... so really I can not switch to Sphinx
 
7:53 AM
it is an application that runs on top of MySQL
 
It's one thing to have the balls to want to solve hard problems, but the minute you've adopted the attitude of "I think ignoring the problem and continue ... is better", you're already fucked.
 
@tereško what?? the query should be changed ?
 
nevermind
 
why?
is it possible to I use it now?
 
if you are out of time, then you should focus on "making it work" .. adding new technology will require additional time for you to learn it
 
7:55 AM
ah! ok you are right
 
and forget about optimization
for now, if something actually works, then it is good enough
 
@tereško really and really I can not, when I use one IF() statement in my code, I can not sleep !
5
 
Your priorities are pretty screwed up.
 
@Sherif some fucktard from this room linked him to some "ifs are bad" post, when he was just learning how to write an echo.
 
Yea, I don't blame the fucktard from what I've seen here.
 
7:59 AM
I like to blame everyone
 
I'm just saying... there's a certain type of people that love to devote the bulk of their time to solving all the wrong problems and they're usually the ones screaming the loudest about "I can not do X in my code because it's bad".
 
for using LIKE(), should I use indexed in the database or fulltext-indexed ?
 
Mean while, X is relatively harmless compared to the nightmare that is Y, which they're doing consistently.
 
@Sajad the index will not affect how LIKE works, IIRC
 
8:01 AM
@tereško Sure it does. But only very specific cases.
 
well, yes
 
so? I index that column or not ?
 
@Sajad You could literally stand on your head right now and it would still have negligible effect on anything you're doing.
Mostly because you are trying to destroy a tank with a fly swatter at the moment.
@PaulCrovella I feel like I'm in the 80s again
 
do you mean my codes and my algorithms are bad?
 
What algorithm?
 
8:05 AM
using match() and like() for search (and mysql)
 
That's an algorithm?
wow
@Sajad I mean because you clearly have no fucking clue what you're doing. You can't tell an algorithm apart from a hole in the wall.
 
ok, I feel I need to some sleep
 
I haven't seen any of your code to say anything about it, but it's pretty obvious you're lost, which would have been fine were you to demonstrate an iota of humility and willingness to learn. All I see is arrogant stupidity.
 
anyway, @Sherif and @tereško thanks for your gauidance
 
hello every one i just need a minute of your timing
 
8:08 AM
u wot m8?!
 
mornings
 
30 seconds left
 
my timing is incompatible with your minute I fear ^^
 
Do I need to give you my stopwatch or something?
 
8:09 AM
$_SESSION['message']="Password Updated";

header("Location: change_password_student.php?id=$uid");
 
1 minute. mark.
 
OK, that'll be $9.99 please.
 
i have this msg in session and i want to display it to user after my page is redirected
but first time is shows me error of undefined variable session
 
Did you call session_start()?
 
<?php session_start();
require_once("../includes/db_connection.php");
require_once("../includes/functions.php");
$username=$_SESSION["username"];

echo $_SESSION["message"];
$_SESSION["message"]=null;
 
8:11 AM
309
Q: PHP: "Notice: Undefined variable" and "Notice: Undefined index"

Pekka 웃I am running a PHP script, and keep getting errors like: Undefined variable: user_location in C:\wamp\www\mypath\index.php on line 12 Line 12 looks like this: $greeting = "Hello, ".$user_name." from ".$user_location; What do these errors mean? Why do they appear all of a sudden? I used to u...

 
i just want to ask how can i store a default values in $_session
 
@eexamilm Did you bother reading the error message? Because I bet it's pointing to $username=$_SESSION['username'];
@eexamilm if (!isset($_SESSION['username'])) { $_SESSION['username'] = 'default value'; }
 
we all should change avatars to facepalms
 
undefined variable message
there is nothing wrong with $_session['']
 
oh dear
 
8:13 AM
the case of the variable name ...
 
there is nothing wrong with $_session['username']
 
Not enough coffee for this yet
 
@hakre .. break glass
 
hopefully expensive one ;-)
 
/me has been reinstalling VPS
 
8:14 AM
it shows me error because first $_session is null and when i refresh the page it works fine
 
it's fun
 
@eexamilm Here's a hint about reading error messages... Step 1) Read, Step 2) Read carefully, Step 3) Reread even more carefully, Step 4) Keep reading, Step 5) See steps 1-4
Hope that helps.
 
( ! ) Notice: Undefined index: message in C:\wamp\www\ILM_FINAL\public\change_password_student.php on line 6
 
Good, you know how to copy/paste, but do you know how to read?
@eexamilm What is it saying is undefined in this message?
 
can i copy paste my code here??
:P
 
8:17 AM
1 liner is fine, but can you also take the 2.5 seconds that is required to answer my question?
We gave you a minute of our time the least you can do is give us 2.5 seconds back.
 
not sure why I bother even digging up links anymore
 
@eexamilm please read
309
Q: PHP: "Notice: Undefined variable" and "Notice: Undefined index"

Pekka 웃I am running a PHP script, and keep getting errors like: Undefined variable: user_location in C:\wamp\www\mypath\index.php on line 12 Line 12 looks like this: $greeting = "Hello, ".$user_name." from ".$user_location; What do these errors mean? Why do they appear all of a sudden? I used to u...

 
@PaulCrovella Isn't it faster to just Google everything now?
 
it's faster to not bother at all - shit just gets ignored anyway
 
There are way too many shits on the Internet to absorb!
 
8:20 AM
@Sherif sorry! it shows me error because i am assigning $_session[message]="message" and end of my code and i am redirecting back user to the same page and displaying message on the top. first time it shows me error when i refresh the page it works fine
 
stop repeating
and read the damned post that we linked you to
 
hahahah.. sorry. i am reading now
 
@eexamilm No, that is a conclusion you're trying to draw about the error. My question is actually far simpler than that. I'm only asking you what the error message is telling you is undefined. The answer is in the actual error message and is one very specific thing that only requires a single word indicated by the exact line of code specified in the error message.
It's not a trick question that requires more than the alloted 2.5 seconds of thought :)
I promise you.
@eexamilm Also, here's another hint: The error message has absolutely nothing to do with variable assignment whatsoever.
Look at the line of code it's pointing you to in the error message.
The interpreter isn't trying to trick or confuse you. It's actually giving you very specific and helpful information to debug your problem.
 
thank you @Sherif @tereško
 
mornign
 
8:29 AM
@PeeHaa You spelled Tuesday wrong.
 
And what a horrible day
 
Not nearly as horrible as it's father: Monday
At least on Tuesday I don't have a dozen meetings lining up my entire morning.
 
Meh. I need to re-install my machine again to get rid of windows 10. So another day wasted on this crap
 
didn't the upgrade come with a rollback thingamajig?
 
It's a fresh install. My previous machine crashed like a pro
 
@Orangepill nice1
 
posted on October 13, 2015 by nlecointre

/* by BuckTheBug */

 
I thought the coding love got voted off the island
 
Dunno. If everybody really has some issue with it I will remove it
 
Anonymous
I actually emailed to the devs asking if they were living below the poverity line
 
Anonymous
8:42 AM
too much shameless ads
 
@samayo I had a twitter "conversation" with him. idiot...
 
@samayo I would have tried to find it, but I don't understand twitter's search
 
HALP! MY PUBLIC KEY HAS BEEN COMPROMISED! IT'S OUT THERE NOW!!!
 
@Sherif old
 
Anonymous
@PeeHaa I think I found it
 
internet makes me sad
on the upside, if TPP and TTIP go through, internet might not be an issue soon
 
@samayo Yeah that's it
 
@kelunik No problem, I'll just wait for public release then
 
@tereško The Transatlantic Trade and Investment Partnership?
 
9:01 AM
yes
 
I don't understand the link between that and the Internet.
 
according to what has been released by wikileaks, the whole thing is a nightmare
 
Yes, but how does that make the Internet a "non issue"?
I mean, how is that an upside?
 
well, when internet is destroyed, it wont make me sad anymore
 
But will it make you happy when you can no longer talk to all the charismatic people of room 11?
:p
 
9:05 AM
especially Sajad
 
:D
 
well, I especially like the "ISPs are responsible for legality of content" ... which would basically end up as white-lists
and the "make reverse engineering illegal" is also a fun one
 
Sounds like Oracle
 
but then again, I have not finished reading the whole thing
@Sherif it's probably one of the corporations which wrote it
oh ... and it also says that you can be fined any amount for breaking DRM
 
Any amount?
I'll pay $0.01!
Who the fuck buys into DRM these days anyway. Spotify for music, Netflix for movies, done.
 
9:11 AM
no, they can demand you pay any amount
 
Fuck DRM and the idiots that thought it up.
 
this should give you some feel for the scale
 
@Sherif Both use drm..
 
@PeeHaa Yes, but who cares because you pay a flat service fee to consume an unlimited quantity of content.
Doing it any other way is just stupid.
 
right, don't buy into drm - rent into it
 
9:21 AM
That is what people want these days. Especially the younger generations. Nobody really wants to own anything anymore. Everything is streamable.
You watch the movies your friends are watching, listen to the music your friends are listening to, and you change your mind a million times a minute. So why own anything?
At least some businesses have figured this out and found a way to capitalize on it.
The times when people buy into the content of a few key content creators is long gone. Today everyone wants to be a content creator and the desire to buy into mass markets is ever diminishing.
 
@Sherif block scoping is fine for large functions… but well… the inherent issue is that large functions should be discouraged anyway :-D
 
@bwoebi Damned if you do, damned if you don't?
 
@Sherif just don't have large function bodies^^
 
9:47 AM
-insert fake fat-shaming outrage-
 
has anyone ever received a 'Compilation error' from json_encode?
 
What are you asking in specific / what is your actual question?
 
well, i'm trying to json_encode an array, and i get:
i'm using a codeigniter based cms and this error is actually only on certain pages
so the error may not be php related, they may be doing something on those pages
eh so bare with me, i've only just found -that- out
 
what is your complete json?
 
10:01 AM
 
@NullPoiиteя me?
(i'm not using JS? :p)
i'm trying to find out if this CMS is doing something to json_encode or changing the encoding somewhere.. something like that
like i said, it works on some pages, and not on others
 
sorry i meant jsonlint
 
@AaronHarding I think that error is specific to CI
I have never seen something called "Compilation error"
The next few words are telling though
Parse error
 
^this btw if your json is valid than problem is at elsewhere
 
Which would suggest just a normal php parse error. I.e. check your code at / around that line
 
10:04 AM
@PeeHaa yeah, i think you're right. thanks
i've just searched 'Compilation error' and you're right, it's coming from Dwoo
i.e. not PHP
i think there's a confusion between this and Dwoo's templating syntax, like Dwoo is being given the json_encode function and trying to compile it
anyway, thanks, i'll take it up with the CMS
 
I have a dwoo microwave
no wait, daewoo
 
I know, but I'm pretty busy at the moment (working full time until project is done) :(
First I'll have to go over DB stuff and then security
 
security?
 
what are other major manufacturers in the InWin & Lian Li market segment?
 
10:14 AM
@Patrick that stuff is security? isnt it standard development process/practice
 
Well ACL, not security
security is other stuff like xss and co that I also try to cover in the tutorial
 
true it would be really nice
 
You know, rather than a dubious title like "Create a PHP application without a framework", why not consider something more along the lines of "Learning Good Software Architecture in PHP"? Because that's what you're really trying to teach here. Pitting a framework as good or bad is just going to attract the wrong kind of crowd, or worse deter the right crowd.
 
@Sherif Hehe, "Create a PHP application without a framework" sounds like a "this is going to be more painful, time-consuming and frustrating than it should be but it's good for you" title.
 
Yea, that's probably how some people are going to read it.
 
10:25 AM
Well the whole thing started out in here because people were getting told to not use a framework and nobody knew how to start without one
I never expected it to grow as big as it has become
I'll definitely consider better titles :)
 
@Jimbo Just doesn't make sense to publish something now while nobody can actually use or test it. ;-)
 
@Patrick Teaching technical people how to think is always going to be more valuable than teaching them *what* to think. For example...

> *I saw a lot of people coming into the Stack Overflow PHP chatroom and asking if framework X is any good. Most of the time the answer was that they should just use PHP and not a framework to build their application.*

I'd much rather learn *why* the answer was don't use a framework than be told *this is what others said*. At least then you can make an informed decision whether or not a framework is or is not the suitable choice for you when looking at you
 
@kelunik I know I know, I was hoping to get in before others so I can get it working
Being generally impatient :)
 
wow, SO chat markdown really breaks down on multiline messages, huh.
 
@Patrick you really seem to like the word "now"
especially when you need to start a paragraph
 
10:40 AM
Now what's wrong with now?
 
Anonymous
now kids, please get along.
 
@tereško I tried to vary things as much as possible, but things get repetitive in a tutorial
And English is not my first language, so I might not be aware of all the alternatives :)
 
10:56 AM
@PaulCrovella Now is the new new
 
Now I know. Who knew?
 

« first day (1823 days earlier)      last day (3107 days later) »