« first day (2315 days earlier)      last day (2627 days later) » 

Wes
12:09 AM
embrace newspeak
 
Ministry of Truth
 
@littlepootis I think it would be Ministry of Intersectionality
 
12:25 AM
@pmmaga re: github.com/php/php-src/commit/… how about bin2hex instead?
 
@tereško i made an api, it was alot eaiser than i expected
can i show u it just to see if i did it reasonaly well
 
12:47 AM
@Jimbo
Where is your hotel room?
 
1:03 AM
@tereško Google gives me some very different suggestions
The ordering of those suggestions is rather curious :|
 
Buddhism showed up in my list
 
"mp3 in itunes" showed up in mine
 
This says a lot about what we each do on the web that Google tracks, eh?
:p
 
I don't even use itunes
 
pdf, islam, mp3, islam (again - yes, for real)
google knows I has a beard
 
1:10 AM
Location probably plays a big role in such a generalized search.
 
Brexit capital of the world
 
1:26 AM
Meh. Tired as hell. Can find reason why hash in PHP and Java is different
Only difference, that I see is, that Java operates with byte[], where as I operate with strings in php
 
Hello. I have a 300 point bounty question on the chopping block. Would anyone care to comment on it? I am taking all advice and criticisms as an opportunity to learn. stackoverflow.com/questions/42172228/…
 
@AnthonyRutledge "typically", no.
 
@Sherif Good to know. Thank you. ;-)
 
@AnthonyRutledge if you're looking for code review try codereview.stackexchange.com
 
@Paul Thank you, Paul. I'm not looking for something that detailed. Pithy comments and suggestions will do. The burden is on me to learn. ;-)
 
1:41 AM
Pithy comments and suggestions are conducive to learning?
 
@NikiC or @JoeWatkins are still around?
 
@Sherif They can be. They can be.
 
Wes
meanwhile, in japan en.rocketnews24.com/2017/02/13/… (NSFWish)
 
@AnthonyRutledge I suggest that when it comes to the terms "PHP" and "MVC framework" being used in the same sentence that you abandon, at all cost, ideological thinking and stick with pragmatism.
 
1:49 AM
@Wes They must use a lot of febreze in that office.
 
@Sherif Noted. I am not trying to mimic a specific implementation. I cannot even say what I did is "MVC-ish". My primary goal is simply to have a single point of access (URL rewriting) and have it chose the correct, what I call, "webpage object" for that page/request. Then I want that "webpage object" to do variable interpolation and any necessary method calls (not raw PHP) in a template. Then, the page should be transmitted.
 
@AnthonyRutledge Which is a grossly ideological way of approaching that goal that leaves too little room for pragmatism.
 
@NikiC I'll try to review this - poke me about it, I'm bad at remembering to do things, but it's in my area of code-touching
 
@Sherif I can see how you would draw that conclusion, but this is the result of a process of refinement. Until now, I named all my pages index.php and put them in various directories. Therefore, the mandatory security code (What I call, "the opening sequence) and layered catch block (the "closing sequence") was repeated in each file.
 
@AnthonyRutledge I didn't make it past the title, knee-jerk hit me at "typically", and the fact you're in the PHP room...
 
2:03 AM
Typically PHP is surfeited with MVC.
 
@Leigh Point taken. But, since I do not use any PHP frameworks, I figured casting a wide net would yield good results. ;-)
 
The question looks well written - I'll admit I haven't studied it. Are you sure you haven't tried to shoehorn something into a pattern?
Hey, I avoid frameworks. I use a router decoupled from the rest of the app
 
morning
any native english speaker around ?
 
Why? Are you conducting a census?
 
Hmm. Well, I'm only 63/64 English, as far as I'm aware...
so I need to duck out...
 
2:05 AM
just trying to get my tables fields names correct ;)
I am developing an investment platform with loaners and investors
do we agree that the percentage of money investors gain are called profit
 
@Leigh Well, if you have any thoughts I am open to hearing them. Just post comments on the question itself. I tried to be clear enough for the "heavy hitters" (and you know how they can get around here). :-)
 
and the loaner percentage of money they give back are called interests
right ?
 
@Valentincognito That depends on the context. Profit is a generic term (one not specific to any particular kinds of profeteer).
 
@AnthonyRutledge It's weird. I actively try and avoid interacting on SO questions now :/
 
there's something weird about that?
 
2:07 AM
ow.. I thought I got profit right , I wasn't sure about interests
 
we still use SO, just not for it's purpose
 
SO's purpose died long ago
 
"we" know that, but we didn't all up and migrate to IRC did we
 
@Leigh I see. Well, I think SO is highly useful and educational, especially when it is combined with some structured learning or experimentation.
 
@Valentincognito If you want financial jargon: There are two kinds of interest (yields and rates). Interest yields are profits paid to investors and rates are profits paid to lenders on sums borrowed.
 
2:10 AM
@AnthonyRutledge so my knee-jerk reaction is.. why does your router have to be an "mvc router".
 
@Sherif Alright thanks for yields and rates , I will read more about those two
 
routers just wanna route, no need to make them do something crazy
 
@Leigh inertia
 
@PaulCrovella absolutely. And I 'd lose contact with all of these amazing people if we lost this resource. I'm clinging to it.
 
@Valentincognito e.g, APY (Annual Percentage Yield) is something you'd see on your savings bank account, as the percentage paid out to you annually on your money. APR (Annual Percentage Rate) is something you'd see on a credit card or loan from a bank, as the percentage paid out to the creditor annually on the money they lent you.
 
2:12 AM
I did wonder why you pinged me.. and I read it twice :P
 
@Leigh Poor hand-eye coordination.
 
@Leigh Good question. Separation of concerns. If I am able to make this work, I will be able to decouple most logic from the HTML. If I need to change something about the security code, I don't have to go changing in in 50 places. If my friend wants to work on a file with HTML, I do not have to worry that the security code might get messed with. Stuff like that.
 
still educational :)
 
@Sherif Thank you very much I didn't know those words
 
@AnthonyRutledge ah man, you dropped the s-word... now I have to scroll up
 
2:14 AM
<script>
$.ajax({
url: 'new_content.php',
 
@Leigh sucker
 
security
:(
 
@Valentincognito The jargon obviously gets far more specific depending on which sector of the financial industry you're putting into context. For example, the stock market is a totally different beast. Also hedge funds don't have interests, for example. They have something called dividends (*how the profits are divided up amongst the principle vs. intermediary investors).
 
Hi, Twig- jQuery question: How to provide path to the file inside Twig <script> ?
<script>
$.ajax({
url: 'new_content.php',
 
@Sherif I can imagine there is a lot more to know.. The thing is I work for a korean company so they give me those technical words in korean but they take a lot of shortcuts and actually use a simpler vocabulary than I would in french or english. I am just trying to have understandable field names for the DB but I think I am going to go with rates and yields
 
2:20 AM
@Leigh Basically, I have created a "server-side DOM". No, not Node.js. Each page in my site has a "webpage object" that contains all the required logic for that page (especially for manipulating form controls (enable, disable, show/hide), error messages, and CSS). It helps with progressive enhancement, but is implemented to expect AJAX calls, too.
 
would someone be able to help me, im trying to make a form activate a console.log but i think the page refreshes so quickly, its not logging
	<form id="apiForm" onsubmit="sendAPIRequest()">
	  <input type="submit">
	</form>

	<script>
	function sendAPIRequest()
	{
		console.log("hi");
	}
	</script>
 
@RachelDockter Submitting a form causes the page the refresh. Your console logs are cleared on each refresh of the page so you will never see it.
 
ah i thought so, any way to get around this?
 
@RachelDockter I think you can check an option in chrome dev tools to not clear the logs on refresh
 
@RachelDockter Submit via XMLHttpRequest
 
2:24 AM
check the preserve logs box
 
it was for other people which will clear every time for them
whats xmlhttp request and is it hard
actually wait i can do this in jquery it doesnt need to be a form
nevermind
 
JavaScript has an XMLHttpRequest object that you can use to submit forms without refreshing the page. developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/…. It can be challenging, depending on your goals. I use it without jQuery.
 
thanks im gonna look at this for future
 
@RachelDockter No problemo. Maybe you will help me some time.
 
i could try lol alot smarter people here though than me
 
2:33 AM
@RachelDockter Yoda Speaking: "Smart by self, no matter. Experience counts, too. There is no try, only do."
 
The key to using the XMLHttpRequest object is to understand the use of a "callback" function. PHP uses call backs for some functions (sorts and such). Some people use anonymous functions (which PHP has, also) as the "event handler" for an XMLHttpRequest.
 
@RachelDockter fetch is easier
 
@RachelDockter in PHP, we are use to using forms in a synchronous fashion (form submits, page re-draws, etc ...). With AJAX, you use the form on the client-side in an asynchronous fashion. In other words, with AJAX you only replace / update elments on the screen, instead of having the entire page redraw.
 
2:40 AM
its ok im doing it through jquery now, im gonna read on xmlhttprequest incase i ever need to do it through forms
thanks @AnthonyRutledge for the info though
 
And with that, I'm out. :-)
 
2:57 AM
can anyone help me with an archlinux question?
I am trying to setup the LAMP stack with php
 
(Symfony) Is it possible to get from Twig template a file that is not in web/ but in some deep project structure?
 
 
2 hours later…
4:45 AM
morning
 
morning
o/
 
\o
 
5:17 AM
o/
 
5:31 AM
~o~
 
fancy
 
5:44 AM
Moronings
 
5:58 AM
\o
 
o/ mornin Joe,Paul Saitama
 
Hello :)
Whenever I try to make that right div stretch down to fill the entire column, it pushes everything down. how do i fix this?
 
any html savvy people here?
willing to pay for a small project
 
you up for a small paid job? ^
 
6:08 AM
I was waving at @Linus
 
woopsey
 
mornin
 
'nin
 
\o
A new day has come with new opportunities :)
 
haha I should really get some sleep
 
6:52 AM
gud afternoon
Any one using slim php framework
 
R.P
@AnishChandran - used a bit
 
$sql = "INSERT INTO $userName (day, P1, P2, P3, P4, P5, P6) VALUES
('MON1', '$p1MON', '$p2MON', '$p3MON', '$p4MON', '$p5MON', '$p6MON'),

('TUE1', '$p1TUE', '$p2TUE', '$p3TUE', '$p4TUE', '$p5TUE', '$p6TUE'),

('WED1', '$p1WED', '$p2WED', '$p3WED', '$p4WED', '$p5WED', '$p6WED'),

('THU1', '$p1THU', '$p2THU', '$p3THU', '$p4THU', '$p5THU', '$p6THU'),

('FRI1', '$p1FRI', '$p2FRI', '$p3FRI', '$p4FRI', '$p5FRI', '$p6FRI')";
Afternoon
How could I change this INSERT INTO so that it is Update?
 
7:08 AM
You mean to update it?
 
why to change can't write update query?
 
Yeah. So instead of inserting those values, I need to update them
I don't know how to write an update query in my case
Really new to PHP
 
UPDATE table_name
SET column1=value1,column2=value2,...
WHERE some_column=some_value;
 
So for me it would be
I'm so confused, aha
 
7:14 AM
Thanks Linus
 
7:26 AM
@R.P I have a problem not getting post parameters. Its working perfect in local . I have check with POSTMAN extension. In production server its not getting. I just dig up request method shows as GET not POST
 
R.P
7:37 AM
@AnishChandran Is there any chance that You are using routes caching?
 
@R.P route caching means
 
$sql = UPDATE Caspar SET P1 = "test" WHERE day = "MON1";
Pulling my hair out
Whats wrong with this update?
 
@R.P am new in slim
@R.P am not using root cache
 
Morning everybody i have a question . I m inserting an excel file into database which is a huge data, using codeigniter. Now i want check on some data to check if it is already there in the database or not. Like my column name is sample_ID which is unique the whole data in the sample_id should be checked and if it is there it should give an error.
 
@Caspar maybe one of the column names are reservered keyword
 
R.P
7:45 AM
@AnishChandran In production You also tried with POSTMAN?
 
it should be very clear if you check the error you get back?
 
@R.P Yes
@Caspar your query is correct what is the error you got?
 
R.P
@AnishChandran is there a way do debug, what is the value of $_SERVER['REQUEST_METHOD'] before $app is initialized?
Never ran into problem like this, might not be slim related
 
@Caspar it's because day is a reserved keyword
you should use backticks around your column names to avoid naming collisions
as in `day`=
 
@R.P its showing GET
@R.P in local its showing POST
 
8:04 AM
backticks?
How do I type a backtick haha
 
R.P
@AnishChandran in that case it's servers configuration problem. Is redirect done by apache module or something?
but for now, going away from keyboard
 
@Caspar is that a question?
 
English keyboard. I don't have backticks.
 
Are you effin kdding me?
 
I know, right
Where's yours?
 
8:07 AM
So you think everybody with a english keyboard cant make backticks or that all chars you can make from a keyboard should be on the keyboard as a single click thing
lol
Have you searched how to make backticks
I promise you, you wont have to copy paste it
 
key to the left of 1
 
just please search for it when in doubt
 
`
Ty
Sorry for the stupidity
 
backtick is just shift tick
 
Anyone using cakephp?
 
8:10 AM
fffff mornings
 
@Caspar np I dont consider it stupidity, just a bit morning lol
mornings @Leigh
 
moring GorEigh
 
<?php

$p1MON = strval($_GET['p1MON']);

error_reporting(1);
echo $userName;

$con = mysqli_connect('localhost','XX','XX','XX');
if (!$con) {
die('Could not connect: ' . mysqli_error($con));
} else {


$sql = UPDATE $userName SET P1 = $p1MON WHERE `day` = 'MON1';



if (mysqli_query($con, $sql)) {
echo "okay";
} else {
echo "error";
}
}
mysqli_close($con);

mysqli_close($con);
?>
Oops. Forgot to format
 
@Trucy not sure what that is supposed to be
 
Can anyone notice any syntax errors here? Getting internal server errorl
 
8:12 AM
user image
10
php cake ...
 
Oh no.
 
Two choices as far as I can see... 1) actually go to PHPUK, 2) go back to bed
 
Anyone feeling up to helpimg
 
@JoeWatkins or cakephp
 
@PaulCrovella and cakepthreads and caketux and cakeoctocat ...
 
8:14 AM
@Caspar "internal server error" is your cue to check your server's error log
 
wife had those made for my 30th birthday ...
 
I'm not hosting the server.
So how can I view it?
 
@Caspar there's your problem ...
 
So, what can i do.
 
get yourself a server
 
8:15 AM
Hmm. For now, what can I do.
Can you spot any obvious errors.
 
And a IDE or code editor that makes sense
Yes
 
get yourself a server now
 
I spot a pretty major syntax error which a editor should highlight for you
$sql = UPDATE $userName SET P1 = $p1MON WHERE day = 'MON1';
 
learn php and mysql too.. :P
 
8:16 AM
@JoeWatkins is it your birthday?
 
@Trucy no, was couple of years ago ... someone mentioned cakephp ...
 
What are you using for writting the code in also? As Joe is right, its annoying to write code when you cant access the logs, have you considered developing locally, as in your local computer?
 
I haven't considered that, no
But
What was wrong with the UPDATE?
 
That its not a string
 
I use GoDaddy's web editor, haha
 
8:18 AM
you are fired
 
oh. my. god.
 
I know.
Rip.
 
Please tell me why are you developing on a remote server?
 
yeah, totally fired, also, I kick you on the way out the door ...
 
I started a month ago and I haven't thought to change.
I don't have a spare computer lying around to host a server.
 
8:18 AM
you don't need one
 
@Caspar you dont have to do that, I understand this is all new but develop you code locally on your computer
 
I can't decide if that's better or worse than writing code with ms word
 
and when it's done and works, you can deploy it on your hosting (godaddy or what not, even if godaddy is evil and bad)
 
lol
 
But then it would only be online when my computer was, right
 
8:19 AM
it's exactly the same sort of crappy @Paul
 
Yes, but server based stuff doesn't work for me when I write it, save the file and open it using chrome
 
@Caspar thats because you are doing it wrong
 
Do anyone know plugins in cakephp?
 
Which OS are you on?
windows?
 
Mac
 
8:20 AM
@AartiBhardwaj only rm -rf
@Caspar okay, you need to install apache2 or nginx .. and mysql
install a code editor or IDE
 
Right, and then it will work?
I got sublime.
 
download your project
and make it work
 
But sublime doesn't highlight syntax errors.
 
sublime would be fine, sublime does highlight completely nasty errors
I think
 
$sql = UPDATE $userName SET P1 = $p1MON WHERE day = 'MON1';
 
8:21 AM
or there's always apachefriends
 
Is that right.
 
Oh.
 
@RonniSkansing i am already using sublime and apache2
 
omg, stop pasting that code
 
8:21 AM
meurning
 
Sorry joe. lol
 
@AartiBhardwaj it wasnt for you
 
Help Ronni
 
@Caspar $sq = " bla bla bla ";
 
start at the beginning, before you do anything, you need an environment which you control in which to develop your code
 
8:22 AM
^ see thats a string with SQL inside of it
 
Oh.
 
@RonniSkansing didn't terminate the statement
staph
 
yea okay, take Joes advice, its good
 
36 secs ago, by Joe Watkins
start at the beginning, before you do anything, you need an environment which you control in which to develop your code
 
8:23 AM
How difficult is it to host a website off of a separate PC I may have lying around
 
you're not going to do that
install something like xampp
there's a version for mac, make sure you use php7
when you have it installed, copy your code base to the webroot of xampp, and open localhost
 
Plugins plugins plugins?
 
Alright. Ronni. Not getting a server error anymore, but when I place 'echo 'hi';' inside my PHP doc it doesn't echo anything
Not connected then, is it?
 
/me gives up with bad listener
 
Sorry Joe
Appreciate it.
 
8:27 AM
the JS calendar plugin we're using doesn't support BYSETPOS rule, I can't schedule "every Nth Friday of the month"
The error is "Invalid recurrence rule, see [link to RFC]"
 
what is an JS ?
 
Bitch I'm literally following the RFC, it's you who's wrong
 
@Caspar it feels like your just looking for quick fix and not fixing the broken foundation
 
@JoeWatkins like PHP 5 but even shittier :p
 
That's exactly what I'm looking for,
 
8:28 AM
PHP 5 is some sort of ruby on rails clone I think, right ?
@Caspar you are doing it wrong
 
Agh
I knoq
I know
I just want to fix this
 
@AartiBhardwaj sorry I dont think anyone really uses cakePHP or will admit to it
 
D;
 
fixing one window will do, right ?
you can just live in that one room ... all will be perfect ...
oh wait ...
 
@RonniSkansing Thanks atleast you replied
 
8:30 AM
@JoeWatkins yeah, with illogical functions names :D
 
Ha ha ha
Joe
Just help me out here
 
I tried, you seem incapable of listening
 
I just want to fix this petty thing
No. There's somethign wrong with a little bit of PHP I'm writing.
And I need someone to help point it out.
 
@AartiBhardwaj yea sorry I didnt answer earlier.
 
Because It's driving me crazy.
 
8:30 AM
there is something wrong with your whole approach
 
I realise this
 
you are driving me crazy
 
@Caspar and we dont want to, because you will keep coming back and asking really bad questions which you should learn to solve yourself
we really tried getting you back on a path but you as mentioned is only focused on your bug
In such case you can pay someone 5$ on some site for helping you
 
@JoeWatkins I object to xamp. it's really horrible and a can of worms and violates the principle of least suprise and a mac is almost never similar to a prod environment.
 
I am sure someone will appreciate your money as much as you will appreciate them taking time to fix your bugs
 
8:32 AM
@Gordon I object to it less than I object to writing your app in a godaddy web app
/me is afk, school run
 
laters
 
8:55 AM
 
morninis
@adsr Maybe just good ol' var_dump?
 

« first day (2315 days earlier)      last day (2627 days later) »