-
Posts
11,243 -
Joined
-
Last visited
-
Days Won
374
Everything posted by adrian
-
MarkupSEO - The all-in-one SEO solution for ProcessWire.
adrian replied to Nico Knoll's topic in Modules/Plugins
Sounds good - I might actually be tempted to go back to this module - I do prefer the inheritance flexibility of it. -
MarkupSEO - The all-in-one SEO solution for ProcessWire.
adrian replied to Nico Knoll's topic in Modules/Plugins
Thanks @Guy Incognito I have merged your PR. I have switched to using SeoMaestro, but to be honest I am not particularly happy with either of these modules - both have their issues for my way of working / thinking. It will be interesting to see what RockSEO brings to the table. -
Hi @johnstephens - thanks for looking into it further - sorry I didn't respond to your last message - I didn't really see anything I could use to reproduce it. It does sound like you might be onto something with the memory error idea. I am curious what is in your bd() call - are there a lot or heavy objects being dumped? How many results are you looping through? If I try to dump too many items, eg: for($i=0;$i<99999999;$i++) { bd($i); } And I do get an out of memory fatal error and the debug bar fails to load, but I fixed it by increasing the "Reversed memory size" option in Tracy's config settings. Please let me know if that works for you.
-
Hi Robin, It's only a minor thing, but I just noticed this when clicking the show when using InputfieldSelector. Note the position of the calendar icon on top of the page numbers. matches 1716 pages (show)
-
Show more than 100 items of arrays (and other iterables)
adrian replied to Ivan Gretsky's topic in Tracy Debugger
Good catch - thanks for noticing that - I'm not on it this morning apparently :) Well @Ivan Gretsky - at least using $config->paths->data should work for you. I'll still keep an eye on that $maxItems setting and implement when available and see if it handles that other situation. -
Show more than 100 items of arrays (and other iterables)
adrian replied to Ivan Gretsky's topic in Tracy Debugger
Interesting - I am seeing that also with that example, but definitely items are truncated to 100 when dumping $config->paths and if I force Tracy to use 2.7 then it's no longer truncated. I don't know why there is a difference - maybe there is some logic that controls when the $maxItems of 100 is implemented? -
Show more than 100 items of arrays (and other iterables)
adrian replied to Ivan Gretsky's topic in Tracy Debugger
Are you sure it's actually showing all 110? It shows the total count, but the not all items are shown - at least that's what I am seeing. -
Show more than 100 items of arrays (and other iterables)
adrian replied to Ivan Gretsky's topic in Tracy Debugger
It won't fix this issue though because the "big" version of those methods only increases the "maxDepth" and "maxLength" attributes. It doesn't support increasing the "maxItems". In fact maxItems is new to the Tracy core in 2.8 and 2.9. In 2.7 and earlier there was no limit to the number of items so this setting wasn't needed as all items would have been dumped. -
Show more than 100 items of arrays (and other iterables)
adrian replied to Ivan Gretsky's topic in Tracy Debugger
@Ivan Gretsky - if you need this immediately, you can always edit this: https://github.com/adrianbj/TracyDebugger/blob/e6088e92ddb052382382edf290077d929832410f/tracy-2.9.x/src/Tracy/Dumper/Describer.php#L34 -
Show more than 100 items of arrays (and other iterables)
adrian replied to Ivan Gretsky's topic in Tracy Debugger
To clarify @bernhard depth is the number of levels in an array, vs the number of items in the array. -
Show more than 100 items of arrays (and other iterables)
adrian replied to Ivan Gretsky's topic in Tracy Debugger
@Ivan Gretsky - there is already an issue about this on the core Tracy repo: https://github.com/nette/tracy/issues/531 Once this is made available, I'll support it in this module. -
I've added it to the latest version. Thanks for noticing this - I think there might be other things that could have been confusing as it was, so I think this is a good improvement.
-
Turns out with your "get" version, you can also use getFresh() and it will work. Although I actually think this is kind of a bug in the Console panel. What do you think about me replacing line 73 of CodeProcessor.php with: $setVars = '$page = $pages->get('.$page->id.'); $pages->uncacheAll();';
-
Hi @Robin S - not completely sure, but here's a little more insight: This version shows that it is theoretically joining the "summary" field, and if I look at the Selector Queries section of the Debug Mode panel, I see: which shows that it is being joined as expected. Now if I do this same find operation in a template file, I get: Sorry for the rambling, but I am posting as I try new things :) I've noticed that if I run this via the Tracy console it actually does work as expected depending on what page you are on. It seems like it works anywhere on the frontend and anywhere on the backend, except when editing a page (which is what I was doing for my first test above). For example, you can see it working when viewing the page tree. Actually, it even seems to work when editing some page, but not all. What page / view are you on when testing and does that impact what you see?
-
@ryan - I wonder if it would be possible to also get the template name in the returned array? I need this to be able to group results. I also need to the know the parent template name - could it be possible to have a sub array with details about the parent included for each result? The other thing that I am struggling with is sorting the results. Obviously there are PHP ways to do this, but it would be great if PW's sort method was available here as well. To give you a bigger picture, I am trying to convert: $references = $page->references('has_parent!=1051, sort=template'); $references->sort('template, -date, -start_date, -year, -year_rt, -parent.month, title'); to use findRaw() with the new references option. For this sort to work, I actually also need to be able to sort via the "month" field in the parent. I am guessing you'll say that this is beyond the scope of findRaw() which might be fair, but I thought I'd provide a real world use case where this takes the query time from: 1260.47 ms, 14.2 MB down to 297.23 ms, 854.6 KB so it's a huge performance gain if it can be made to work.
-
Thanks for the IN fix. Sorry about the empty results issue - was a mistake in my selector. Everything looks great and this is a really nice feature for generating long lists of documents, blog posts etc associated with a person. Thank you!
-
Sorry, also a bit confused about the results I am getting. Am I doing something wrong? Shouldn't I expect to see key / value pairs for title, and url for each of the results?
-
Thanks @ryan - the "references" for findRaw is awesome. The only catch is that if there are no results, then we get an sql error. Exception: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ')' at line 1 on line: 1311 in /var/www/myseatosky.org/html/wire/core/PagesRaw.php The query it's complaining about is: SELECT pages_id, data FROM field_actions WHERE data IN() Let me know if you have any problem reproducing.
-
That's exactly what I was looking for - thank you. I think in most cases having an actual date time is preferable for most people.
-
Now I am going to be annoying and ask if it would be difficult to set a default format. Maybe by setting the default as the first option entered in the Date Options config setting?
-
Damn I love what you do!
-
@gornycreative - if I understand correctly, this should work. $searchEngine->addHookAfter('Renderer::renderTabLabel', function($event) use($types) { $event->return = $event->return . 's'; }); I was modifying the tabs a little more via a $types associative array, which you can see here. Just for fun I also included the hook I used to add images to the results. In the end I actually stopped using the built in tabs feature because even though it's really awesome, it doesn't work with multiple operators like: *=~= so I built up the tabs manually and now I can even change the operator if the user has wrapped something in double quotes to make it an exact match.
-
I'd love to know your favorite PW alternative - if something else exists with all the features, flexibility and ease of PW which also has full compatibility with version control, that would be perfect. Surely it would require a flat file database, but even that has its problems when it comes to data querying, doesn't it?
- 66 replies
-
- 5
-
-
- developing
- working with pw
-
(and 1 more)
Tagged with:
-
[solved] Request: Add option to define development host
adrian replied to bernhard's topic in Tracy Debugger
Glad that solution works for you. I suppose DDEV is doing something unusual in regards to the normal 127.0.0.1 for localhost that must be messing with the isLocal() detection.