« first day (991 days earlier)      last day (3957 days later) » 

12:01 AM
@HamZa The problem is with the variable going into the function. I've just put this in as a plain string and it works beautifully.
I need to work out what's up with it..
 
@Dan lol, then good luck
 
urgh
string(221) "A pair of late 19th early 20th c. Royal portrait photographs of the future George V and Edward VIII. Prince Edward was born at Richmond on the 23rd June 1894. Mounted in their original vellum and gilt embossed frames."
What's wrong with that? It's just a string.
 
@Dan That's why I asked to split by dot, maybe you have some other special characters ...
 
I get this

Array ( [0] => A pair of late 19th early 20th c [1] => Royal portrait photographs of the future George V and Edward VIII [2] => Prince Edward was born at Richmond on the 23rd June 1894 [3] => Mounted in their original vellum and gilt embossed frames [4] => )
 
12:06 AM
@Dan Now try with (?<!c)\.
@kaᵠ That's maybe better :p
 
This;

Array ( [0] => A pair of late 19th early 20th c. Royal portrait photographs of the future George V and Edward VIII [1] => Prince Edward was born at Richmond on the 23rd June 1894 [2] => Mounted in their original vellum and gilt embossed frames [3] => )
 
So far so good ...
Try with
(?<!c)[.!?] I think this will work too
Note @kaᵠ 's solution might interest you ...
 
I tried ka's, I got this again

Array ( [0] => A pair of late 19th early 20th c. Royal portrait photographs of the future George V and Edward VIII. Prince Edward was born at Richmond on the 23rd June 1894. Mounted in their original vellum and gilt embossed frames [1] => )
 
I think it's the lookahead then ...
Do you have an hex editor ?
Try to see the hex code of your space
 
And here's your one:

Array ( [0] => A pair of late 19th early 20th c. Royal portrait photographs of the future George V and Edward VIII [1] => Prince Edward was born at Richmond on the 23rd June 1894 [2] => Mounted in their original vellum and gilt embossed frames [3] => )
Sorry, I don't understand.
 
12:13 AM
@Dan What editor are you using now ?
 
Dreamweaver - does it make any difference?
 
@Dan no -- only the fact that I hate it and almost every user in this chatroom lol
 
Yes, I know.
Not sure why - is there a real reason..?
 
that's ok ...
Do you know what I mean by "hex code" ?
 
I don't "use" it at all, I just write like I would in notepad or whatever, only difference I can see if the colour highlighting haha
No^
#e3e3e3? :P
 
12:16 AM
Mar 12 at 16:16, by tereško
Dreamweaver is the IE of IDE's , it is popular only among people who do not know better
@Dan Ok, not sure how to tell you this then ...
 
Well, as someone who mainly writes CSS, I understand the significance if what you said. If DW is like IE, then I should change to something else.
 
Try with (?<!c)[.!?](?=\s|$) and tell me what's the results. ..
 
Same, everything is in the first array value.
And a black second value.
blank*
 
ok, this confirms what I though...
 
Me too, I know fuck all about regular expressions.
 
12:22 AM
I think you don't have a space there. At least not a normal one
 
@HamZa I just checked the admin area of the site,
user had entered double spaces, I've made these single spaces and now it works.
Why though..? I thought one OR MORE spaces would match in my original code.
See: /(?<!c)[.?!](?=\s*[a-z]|$)/i
/s* - this means one or more doesn't it? Or is it zero or more, I can't remember..
 
It should match... That's why you should check what's the hex value of that space
If it's not 20, then it's not a *normal* space
@Dan zero or more times
 
Yeah, ok.
So what other kind of space is there?
I know about the 20 thing..nothing else.
 
I really don't like to tell people not to use their IDE of choice but I really should say something...Dreamweaver carries a connotation with it. Real or not, fair or not it does.
When you tell people you use Dreamweaver a stereotype tends to happen. That's not fair to you but there's no denying it. If the only reason you're using it is syntax highlighting please check out other IDEs
 
Want to know why I use it?
 
12:27 AM
I'm searching but can't find something useful ...
note that \s matches tabs, newlines (\r and/or \n) and much more
 
@Dan If it is just syntax highlighting that is not a legitimate excuse. If that is the reason you really can find something better.
 
@Dan Your work impose it ?
 
It came with Adobe suite, which came with PhotoShop - end of story.
 
I'm just letting you know that Dreamweaver has a connotation about it. That's all I'm saying
 
12:28 AM
I'm cool with that, don't worry.
I was thinking about trying Sublime.
 
@sectus how did I not think about checking wiki ...
 
I think it's just as bad when people say "yeah, I wrote this whole site in notepad".
 
@Dan Really I don't get into IDE type religious wars. You can use whatever you're most productive with and as long as you produce clean, maintainable code go for it. :)
I just know that a lot of people I know and have talked to think of a point-and-click WYSIWYG type "developer" when they hear Dreamweaver.
 
Someone who actually uses design view? haha
 
@Dan You laugh but I was talking to somebody in this chat room that was being taught at school how to develop websites exclusively with Dreamweaver point-and-click
Let that sink in for a moment
 
12:31 AM
CSS selectors are pink, PHP tags are red, and comments are yellow. Job done.
 
@cspray hahaha yeah I remember that ...
 
No matter what I've ever said people have a go in here though,
 
@Dan How long have you been programming? Just curious as to what kind of experience you have.
@HamZa Stuff like that really does scare the ever loving shit out of me...
 
I mentioned that I use Chrome developer tools inspect element once, and some guy was like "why???"
I was like "it saves time....?"
 
@Dan Notepad++ OR Geany.org OR SublimeText
 
12:32 AM
@cspray I mainly design and write html+css - I like responsive stuff.
I'll scare you some more, I use WordPress.
Shall I leave now? : )
 
Eh, I don't care about any of that
I don't particularly care for using WordPress
But to deny there aren't legitimate use cases for the software is just silly
 
As far as PHP goes, I usually know enough to get around loops and queries.
 
@Dan lol no no. This is a chat to share ideas. I actually learned a lot here
 
If a rock comes in a pack of nails as a bonus are you gonna stop using your hammer?
 
I've started learning more about JS - that's what I really want to know, for front end development.
 
12:33 AM
Ok. That's fair enough. Then, yes, I probably wouldn't worry too much about IDE until you get more serious with the programming side.
 
No, I like hammers ^
 
:)
 
I've been writing some small plugins for a while now, but my PHP progress is slow.
 
hit it
 
I can't quite figure out the point of using a class.
That and regex are probably the two things I keep coming back to, feeling like I don't know enough basic stuff.
 
12:36 AM
@Dan I wouldn't worry about that until you're deeper into the programming side
I don't believe that beginners should start out worrying about OOP
That's for later imo
 
@Dan regex is quite easy. Some basic tutorials and some practice you'll get it
 
Fancy testing me on some easy stuff?
 
@Dan Not particularly. I'll talk to you about what you're facing and what I think but I don't really like quizzing people :P There's sites for that kind of stuff!
If I really wanna know how a person codes I don't ask them quiz questions; I look at existing bodies of work
 
Very logical thing to do.
 
The only thing you really get out of quiz questions is: (1) they understand the very basics or (2) they've been to a lot of interviews
You can change your definition of "very basics" to fit the level of the position and domain
 
12:39 AM
2 days ago, by HamZa
lol, first file opened aaaaand:
<?php if(@$_GET["page"]==!0){ echo ", page ".@$_GET["page"].".";}?>
^ did you check this lol ?
 
@HamZa No. What is this monstrosity?
 
@cspray hahaha
I've never seen @ before $_GET
 
@cspray hahaha, a piece of code in my first website I coded ~3 years ago !
 
@Dan Do you know why it is there? :P
@HamZa Eh, I would rather look at more recent projects. Surely your code now is better, yes?
 
Nope, I wouldn't write it, haven't needed to yet.
 
12:41 AM
@Dan They are suppressing the error when the "page" key isn't in $_GET
 
@cspray better but I'm looking forward to learn OOP. Just bought a book waiting for delivery
 
By they I totally mean @HamZa
@HamZa Well, that's the point
I was recently asked what my biggest accomplishment and biggest disaster was in programming
Both answers were my same project
The first professional "app" I ever worked on
I automated a 40 hour a week task to a button click every day
But that code? That code was absolutely awful
 
@cspray that's awesome
 
Mine's probably my many infinite loops...
 
It solved a really important problem and was really a drastic improvement over previous process but that code was awful. Today I wouldn't even dream of doing what I did then
Nobody starts off just good at it. I wouldn't expect that from anybody. :P
@HamZa It was kind of awesome and also a little ridiculous that the particular company was allowing the particular task to happen in the first place :P
Let's just say that both solutions, the manual and automated one, weren't exactly efficient with their use of resources
 
12:45 AM
I think my biggest disaster was the following:
There was the development website and the live website.
Now, I had to place the development website on the live environment
I have made a backup of the live website.
But then I deleted everything. After a short while, I noticed that I was on the development environment and that I deleted it lol
 
@HamZa Ouch. Yea, I've had a couple situations like this
 
Basically everything we made was destroyed in a couple minutes xD
 
One night I was working really late...typed into CLI
sudo rm -rf /
I even typed in my password and hit enter
 
@cspray hahahaha I can't believe that happened
 
Boom. Bricked computer.
 
12:46 AM
you were drunk ?
 
All for a missing asterisk
 
I'm feeling much better about myself.
 
No, I was unemployed and in school. I was up way past the time I should have stopped working on the computer
At least in the CLI on the computer :P
 
haha I see...
Well from that time I made that mistake. I always do backups, and check several times if I'm on the right domain
 
@HamZa hehe :P
 
12:49 AM
@Dan yeah, when looking back at what I did. I really laugh at myself. Specially the code !
@Telkitty猫咪咪 awesome cat you have there
 
hi quick question pls , why this wont be selected ?
<option value="Afghanistan" <?php if(isset($_SESSION['slist']) ){ echo 'selected = "selected"' ;}?> >Afghanistan</option>
 
@HamZa thank you :p
 
@echo_Me What does var_dump(isset($_SESSION['slist'])); give ?
 
it gives this bool(true)
i have many select option but it only select the last one Zimbabwi even if i dont select it
all countries
 
Do you have that little bit of code on all options?
 
1:00 AM
yes :)
 
Well, there ya go
 
@cspray lol, right on the spot
 
You can't expect to have multiple selected attributes set and it to work right
 
same thought
@echo_Me try something along the lines: if(isset($_SESSION['slist']) && ($_SESSION['slist']=='Afganistan')
 
no , i get zimabwi also
 
1:04 AM
@echo_Me can you post your code in a pastebin ?
 
great
 
zimbabwi is the last option
 
@HamZa you sure you wanna see that :P
 
@kaᵠ no but can't be helped :)
 
Did you alter the code any at all? Because if you're really just putting selected="selected" on all your attributes
You should expect to always see the last option
Remove Zimbabwe. Whatever the last country is now, that's the one that will be selected
 
1:07 AM
@cspray if i remove zimabwi it will be zambia :)
 
@echo_Me do you by any chance set _SESSION['slist'] to the country's name somewhere?
 
@echo_Me It should also tell you what is wrong
 
@kaᵠ didnt understand , what you mean
 
Why not ask why? Why? — ircmaxell 9 secs ago
 
@kaᵠ you mean i will use this somewhere set _SESSION['slist']
 
1:12 AM
@echo_Me yes, and set it to the country's name, so you can use it it your checks there
 
I can cast...
 
@kaᵠ im using just this in php if (isset($_POST['slist'])){$_SESSION['slist'] = $_POST['slist'];} else {$_SESSION['slist'] = ''; }
 
I believe i can cast, i believe i can close a post.
 
i believe in you @sectus :) congrats
 
'0' -- will not match. Are any int number. — sectus 3 mins ago
@sectus ^ ????
 
1:17 AM
In the context of databases (data modelling as a whole I suppose) in a one-to-many relationship, are there common names for each table in the relationship? Such that, you have the dependent and the dependee?
 
@HamZa , it's depends on input variable type and wanted format of it.
 
I suppose parent and child work; just wondering if there's a more idiomatic name.
 
@HamZa some countries use comma for floating points
 
oh... there is a string...
nvm
 
anyway, dots ftw
 
1:20 AM
@kaᵠ yeah I know
 
if i echo session['afghanistan'] i get it 'Afghanistan' but why it wont be selected ?
 
1:35 AM
@echo_Me Whatcha trying to do? I just came in here. please elaborate
Hi everyone ! has anybody tried to $autoload sparks using CI-Bonfire successfully?
 
hi
@Kyle you told me fixed it
 
@KrishanaSingh yeah, I just called it on MY_Controller. I was aiming to use $autoload
 
@echo_Me Are you seriously manually writing every country ?
 
@kyle k
@Kyle now what you want?
explan it
 
1:51 AM
@KrishanaSingh ah, I was just asking whether anyone has loaded a spark via $autoload['sparks'] successfully.
 
@kyle installed spark right?
if yes then try my sent code
 
3:04 AM
@igorw yes, it should be possible however, it was asked about views which are not (generally) isolated from the framework. At least the framwork choice in this case puts hinderance for testing. This is normally a long-time slow-downer and I suggest to replace it.
 
@KrishanaSingh : ok.
 
user652649
morning
 
Does anyone still use Smarty?
I never understood the benefits of Smarty
 
user652649
@marabutt me neither
 
@marabutt yes it's still in use. the benefits is in introducing a new layer.
 
3:34 AM
more layers more fun, right?
 
"more layers more cake" --> more cake more fat...
couldn't have said it better than that ^
 
user652649
insta-star
 
user652649
afk
 
yea... too bad it's out of context :P
there, fixed it
 
3:40 AM
i am not an expert but reading through the smarty docs doesnt seem to remove much complexity.
*smarty doesnt seem to remove much complexity
 
@marabutt no, it most certainly adds complexity.
it's quite dated. if you're looking for a more modern templating system in PHP, take a look at Twig.
 
@marabutt you know.. you can edit your recent messages
 
what these kind of templating langauges do is that they compile the template into PHP code again.
 
@hakre Just out of curiosity, do you use Twig in your own projects?
 
@cspray I have used, yes (not my own project).
 
3:49 AM
@hakre What benefits do they offer over just native PHP?
 
@cspray the extra layer again. If you just use native PHP then you need to have an iron will to keep things separated.
 
@hakre Ah, ok. Fair enough
 
And then there are some stuff like template inheritance, caching etc.
 
So does Twig offer anything in particular to help separation of concerns? Or is it just more a thought process thing?
 
It's just that twig has been made for common webapps output problems, so you find many good tools in there.
For example taking care of escaping the output.
 
3:51 AM
word of the day: buttbuttinate
 
Sure you can do all yourself, but it's not that bad if things grow to have some dedicated layer for it.
 
Ok, thanks.
 
@kaᵠ awesome
I'm getting sick of hearing bro added to every word
 
@marabutt you mean, just at the end of the sentence with a question mark, bro? :P
 
Goodmorning everybody. and @Mr.Alien I will yes hopes thats ok :)
 
Hi all ! I've successfully uploaded my files to the remove host but when I access them, this error comes up "Unable to connect to your database server using the provided settings." I'm using CI-Bonfire.
 
Have you setup everything correctly ?
 
@Tredged yes, I have configured everything correctly. The error also states that it comes from "/third_party/MX/Loader.php"
 
4:23 AM
@Tredged obviuosly the db configuration does not work out, right?
 
files to the remove host???? lolzzzz
 
1 min ago, by hakre
@Tredged obviuosly the db configuration does not work out, right?
 
@hakre obviously yes that way it isnt a bad thing to ask if hes sure everything is correct, right?
 
remote host*
@YogeshSuthar remote host*, typo. sorry. heheh
 
@Tredged sure, same applies to me, right? :)
 
4:28 AM
Good morning..
 
@KyleEmmanuel Check again your database configuration. If you are sure that it is correct, try with core php to connect with remote host.
 
@KyleEmmanuel it's probably an issue with that third party extension. replace it with a different one and see if it works then.
 
@hakre Always xd :)
 
0
Q: Can some one help me with this .htaccess rewrite rule?

Chandez HardingI have to admin I am a total noob when it comes to .htaccess and rewrite rules but saying that I do have a general understanding of how it works but for the life of me can not figure out how to correctly fix an issue I am having. What I am trying to go is rewrite URL's for my profiles a bit like...

someone help him. hahahaha
 
@Rafee Morning..
 
4:29 AM
ok.
 
@Rafee Hola amigos.
 
How are you?
 
@Rafee me?
 
@Rafee what was it with all the dots few hour earlier ?
 
4:38 AM
Your present circumstances don't determine where you can go; they merely determine where you start.
 
@YogeshSuthar yes..
@kaᵠ I was working on something and slept.. the i dont know.. why it started working with Chrome..
Just got to see now!.. got 3 chat messages ...
I wanted to make browser active state.. so that my laptop doesn't sleep..
not even its screen light..
 
@Rafee I am fine and feeling sleepy. :P
 
My eyes are burning.. Eye infection.
 
morning
 
@Mr.Alien Morning..
 
4:44 AM
Morning ;)
 
@YogeshSuthar Check your inbox
@Rafee hello
 
hi.. so whats up today.
 
well planning to start 3 projects together... so kinda facked up :p
 
@Mr.Alien Checked. :) That lenovo 2GB GC having AMD processor which is less powerful than i5.
Khichadi bana raha he project ki. :P
0
A: Using PHP to group and display MySQL table

Goutam Pal$result=mysql_query("SELECT * from district d inner join region r on d.regID=r.regID GROUP BY r.regID");

 
@YogeshSuthar arey c, ek apna, than I've my 2 personal projects, 1 is quratek company website where I am stucked at content writing and second is my Customized Business System
 
4:47 AM
copy of my answer. :P
kk
 
Anyone have a good song for me :)?
 
@Tredged try Aashiqi 2
 
Jukebox full songs?
@YogeshSuthar
 
@Tredged don't know. :(
 
Listen we own it
 
4:50 AM
2Chainz and Wiz?
I like that song xd FF6 )
 
@Tredged Do you listen to Hindi Songs.
 
Oh yea... thats a speedo song
fires me up everytime I hear it
 
I listen to everything that sounds nice doesnt really matter if I can understand it or not xd @Rafee
Yeaa
 
Cool
 
"Only god can judge me"
 
4:51 AM
Just like me. I can hear Japanese songs too. :P
 
I often listen enrique spanish versions
 
Yea, u dont need to always know the language u listening.
If its nice and u feel the song then its fine xd
 
@YogeshSuthar Wow. Do you know japanese.
 
@YogeshSuthar yest someone down voted this
 
@Mr.Alien LOL u had some time explaining that I see.
 
4:53 AM
@Mr.Alien hahaha, may be that person don't like your profile pic. :P
 
@Rafee did you tune it to 25 minutes?
 
@YogeshSuthar Theres always a dumb reason they would downvote so..
 
I made to 13 to 26 minutes.
random time
 
@Rafee No, I don't know japanese. But I am hearing any language songs. Just like japanese, Chinese,spanish,russian, tamil, etc
 
@YogeshSuthar Who won't like my stud face... @Tredged yes, was free, I just edited that few days back, else if you see my original answer, it was just small
 
4:55 AM
I am learning Japanese.
 
@Mr.Alien Haha, by the way i like the Neonize menu its something different :)
 
@Rafee you are baka. :P
 
whats baka..
 
@Mr.Alien How can I know? :P
@Rafee you don't baka? BAKA means IDIOT in japanese.
 
baka means idiot stupid fool in japanese
Awh :(
 
4:56 AM
@Tredged aaah, that's my babe.. actually I wanted to be an astronaut, didn't became unfortunately... :p
 
@Tredged And he is saying that he is learning japanese. lolzzz
 
wow @Mr.Alien nice long post +1, btw Y U NO HAZ ALIEN HEAD AVATAR?
 
@Mr.Alien found it , he may be @kaᵠ :P
 
@YogeshSuthar I have decided to go with a blue theme for out portal
 
@Mr.Alien Haha thats dissapointing :( @YogeshSuthar Haha I watch naruto to much :)
 
4:58 AM
haha
 
@Mr.Alien there's still time: mars-one.com
 
@Mr.Alien What portal project u making if ur eligble to share?
 
@Mr.Alien Blue theme with funky color.
 
whats that.. @kaᵠ
 
@kaᵠ aah, actually I have changed my avatar so that you humans don't feel inferior :p heehe
 
4:59 AM
html raw data.
 
@YogeshSuthar that didn't make sense
 
haha
 
@Tredged I also watching naruto.
 
@YogeshSuthar What epi you on? kage bunshin no jutsu ;x
 

« first day (991 days earlier)      last day (3957 days later) »