« first day (201 days earlier)      last day (4732 days later) » 

1:47 PM
@Brady: Are my comments clear enough? It's not always easy to explain there :-)
 
one mo Jan ive got 5 things going on at once. Ill get back to you :)
 
2:04 PM
@JanFabry do you have any examples anywhere of applying filter to the WHERE part of the query
 
@Brady It uses the posts_where filter, I'll try to find some answers I wrote that use it
A very simple one that adds a clause:
1
A: Query on custom field count?

Jan FabryThe following code allows you to add the parameters wpse4528_key and wpse4528_minimum to your queries, and will then add an extra criterium to the where clause that counts the number of meta values with your key. add_filter( 'posts_where', 'wpse4528_posts_where', 10, 2 ); function wpse4528_posts...

 
ok I think I've got enough to go on now. I'll try out a few things and get back if i need more help. thanks Jan
 
Mike Schinkel once added a nice example that subclassed WP_Query to add his own functionality
very clever and clean
1
A: Custom Taxonomy WP_Query for All Terms in a Taxonomy?

MikeSchinkelHi @Dave Morris: You are correct, WordPress decides if you don't have a term they'll just ignore your taxonomy. There are three (3) main approaches you could try: Use a complete SQL query with $wpdb->get_results(), Get a list of $post->IDs for all posts in your taxonomy and then pass t...

 
2:38 PM
I have a page. I want to display it's content with template index.php. the_title() works. How to grab the body-content?
 
@user247245 the_content() ? :)
I am not sure what you want exactly, but you shouldn't mess with index.php - it's catch-all template for all things that have no template of their own
if you need page with specific template you should just create one for it
 
thanks, it's a simple portfolio site, no blog, all pages. the !"#* content won't show up. I don't need loop. Have tried with or wo the_post() before calling the_content(), no difference..
ahh, now it works, thanks anyway!
what if i want to load the_content() into a variable, (for simple parsing)?
 
@user247245 get_the_content()
But this misses some filters that only act on the_content(), so you probably want apply_filters( 'the_content', get_the_content() )
 
Whats better to store lat lng values in MySQL? use floats or look at usual MySQL spatial data types?
 
2:53 PM
@Brady You would only be using POINT I guess? Then the overhead of the spatial datatypes might be too much
With all the conversion from and to a textual representation
 
Im just storing lat and lng nothing else.
so float(10,6) seem the best way and correctly indexed?
 
@Brady That is how I would do it yes
 
yeah from what im reading else where im getting same feedback
 
But we also have dba.stackexchange.com if you want to be really sure :-)
 
2:58 PM
is there such thing in mysql to do an insert but if the key exists then do update instead
@Rarst :D
 
that sounded too much for my brain today :)
 
@JanFabry cool I need this for use on save_post so that if the custom post type hasnt got its lat lng in the db it inserts and if it does it updates
now just need to find best way to index this table.
 
that is some crowd in chat... do we have a record? :)
 
6? i know its more than normal but surely uve had more than this in the past
we've*
 
3:08 PM
had we?..
 
i dunno im asking you
 
I don't think I had seen more than three :) on other hand I hadn't been much in the chat from the start
 
anyway I'm going afk. Just because I've got an electrical degree I've been the one designated in the office to change lightbulbs. Need to replace a handful.
 
Ah, the value of a degree!
 
heh... I need to do some more hours of work... yay, Settings API... a lot of Settings API...
 
3:12 PM
I still need to get my head around the Settings API. to me it seems to make such a simple task much longer
correct me if I'm wrong but you have to create a function for every setting on the page and a function for every call back for saving that setting... So if you got 15 settings on a page thats a lot of added code
or am I seeing it wrong...
 
@jan, thanks. Now the menus are messing with me. Two menus, registered in functions.php, with add_action and register_nav_menus. Template holding wp_nav_menu('name'=>'tried both name and title'), they're showing the same menu. Thankful for any input.
 
@user247245: Can you create a question for this?
 
@jan, sure.
 
I'm also gone now, see what we'll eat tonight
(Ah, remembered it: leftovers. Yay!)
 
@Brady function per setting, but only one validation function per page
 
3:49 PM
@Rarst so you can use the same one function for all settings on the page?
 
for validation yes, for form output - function/method per field
 
4:16 PM
@JanFabry stackoverflow.com/questions/5900963/… question is up on stackoverflow
 
4:59 PM
Hey great, we got a "votes cast" indicator in the activity dropdown!
 
whats that?
 
5:14 PM
@Brady Hover over your name at the top of each page, next to your reputation
The dropdown shows recent reputation changes and other activity
I just noticed that it now also shows how many votes you cast today
To encourage people to vote more
Just like there was a recent change where you get more question-only votes
 
oh yes i see it too. wasnt there before :)
 
You can cast 30 votes on questions or answers, and after that, 10 more only on questions
To encourage people to vote on questions, which is something that doesn't happen enough
4
Q: Why are questions not being voted on?

Chris_OI have noticed a trend that questions (even good ones) that have multiple answers are not being voted on. When a new question comes in it's on the front page for less than a day (around 16-20 hours) unless it has votes then it's pretty much forgotten. The problem is much worse on SO where front...

 
5:27 PM
I think I up vote well. I have contributed about 100 upvotes in the short period ive been here. I think thats impressive
Granted I pick and choose only a small handful of questions to look at but out of those I'd say 90% of them I upvote if their question is well presented
 
5:42 PM
@Brady Well, you are in the top 5 of voters for the current quarter, which roughly equals the time you spent here
So that is indeed great!
It took an extra effort for me to start voting on questions, but now I like it too
 
I hate HTML forms...
 
@Rarst True, they don't give the same satisfaction that a paper form gives when you scribble all over it :-)
 
not filling, making...
 
 
3 hours later…
8:24 PM
0
Q: Haunted by one question in mod queue

Rarst(strictly moderator stuff, nothing interesting) Every time I use bottom moderator bar to cycle through pending flags queue sooner or later I get this question. Bottom bar is just empty, no flags that I can see, it's long deleted. Why does it want my attention all the time?

 
heh I just got "you haven't voted on quesitons in a while, questions need votes too!" popup... guess that meta request struck a chord with higher powers
 
 
3 hours later…
11:37 PM
0
Q: JavaScript Error on WordPress Answers

John P BlochI figured this would be the best place to report bugs; please let me know if there's a better place/way. I'm using the latest stable version of Chrome on Mac OSX and I get a JavaScript error on question pages. The error message is the following: Uncaught TypeError: Cannot call method 'initIfSho...

 

« first day (201 days earlier)      last day (4732 days later) »