« first day (2448 days earlier)      last day (2485 days later) » 

1:01 PM
@DᴀʀᴛʜVᴀᴅᴇʀ Nevermind, it was reversed automatically :P
I just wonder why there is no SE community solely for web development (HTML, CSS, etc ). SO is the place to ask these questions but it's also filled with millions of questions of other languages.
 
I think it is somewhat hard to define web dev in any narrower way than what SO is. You can also write web stuff in GO, Java, C or probably even Assembler.
 
what about C++... :D
@Brady Hello sir!
Also noticed that WPSE boyz have finally decided to do some changes on the site. They changed the color for badges in user profile! Cheers!
 
 
4 hours later…
5:39 PM
I wish when updates are pushed to Stack Overflow they could be pushed to all the subsites too :/
 
 
1 hour later…
6:41 PM
@Howdy_McGee Right now i'm visiting my profile every 2 minutes and clicking my badges, since the new styles are actually so amazing, u know.
I also have a simple question. I've read like infinite number of guides about filter and still don't know how to do this. I'm declaring a function and i want the customers to be able to modify its input in their child themes
so i did like apply_filters('sample','example'); function example($data){}
but i can't use add_filter('sample', ... ); in the child theme.
anyone can guide me please? how to apply the filter in the child-theme not directly when calling the function in template files?
 
not clear what you want to filter? $data?
 
yes exactly
BEFORE passing to function
 
$data = apply_filters('sample', $data);
example( $data );
 
so i should write this exactly 1 line before defining the function?
 
however you want?..
 
6:56 PM
$data = apply_filters( 'modify_data', $data );
If you're passing $data to the function, and want to filter what is passed, put the filter inside the function call
 
it depends on use case and stuff really. it can easily make more sense outside if data is very contextual. kinda pointless to discuss in too general case.
 
I owe you guys for one! These guides explained everything but this.
just had to do example ($data){$data = apply_filters('sample',$data); }
 
7:58 PM
Is it possible to add a query var to every URL (homepage, archive, post, etc) without using .htaccess?
can't quite understand if add_query_arg can do this.
 
@JackJohansson Not sure, this WPSE Answer maybe
 
literally i want every URL of my website to be like example.com/bla/bla?foo=bar
So i have to use rewrite rules, right?
 
Probably
 
appreciated. Was hoping to do it without rewrite.
However the answer is about retrieving them, not adding them to the URLs.
 
8:13 PM
if you want it at every URL why do you want it at all?
 
I'm making a demo page for my theme. I want the user to be able to change the elements in the front, by adding a query var to the URL (after clicking the button). i will remove it in the public release
 
I assume post_link is being applied to every post type, based on the example.
 
hmmm even archive and homepage?
tried it, unfortunately it only works for permalinks
isn't there a hook like site_link?
got it got it
function append_query_string( $url ) {
	$url = add_query_arg( 'foo', 'bar', $url );
	return $url;
}
add_filter( 'site_url', 'append_query_string', 10, 3 );
 
8:30 PM
Neat! How'd you format that code? Man, I've been here for awhile now and still can't get code to format properly in this chat :(
 
You need to paste the code in the textearea and click on the fixedfont :)
i think SE can detect the codes, so if you add normal text then the button won't appear
 
I've never even known that button existed... #theMoreYouKnow
 
+1. Didn't know either until i pasted a block of code into the chat
 
 
3 hours later…
11:15 PM
I just noticed that the scholar badge ( Ask a question and accept an answer ) has been awarded only 14k time. This means that the remaining 64k questions don't have an accepted answer?! and the rest of 88k users have never accepted an answer???
 

« first day (2448 days earlier)      last day (2485 days later) »