« first day (1601 days earlier)      last day (3343 days later) » 

10:25 AM
So have you error_log()-ed your way down that callstack to make sure you're reaching the filter auto_update_plugin? If so, inspect the filters global to check that your callback is registered.
 
1
Q: Split up wp_nav_menu with custom walker

SnowballI am trying to create a Menu that shows a maximum of 5 items. If there are more items it should wrap them into another <ul> Element to create a dropdown. 5 Items or less: 6 Items or more I know this kind of functionality could easily be created with a walker that counts the menu items and ...

Ha! Great idea! Anybody seen such a menu before?
 
True. Depending on the Layout this might even be doable without special markup using "quantity queries"
 
still you'd need a fallback for browsers not capable of that
wouldn't be that hard. at least it's just a counter
 
10:40 AM
actually implemented something similiar some weeks ago, but the reason was responsiveness which can not be solved at server side
 
sure, it can't. but you can apply this for all devices: first and second level priority menu items
 
Everything from IE8 up supports this: caniuse.com/#feat=css-sel3
 
not everyone necessarily needs to have "about us" in the menu
@kraftner IE8 ... partial support. and that will so kick you in your face.
we had used the nth-child() selector in blueprint. what a stupid idea. "needs no support" suddenly became "why the heck you IDIOTZ!!1!"
 
You're really still caring about IE8?
 
if I can: yes
 
10:43 AM
I think it just creats bad admin. If you need two menus then create them
 
wat?
 
you rarely want that whatever appears in your main menue will be automatically decided
 
@kraftner that actually helps you writing better code. at least this is how I learned about JS functions that I didn't know about
aaaaand: Polyfills!
 
Well but that was some time ago, right? I mean sure there might be situations. Just saying that it might be an issue easily solvable by CSS, especially if it is a responsive optimization only needed sometimes. Still interested in the walker of course.
 
Would you mind offering that CSS solution?
maybe link to that alistapart article as well?
 
10:44 AM
You mean for the question. Sure. On it. :)
 
:)
 
Not like I've got other stuff to do :)
 
@kraftner sidenote: @toscho linked "you may not need jQuery" some time ago. that's a great resource regarding browsers and javascript. and it helps removing jQuery as dependency
 
open link that sounds interesting. realize you've already bookmarked it. :)
 
hehe
 
10:48 AM
And I always try to go as far as possible without JS. Progressive enhancement all the way. Also because I am a NoScript user and freak out every time I get blank white pages because people use JS for no good reason on e.g. simple blogs.
 
why is a "simple blog" a reason to go w/o JS? a blog is something highly personal and a play ground for new tech (if you find the time for it).
 
No I mean blogs that display the main content with angular or something like that and show absolutely nothing with JS disabled.
 
then we are talking about the same thing
but yeah, you could add a noscript part that just displays the JSONified API endpoint to reach the content. And a note above: "if you really turned off JS, then you know how to fetch that"
 
It is just completely crazy! Use JS were needed, not just anywhere without thinking.
 
It is not! :D
you know, you were the one arguing to drop IE8 support
 
11:04 AM
Okay my stand is this:
1. Keep it simple.
 
1. Learn to code.
 
2. Use progressive enhancement. If something works better with JS do it, but have at least a basic fallback for other people.
 
2. Use Polyfills.
3. Stop trolling. I know, I know. :)
 
JS-based polyfills for issues caused by lack of JS? ;)
 
sure.
 
11:07 AM
Concerning IE8 I wouldn't create a completely unusable menu for IE8, but what I would do is just let them fall back to e.g. displaying the other menu items in a second row below.
 
so you can't copy text with JS to the clipboard and can't bookmark a link with JS
Sometimes I wonder were does the client get their crazy ideas
actually the best part is to send a link in SMS, but I didn't need to do research to know it is impossible
hmmm, actually sending SMS is possible if you want to implement it on your server but it will cost money and will not be sent from the user
 
 
3 hours later…
2:15 PM
@kaiser Done. Feedback appreciated. wordpress.stackexchange.com/a/180258/47733
 
 
4 hours later…
6:34 PM
@kraftner @kaiser the answer using wp_nav_menu_items filter got 4 upvotes but is broken...
 
7:02 PM
@gmazzap looking at WPStarter right now
 
what's that
 
@gmazzap recommended way to let it run is project > composer.json > post install ?
 
@kaiser README is live :)
 
yeah, you just did it at the right second :)
 
:)
 
7:07 PM
nice
interesting read
 
I messed up git tags, damn me... fixing
 
@gmazzap the .gitignore is ... meh. doesn't ignore the wp dir ... :/
 
Yep sure
I'll fix it soon
 
also it doesn't ignore the generated files
and vendor dirs (plugins, themes)
not sure if the .gitignore was a good idea at all
 
vendor is ignored
plugin and themes probably should ignored
ot not...
 
7:11 PM
they should
 
you can always edit it
after is created
 
yeah, but it killed my original .gitignore. maybe it should check before it overwrites
 
Yes. It is meant to run on install, not on already installed projects...
btw, check for existent files can be added
I think is important keep gitignore because of .env
 
Sure. But .gitignore files always depend on the group of contributors anyway.
Maybe just split an existing ignore files on line break and search for .env. If it doesn't exist, append to the .gitignore and append the newly created files as well.
 
And if there is no .gitignore?
 
7:15 PM
create it like you did?
 
Ok, fine
Note that WP Starter works also using create-project, when in target folder there is nothing.
 
what
 
composer create-project wecodemore/wpstarter
in a empty folder
gtg for dinner, back in 1/2 hour
 
back in 1/2 hour. turn around. cry silently. call it a day.
@gmazzap ERROR
Warning: require(foo\bar\baz\wp/wp-blog-header.php): failed to open stream: No such file or directory in /var/www/index.php on line 17
same for my colleague
@gmazzap fixed: ~/wp-config.php > require autoloader was calling an absolute path. Works perfect with __DIR__.'/wp-cont... same for index.php and requireing the blog header file
 
7:46 PM
The votes for scalar type hints look pretty good.
 
@kaiser can't reproduce. Yep, it uses absolute path, but it is solved using realpath and works for me...
 
@gmazzap can reproduce for my colleague on OSX and for me on Win7
 
can you say what the absolute path looks like? In your previous example the require is fine if foo\bar\baz is the proper path
@kaiser
 
8:02 PM
@gmazzap for e.g. on Win7: C:\projects\myProject\wp/... < see directory separator mess
 
Ok, the problem happen when installation is done in a Windows environment, but server is unix
viceversa is fine
confirm? @kaiser
 
confirm: yes. it's a vagrant box (ubuntu LTS, 14)
not only win, but mac as well
 
ok, go fixing
 
thanks :)
 
8:37 PM
fixed, do same tests and push
I hate composer cache
 
9:10 PM
spent 15 minutes to understand why a variable contain a /... to understand the variable does not contain it. Is the template that has it. facepalm
 

« first day (1601 days earlier)      last day (3343 days later) »