-
Posts
4,956 -
Joined
-
Last visited
-
Days Won
100
Everything posted by LostKobrakai
-
As we're now using composer this might become a bit more relevant, but this is really missing out all those systems, where composer isn't being run. There are certainly a lot of servers / hosters out there which are fine with running old version of php for those wordpress and other clicky install cms's. I'd certainly like to see ProcessWire up the requirements in php version, especially as everything below 5.6 is EOL, but Ryan seems to like keeping ProcessWire as compatible, even to shitty hosters, as possible.
-
Everything is in memory already anyways. You could even use $this->page in the included file even if you don't explicitly give it the object as $page. So there's not really overhead.
-
It might be a nice feature for the api-explorer as well. Have your own code's documentation exported to dash ❤️
-
That's probably an error outside the grasp of anyone besides the one running the machine it's happening on. Besides if $pagefile->filename is invalid even though it should.
-
filemtime() will return the time a file was modified. So maybe there's something wrong with the file / filesystem.
-
The valet driver basically replaces what the .htaccess does.
-
First of all, your question is asking to compare apples to bananas. ProcessWire is first and foremost a CMS, but with a great (smallish) framework beneath it, whereas Laravel and the others you named are big feature-rich frameworks. But to answer it anyways: (In it's role as framework) I've never regretted choosing ProcessWire for what it does, but if so rather for what it doesn't. E.g. tests are first class citizens in other frameworks out there and ProcessWire doesn't have that. Also ProcessWire's core is not the kind of framework which does come with all batteries included. If you need more advanced features e.g. like queueing stuff for later processing or handling notifications it's often more manual work, than it might be in your alternatives. On the other hand you'll get great data-modeling tools and the accompanied backend nearly for free. If you rather want to compare ProcessWire to other CMSs the bullet-points would certainly be quite different, as the use-cases are probably quite different.
-
image.count is not a supported showif selector. The images field is not using an html inputfield, which would be countable by js. At least not without deep knowledge of the used markup.
-
Your if condition is missing a ")".
-
foreach($page-children(…) as $key => $post) { if($key == 3){ // Render static content after 3 posts } // Render post as normal }
-
Elixir / Phoenix - A really great functional programming language running on the erlang VM. Damn fast and with great concurrency tools. Phoenix is the corresponding webframework (inspired by rails, but also not really)
-
Multi-instance support does require modules to be wireable to a specific processwire instance. This is most easily done by extending any Wire classes. While it was possible in 2.x to just implement the Module interface it was never the suggested way to do that. For 3.0 you can always create a module, which extends a wire class and just forward all method calls to your Bar class.
-
Without url rewriting only processwire's homepage will work and maybe – if you really want go that way – the internal GET entry point like: www.domain.com/?it=/my/path/ See the requirements: http://processwire.com/about/requirements/
-
You need to keep in mind, that you're in charge of any logic regarding the total of pages if you overwrite it, so you need to handle cases, where the total is less than 100 as well. // The customer wants to set the items per page. Lets say it's 10 for the moment $limit = $page->number; // Remember: There are only 12 Event Pages at the moment $items = $pages->find("some=selector, limit=$limit"); $items->setTotal(min($items->getTotal(), 100)); // Output Markup $paginationMarkup = $items->renderPager(array( 'nextItemLabel' => '<i class="fa fa-angle-right"></i>', 'previousItemLabel' => '<i class="fa fa-angle-left"></i>', ));
-
Enable debug mode in the config.php and look in the footer of the admin theme. Those debug tools do have a panel "Timers".
-
Could you take a look at the Timers in the core debug-info panels.
-
Get unique parents from children and make them a page array
LostKobrakai replied to cb2004's topic in General Support
PageArray's are automatically unique. $found = $page->find("date_1>=today, sort=date_1, parent.status<" . Page::statusUnpublished); $results = new PageArray(); foreach ($found as $p) $results->add($p->parent()); -
I'm not sure you'll get a good answer to this one if you won't add what you intend to do with those data. It could be from "simple pages are fine" to "do not use processwire to start with, but take a look at graph databases first".
-
Set order of pages in PageTable field via API
LostKobrakai replied to alexcapes's topic in API & Templates
I think page sorting could sport a more intuitive api like insertAfter/insertBefore/insertAt. But it seems currently most of the sorting stuff is hidden away in ProcessPageSort. -
It's essentially those two libraries: league/csv and league/flysystem (with the FTP adapter).
-
Do you need validation of the data as well or only the ftp connection and csv parsing?
-
They are also documented here: https://processwire.com/api/selectors/#or-groups