« first day (677 days earlier)      last day (4261 days later) » 

12:00 AM
0
Q: Show x time ago if time is less than 24 hour ago

MotiveKyleI use Codeigniter and it has the timespan() function that returns the time as 1 Year, 10 Months, 2 Weeks, 5 Days, 10 Hours, 16 Minutes. What I'd like to do is only show the time formatted in x hours ago if the time is within the last 24 hours, otherwise just show a normal datetime. I feel like ...

AUGGGGGGGGHHHHHHHHHHHHHHHHHH
 
@Lusitanian MOAR JQUERY!
Codeigniter they say...
 
jquery is the universal answer for every problem
 
@webarto what i want is a javascript framework factory
a factory which builds me javascript frameworks
that way i can build a mootools today, a jquery tomorrow and a dojo yesterday
 
cross framework compatible
 
I want a framework that would do my job for me, so everyday is holiday for me. Can you give me a link? Thank you.
 
12:09 AM
@Jocelyn yes
@Jocelyn it's called querypath
it's jquery for php
 
I want @php.net so I can troll recruiting companies.
sometimes I wish I set on ignore list
 
What's the good word?
 
We'll live to see PHP.net redesigned? (pretending I didn't see Levi coming)
 
Oh, it's been redesigned.
Just not completed
And the new design isn't necessarily a good one.
 
Good night everybody
 
12:21 AM
@LeviMorrison current one is functional I guess
 
i am having trouble in finding the term to google for , i have a htaccess mod_rewrite and when i don't put the last "/" it redirects with the folder name
what is the name of the last "/" in english, trailing slash?
 
One very ugly mysql query: stackoverflow.com/questions/12080409/…
 
0
A: How to convert Unicode chars from \xXX to \xXXXX format in PHP

webartofunction unicode_decode($string) { return preg_replace_callback('#\\\\x([0-9a-f]{2,4})#ism', function($matches) { return mb_convert_encoding(pack("H*", $matches[1]), "UTF-8", "UCS-2BE"); }, $string); } Output: "... \n Proficient knowledge of strongmedical/strong ter...

hunting my second bounty
someone upvoted, thanks, means can haz pass
 
@webarto I like mines betta
 
of course you do :D
 
12:29 AM
@webarto your answer doesn't contain enough jquery, it is probably not valid :-p
 
true dat
 
@webarto don't worry, I gave it more jquery
 
user895378
Has anyone considered the Stack Exchange Machine Learning Contest? I was thinking about running some regressions and seeing what I could come up with.
 
If I were taking the machine learning class this semester I would do it as a class project :)
 
user895378
Often, the toughest part of statistical analysis is getting quality data, and since the SE folks are already providing the data ...
 
12:34 AM
@rdlowrey funny idea, I'll have a look to the website
 
@Lusitanian kind of you to share jQuery
 
user895378
And it deals with a subject near and dear to the hearts of many regulars (detecting which questions will be closed) :)
 
any one knowledged at photoshop in here =/
 
we need @webarto to write a jquery plugin that tells the user who wrote a bad question: "Hey! don't bother clicking the submit button, your question is going to be closed anyway!"
 
@webarto i gave you moar!
 
12:37 AM
@Jocelyn something like, search('jquery') == false = bad question
 
user895378
Even better -- the algorithm posts to the various SO chat rooms right before the user clicks submit to notify them that a bad question is coming down the pipe, so everyone can load their respective close-vote shotguns.
 
user895378
Like a feed :)
 
hahahaha
 
need a dispenser here!
erectin' a dispenser!
at least one person should get that.
 
@rdlowrey I'm studding the NLTK project and started testing some classifiers, when I saw this contest, my first thought was that we'd need to know how to extract meaning and build corporas to suport each subject of a given tag (e.g. PHP). Otherwise, how we'd be precise?
 
12:43 AM
$.ajax({type: 'POST', url: '/posts/id/vote/6', data: {reason: 'no jQuery, it sucks'}});
 
:-D
 
@webarto THERE. Mine has jQuery. stackoverflow.com/a/12083164/610573
You sir, have been bested.
 
@Chris a true sir admits defeat
 
@Chris needs more "$"
 
0
Q: javascript find oldest date?

IceDI need a help in coming up with function in JavaScript. The function should be able to find the oldest date from the list of dates in this format yyyy-mm-dd hh:mm:ss. So the function would receive a text and among the lines it should find the oldest date entry and select text associated with that...

obviously he can't do it with javascript, he needs jquery
 
12:46 AM
$.now is now supported
 
you can't do it in javascript, but you can in jquery. — webarto 7 secs ago
 
user895378
@Keyne I'm not sure how significant tags would really be -- there may be a few outlier tags worthy of a binary dummy variable. Like perhaps questions are far more likely to be closed than questions. I'd honestly be surprised though if there were statistical significance for many tags. I'd expect the data would be more likely to answer that than my speculation, though :)
 
Like the nested-nested-nested ternary?
 
@Chris excellent
 
I dare you to maintain this code, I DARE YOU
 
12:49 AM
can you do it in jquery? — webarto 41 secs ago
trolling 47k user
probably will result in ban :D
 
@webarto quit trollin
 
RAGE haha
 
@rdlowrey You may be right. So the challenge would be select the aspects of closed questions to analyze without taking into account the subject/tag.
 
@webarto answer him
and say "because jquery is the write less, do more js library!!"
 
hahaha
 
12:53 AM
here is a question about jquery for you: stackoverflow.com/questions/12082808/…
 
@webarto If you can't do it in JavaScript, then by definition you can't do it in jQuery either since jQuery is just a big ball of wibbly-wobbly, JavaScripty-wipty... stuff. — Kolink 2 mins ago
 
@webarto what we need here is a jquery plugin for creating invisible iframes
 
@Jocelyn bad questions, worse answer :D
 
Seriously though, it's one of those: "let's throw a large abstraction layer on top of something that doesn't need an abstraction layer!"
JavaScript has very good DOM access...
 
I love javascript
Hate jQuery
 
12:56 AM
I say ol' chap, jQuery became an animation library... only thing useful is $.ajax, and few other things...
 
@Chris I dislike javascript and strongly dislike javascript
@webarto Admittedly if they stopped at $.ajax it would be a nice XMLHttpRequest wrapper
but it's >50 kilobytes -- compressed -- of useless functions
and now they added an effing template engine to it
it's a DOM library...why does it need templating
 
user895378
@Keyne I'd say it's best to start without any tag bias and see what you get. I suspect a lot of people will introduce their own bias towards particular tags.
 
user895378
I haven't looked at the data set but it seems to me that gang-voting by chat users is a significant driver of close vote activity (it is for php, at least). I'd be surprised if post-times that correlate to high-traffic chat times don't result in more closings as well.
 
1
A: How to convert Unicode chars from \xXX to \xXXXX format in PHP

webartofunction unicode_decode($string) { return preg_replace_callback('#\\\\x([0-9a-f]{2,4})#ism', function($matches) { return mb_convert_encoding(pack("H*", $matches[1]), "UTF-8", "UCS-2BE"); }, $string); } Output: "... \n Proficient knowledge of strongmedical/strong ter...

@webarto: Why all this? there's no unicode at all in that input string
 
$("#textbox").enableDecodingMechanism().children('span').each( function() { $(this).children('span').html( $(this).parentsUntil('div').html().grandChildren().decodeUnicode( $(this).grandParents().html() ) ); } );
 
1:00 AM
@netcoder misread the question, I don't know what is the question... I thought he wanted to decoede UTF codepoints...
 
user895378
Granted that's likely not part of the official data set, but you could include qualitative variables based on time of day that were weighted to peak chat traffic
 
well it seems he just wants to decode characters passed as hex, the preg_replace_callback part is enough
 
user895378
Regardless, I think it'd be a fun problem solving activity to try to predict close votes :)
 
Ahh, Drupal. The jQuery-of-PHP-if-CodeIgniter-did-not-exist.
 
the whole "\xXXXX" part in the question is completely irrelevant :)
 
1:03 AM
@rdlowrey Pretty reasonable. It'd be nice to have the chat integration.
 
@Chris drupal is a large turd
 
@netcoder thus irrelevant answer :D thanks for observation, will see...
 
@webarto: Actually, the preg_replace_callback is perfect, it's the rest that's unnecessary
OP should just convert the hex chars to their actual counterpart and json_encode it, and it would be fine (considering json_encode takes care of the rest)
 
@Lusitanian Agreed. Have you ever seen the code, like actually tried to work with it? You've got 12-deep nested associative arrays with "objects" strewn around at random depths that only have a single property that is another 12-deep nested associative array.
 
i've looked at it...it's just awful
and now they're mixing it with symfony2 components
so it's going to become even more inconsistent
 
1:08 AM
I've just read this post: blog.stuartherbert.com/php/2010/07/13/… and decided to ask. How you guys are dealing with DbC in PHP? Are preconditions being enforced by validators and postconditions just documented (i.e. @return)?
 
Drupal is implementing symfony components?!? Drusymfonpal? Sounds like a friggin' sexually transmitted disease. Avoid, considered harmful.
 
1
A: How to convert Unicode chars from \xXX to \xXXXX format in PHP

webarto\x usually represents hexadecimal, while \u is for unicode. Your question has nothing to do with Unicode or unicode codepoints. function weird_answer_to_weird_question($string) { return preg_replace_callback('#\\\\x([0-9a-f]{2})#ism', function($matches) { return chr(hexdec($match...

 
@webarto: Better. You'd probably want to convert \n too, since json_encode also encodes that.
otherwise it would result in \n being double encoded as \\n
 
user895378
@Keyne I bet that two things matter as far as tags: the first tag, which is likely the most applicable because it's the first one the OP thought of, and the number of tags -- I suspect more tags relates to lower-quality questions because they're less targeted and the user is likely just throwing out darts everywhere hoping for help.
 
Slated for release in 2013: jDrusymfonpalIgniteryPress -- No code, less trying
 
user895378
1:14 AM
Not jDrusymfonpalIgnitery-press?
 
And then we delete the internet.
 
user895378
@Keyne Also, I would think that the closer the levenshtein distance of the different tags when mutliple tags are applied, the better the question. For example, if I specify and , it means I'm at least smart enough to know the difference between the two and I have probably done some research into the nuances of the different tags
 
@netcoder added that too in some weird form, thanks for mentioning it
 
@Chris jQuersymfopalignitedcakelaraveldojomoopress
The application stack I use for my web apps is: codeigniter + php 5.1 + fuelphp for my rest api + laravel for my console commands + jquery and mootools alongside prototype with interacts with my asp.net soap api (legacy)
 
user895378
lol
 
1:20 AM
good bye / afternoon / morning / night / see you later !
 
user895378
adios
 
i just hate it when i forget to clear my laravel cache and my fuelphp api breaks how to fix this in order to make next facebook and have great ipo
 
@rdlowrey Yes, it could be one of the classifiers. But, for example, "headers not set", we may assume that questions tagged as PHP would be more likely to be closed. But not necessarily on other questions that for some reason talk about headers.
There are tons of questions that share similar characteristics, I think.
 
-1
Q: Navigating stackoverflow

OptorockI've been in IT for decades and read lots of forums but this is one of the first I have joined and asked a question on and I am finding the basics of replying to answers to my question in an orderly fashion a bit of a challenge. Is it just me or have other people strugled with the user-friendly s...

 
ouch, even though he said he read the FAQ, he probably didn't
 
user895378
1:23 AM
@Keyne True. With 3.47Gb of training data you have a lot of possibilities
 
@netcoder he doesn't have any badges
you get a badge for reading it
 
@Lusitanian: which one? I don't think I have that
 
user895378
The first thing I'd probably do is get some basic aggregate counts for words and tags that appear most (percentage-wise) in closed posts ... just to get an idea of where to start thinking about quality judgements.
 
He probably didn't click all the "Show more" links
 
1:26 AM
@rdlowrey my vote would also go for including a type of
spell check
posts with lots of bad grammar and spelling tend to be closed more often
note that if that wins you $20k i get half <---- legally binding contract
 
@rdlowrey Yes, that definitely would be the first step.
 
user895378
It's helpful to have the raw markdown -- I'd be willing to bet code samples are quadratic -- code is a marker of quality up to a point, but after that it turns into a code-garbage-dump
 
between 6-8 lines of code is optimum imho
 
user895378
if your question is entirely code, it's probably terrible.
 
you'd have to analyze that for sure, though
it's certainly terrible
 
user895378
1:28 AM
There's literally a mountain of data there. I think I'm going to work on this for fun either way.
 
i have legally bound you to pay me half of your prize money if you implement a spell checker. good luck.
 
user895378
:)
 
English is simple, but idiots still manage break it...
 
I disagree, English is far more complicated than most languages IMHO
 
user895378
Everyone makes spelling/grammar mistakes -- it's taking care to fix the mistakes before clicking submit that indicates you were thoughtful in crafting your question.
2
 
1:30 AM
spelling, on the other hand, is pretty easy :P
that's very true
 
user895378
So, yeah, I'd expect that has some significant statistically significant value in determining question quality.
 
0
Q: php how to create dynamic xml sitemap

Hannah Pinki have the following code, but i want the proper sitemap stand. my code $xml = new DomDocument('1.0', 'utf-8'); $xml->formatOutput = true; $products= $xml->createElement('url'); $product = $xml->createElement('url'); $xml->appendChild($products); $products->appendChild($prod...

cv plsk
 
user895378
@Lusitanian Exactly, if you have a 90/10 code-prose split, your Q probably sucks D.
 
yeah that was a great case-in-point
but @rdlowrey the username is "Hannah Pink" and it's a bad[dumb?] question
 
1:32 AM
@rdlowrey Maybe splinting the data by main tags like PHP, Java, Ruby, Scala, and so on would be good option. In English corporas we usually have categories to analyze, like chat conversations, news categories...
 
right into your wheelhouse
 
@Lusitanian I meant words don't change ... in my native language, one word can have 20 variations (grammatically)... it's a mess, like PHP...
 
@webarto ah. our grammar is a mess too though
Latin is incredibly simple, too bad it's dead.
I should write a programming language whose constructs are entirely in Latin.
 
an "esperanto programming language"?
 
user895378
@Keyne Yeah, the more we talk about it the more I suspect individual "major top-level" categories might require their own specialized model
 
user895378
1:35 AM
I'd be interested to see if having the language name in the title indicates better questions? It at least intimates that you are aware that there are other languages besides the one you're asking about?
 
user895378
So many possibilities.
 
if jquery is in subject --> instant close
 
user895378
lol
 
@rdlowrey Yes, hard to predict!
 
user895378
Did I mention stack exchange is going to get away with thievery with this competition? Lots of smart people working for the next six weeks and they're only going to shell out $20k? That's some serious slave labor.
 
user895378
1:38 AM
You can't hire a janitor for $20k, and they're going to get an algorithm that significantly improves their business model :)
 
stackoutsourcing
I worked a year for 20k :D
 
@rdlowrey except it's completely willing, the irony of it all
 
user895378
Sorry, USA pay-scale
 
for a USA company :\
 
@rdlowrey I thought so, but as we have a lot of fanatics, maybe they will be seeking for visibility.
 
user895378
1:41 AM
I think it's a cool project, honestly. It definitely appeals to me. I'm willing to try it and I have precisely zero expectation of getting any $$$ out of it :)
 
@webarto whyd you accept that little?
 
user895378
Plus I should probably try to get some use out of what I studied in school
 
I hate when people copy and paste someone's answer and change one word five minutes after that answer was posted.
see: this user
Nerd-Herd, India
3.5k 2 5 16
 
Sure, it's always interesting to think about the natural language intricacies.
 
user895378
best. name. ever.
 
1:42 AM
admittedly, yes.
unless it's just sheer obliviousness which is perfectly valid :O
 
@Lusitanian it was x2 better than the best local option... 2k a month...
 
I hear salary @ Facebook is like 80k
good night, 4AM here, uptime 21 hrs.. legs no feel, heart can hear... eyes no see... hear is loss..
 
user895378
1:58 AM
later :)
 
@webarto that's it?
do you mean starting salary?I believe they pay mucho more
@rdlowrey if i un-downvoted every answer i have ever downvoted i would gain 66 rep points!
 
user895378
I need to go on a question voting spree -- 200 more votes on questions and it's a gold badge for me.
 
lol
how many total
 
user895378
600
 
notice how everything is made into an rpg...
 
user895378
2:06 AM
600 on questions, and at least 25% of total votes
 
user895378
Yeah, it's annoyingly addictive.
 
i'm coming up on the fanatic badge
there's not a chance i'll forget to visit the site :P
61 in a row, needsz 39 moar
 
user895378
My little sister was getting married in Ireland the week I was scheduled to get consecutive days 96-103. I may or may not have written a cURL script to log myself in and do some stuff just in case I couldn't get internet on my phone one day when I was there :)
 
LOL
i'd do the same...
 
user895378
I was not going to wait another 100 days
 
2:10 AM
understandable
 
user895378
All right, I'm going to be a rebel and not start unit-testing the (essentially) complete HTTP client and go start re-reading A Dance With Dragons by George R.R. Martin. Man, I sure sound cool.
 
user895378
I'm also not going to push the new hotness until tomorrow, because I can only push major changes to anything on Thursdays. It's a rule.
 
that is a rule...
1
Q: Is it better to move values computation to PHP layer out of SQL?

Roman NewazaThis method is to select number of actions between User and TargetUser, e.g. just between two users. The result values of this method are dependent of GetTotalOfPossibleActions() return value which is dynamic (every user has its own number). Question: Is it better to move values computation to P...

good ol' service locators
 
 
2 hours later…
3:58 AM
jesus h christ
its rediculously convoluted to install RoR on os x 10.8
 
Has anyone here ever had someone thank them by saying 'Thank you very muck'?
 
 
3 hours later…
7:21 AM
morning
 
hello
 
Hmm I'm trying to think of something to develop. I don't want to reinvent the wheel. I thought about creating a blog of humorous pictures posted daily but that has been done so many times its hard to count.
 
@W3Geek Create a web crawler that will not leave a domain.
 
7:57 AM
dudes hi
 
yawn another dull day at the office..
the room is quiet too..
 
Yo
 
Anybody here?
 
@Waleed See the avatars in the top right of this page? Those are people who are here.
 
morning
 
@tereško Good morning!
 
please , don't sound so cheerful ... it hurts
 
@tereško Almost weekend. Only today have to do some real work and tomorrow I can cleanup my desk and troll my way through the last day of the current job. :)
 
oh ... good for you
 
3
Q: Cacti graph not showing

Daniels PitkevičsI have created php script for cacti which outputs data in format like: <variable>:<value> Output of my script: temperature:20 humidity:15 Then I created data input method where input string is: php <path_cacti>/scripts/getTempHumData.php <host> Script is placed in cacti fo...

Maybe someone?
 
hello can i ask about mod_rewrite im not sure if it belongs to this section but ill ask anyway.
 
how can i combine two rewrite rules in an .htaccess? i have two rules RewriteRule ^([^\.]+)$ $1.php and RewriteRule ^dictionary/([a-zA-Z])$ dictionary.php?letter=$1 and only the first rule works if put them together into .htaccess.. please help me..
 
@LeviMorrison What would be the point of that? =P
 
8:48 AM
@PeeHaa That's why I waited until now to give the bounty :)
@anoldgangstah What happens if you place the more specific second rule above the less specific first rule? And have you see the explanation on the httpd manual how rewrite rules are processed? They even draw a very nice picture (actually they already did with version 1.3).
 
@hakra sorry im a beginner i would have thought of that if im familiar... i will read more on the manual.. thanks for the advice!!!
 
@anoldgangstah The difference between beginner and non-beginner is, that the later will look for the manual first and then ask if the manual is not clear. The beginner does it the other way round. Will first ask and when he doesn't understand the answer will consult the manual then :)
3
 
@hakra Worked out great! Thanks :)
 
@PeeHaa Another ~1.5k and you have reached the 20k level :)
 
8:57 AM
@hakra two weeks of repwhoring and I'll be there
:)
 
@PeeHaa Two? Do it in one week :)
 
he will have free time till septermber .. or so i have heard
 
:-)
 
9:05 AM
hello
Cleaning is in progress, I see
 
Bonjour Jocelyn :)
 
:)
 
the morning garbage duty .. we like to think of it as a community service
 
9:24 AM
if you are shown some valid MySQL code containing PHP variables (and nothing else), can you say for sure that SQL injection may be used somewhere?
 
hello, my first time here
 
hello Norman :)
 
hmmmmm
 
hi Jocelyn
 
@Norman Hello!
 
9:26 AM
hi
 
@Jocelyn it depends .. what's the code you are talking about ?
 
0
Q: Codeigniter query not working

SupremekhaozI have tried to fix the query but it still doesn't work This is the error: Error Number: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'INSERT INTO user_notifications (id,usr_id,notification_me...

 
no , you cannot be 100% sure that it will be vulnerable to SQL injection , but it is the safe bet
 
I got downvoted because of that, even though my reply addresses all syntax errors in the MySQL code
yesterday, on another question, I commented that the MySQL code may be vulnerable to SQL injections, and another user replied to me "How can you possibly know?"
Some users seem to be traumatized by SQL injections, maybe they already "experienced" them
 
9:32 AM
morning
 
@tereško: Sorry, your search returned no result :-p
 
@NikiC morning
 
@Jocelyn , it don't get it. What exactly are you bitching about here ? Is it that you were downvoted for quite poor answer ? Or is it that people care about security ?
 
caring about security is very good, but I disagree with the downvoting since it is impossible to know if the PHP variables where properly escaped before use in the MySQL queries
 
why do people from India always put learn in their profile...
 
Today I learned something which I think might come in handy to others:
> Please note that the mysql slow query log will not show the SQL of your slow queries if your application uses prepared statements.
 
@Christian you didn't know that :P ? @Jocelyn I'm fine, thank you :P
 
@webarto Nope. I rarely watch those logs either. Yes, my sql is that good. XD
 
10:05 AM
I only use BobbyTables queries ;-)
On the serious side, someday I will give a try to prepared statements...
 
@Christian I look at the execution time, so I conclude which one is slow, etc. But like you say, you'll know which one is slow if you wrote it :)
@Jocelyn you are not using prepared statements :O ?
 
@Jocelyn Don't know how to put it nicely, but isn't your nick a girl's name?
 
@webarto: not yet, I read about it on Stackoveflow
 
Hmm, looks like I'm wrong: en.wikipedia.org/wiki/Jocelyn
 
@Christian: in my country Jocelyn is a male-only firstname, while JocelynE is a female-only firstname
 
10:09 AM
Oh, ok. What country is this?
 
and lots of people make the same mistake (including people in my country!)
France
 
Ah, Francais!
 
;-)
 
You get to learn a few words after three years supposedly learning French at high school ;)
 
When I fill in a form for some administration, and write I am a man and my firstname is "Jocelyn", they often answer to me "Dear Miss JocelynE" :-(
 
10:11 AM
Usually, I can pick up a few spoken words, but my accent's terrible. Last I tried talking to a French waiter, I could have sworn he started pulling at his hair in horror. :D
 
:-D
 
user1125394
Hi sorry to annoy, can I ask you why these 2 regex differ: '/[ +,-:]/' and '/[: +,-]/'
 
If you don't mind me asking, how's it spelled? Does it sound like the female one but with a lesser tone on the final e?
 
user1125394
the two dot
 
@Christian: I can't speak your language at all
 
10:13 AM
@cyril Other than the priority, they're pretty much the same.
 
user1125394
$p = preg_split('/[ +,-:]/', "Projet: IRIS S.A., AUS", NULL, PREG_SPLIT_NO_EMPTY);
print_r(array_unique($p)); // [0] => Projet [1] => IRIS [2] => S [3] => A[4] => AUS
$p = preg_split('/[: +,-]/', "Projet: IRIS S.A., AUS", NULL, PREG_SPLIT_NO_EMPTY);
print_r(array_unique($p));// [0] => Projet [1] => IRIS [2] => S.A.[3] => AUS
 
user1125394
no ^
 
@Jocelyn No, I was asking how it sounds in French.
 
user1125394
S.A. is splitted in the second case
 
user1125394
I'm using PHP 5.3.2
 
user1125394
10:16 AM
this is kind of glitchy no?
 
@Christian: Click the "Play" button in the bottom-right corner (on the left side of the screen) translate.google.fr/#auto/en/Jocelyn translate.google.fr/#auto/en/Jocelyne
 
@cyril It is indeed strange, but I'm no regex expert, sorry.
@Jocelyn Shame I didn't keep up learning French. I love France, especially the part near Switzerland (stayed there for a while during a tour at CERN).
It was simply great, quiet but friendly people, hard working, accurate at their jobs...
Also the environment - nice countryside, not too much sun, etc
 
user1125394
so preg_split('/[ ,+:-]/', is different than preg_split('/[ ,+-:]/' I will try in javascript to make sure
 
@Christian: People often say French language is difficult to learn. Especially the use of verbs, because there are lots of exceptions and special rules. I went once to this part of the country, during a trip to Switzerland, there are nice places there :)
 
I think it's a country worth fighting for...unlike the one I currently live in.
 
10:23 AM
hey , can you help me with pastebin.com/4fQU9Jih ?
 
@MichałKról Do you even need regex for that?
 
@MichałKról Are you trying to get youtube ids?
 
user1125394
ok the same "S.A.".split(/[ ,+:-]/) // ["S.A."] and "S.A.".split(/[ ,+-:]/) // ["S", "A", ""]
 
$vid = 'b6UxXXVf6G0&amp;feature=g-feat';
$vid = explode('&amp;', $vid);
$vid = $vid[0];
 
@Christian thx
 
user1125394
10:25 AM
beauty of regex
 
@MichałKról Also, if you had the full URL, you can just do:

parse_str(parse_url(html_entity_decode('http://ffdgdfgdfg/?vid=gfsdgsdfgs&dgfgs'), PHP_URL_QUERY), $vars);
echo $vars['vid'];
 
sweet :D
 
The html_entity_decode() is because you had &amp; in place of &
 
It works by the way: codepad.viper-7.com/By1lX6
 
10:29 AM
pretty useful
and much simpler then reg expr
 
10:46 AM
 
lol
 

« first day (677 days earlier)      last day (4261 days later) »