Jump to content

diogo

Moderators
  • Posts

    4,314
  • Joined

  • Last visited

  • Days Won

    80

Everything posted by diogo

  1. The sidebar is incredibly useful! Just tested it and it's really slick to edit a bunch of pages in a row
  2. If there's nothing in curated, then $curated would be an empty page array, which is perfectly fine because it would just get filled with the 4 regular inspirations. The only doubt that I have is if the import will keep the order of the pages.
  3. I would probably do it like this (not tested): $curated = $page->global_inspiration_related; $nr_of_inspirations = 4 - count($curated); $inspirations = $pages->find("parent=/inspiration/, id!={$page}|{$curated}, sort=-global_published_date, limit={$nr_of_inspirations}"); $all = $curated->import($inspirations);
  4. @dweeda here is all the info you need https://processwire.com/api/include/ @abdus the info above is the official way to do this.
  5. To go a bit deeper in what Robin explained. When you are on the last page of a level, you want the first page of the next sibling of it's parent. For this to work, you have to be actually positioned on the child page, and not the parent — you can do that by redirecting to the first child when positioned on one of the parent pages. As for the next and prev links something like this should work to get the correct pages; $prev = $page->prev->id ? $page->prev : $page->parent->prev->child; $next = $page->next->id ? $page->next : $page->parent->next->child("sort=-sort");
  6. Be sure that we are all aware of that here, it's just that newcomers don't and may take it the wrong way. I'm certain that @theoretic will appreciate your kind apology
  7. @ottogal Independently of the opportunity of this suggestion, It doesn't sound at all like @theoretic is joking, you can see that there is some thought and work in that logo either you like it or not. There's too much trolling going around the world these days, let's try to keep this little corner of ours a nice and constructive place. I'm not trying to bash you down, but please try to be a bit more explicit about what you didn't like when criticizing someone else's post. @theoretic you might want to go through this thread to get a feeling of what was already discussed about this subject
  8. You can put three links inside a div and make them squares with css.
  9. Funny, today I went to something very similar with another avatar from this forum
  10. That doesn't sound right. A page field returns a normal page array, just like a $pages->find() call, and how many pages can you possibly have selected in a page field? Are you sure this is not caused by something external to PW (e.g. server config, some external library...)?
  11. "Vanilla ProcessWire", love it!
  12. The alerts work great, every time I edit some files I get an email. Until now I've never had false positives. I don't get any alerts for database changes, and I'm not sure you can do that. Their site is in maintenance right now, so I can't check that out. The alerts are available on the free version.
  13. I have to say I find Codeguard quite amazing. Independently of which method you will chose to backup locally, it won't hurt to have an extra backup in the cloud, and Codegard does backups for one website, with one database, until 1GB, for free. ps: I mentioned it on another thread already
  14. Better yet, show us your HTML and I'll tell you how to do it.
  15. It's possible to do :nth-child(n+6) on any kind of element, it's not the element that matters but the context it is in, particularly it's siblings. If you have a bunch of <picture> elements standing next to each other, then picture:nth-child(n+6) would certainly work.
  16. I agree with Adrian, there's no point on doing this with PHP when you can do it easily with CSS. Besides, if someone loads the site on a small window, and then resizes the window, you'll have less content on a larger screen. Is your reason purely layout related, or are you trying to spare mobile users from loading content? That can also be fixed with JS, and some browsers won't even load images that are not displayed. In your code you're trying to load a PHP file with javascript. for what I see, either you have those files on the root of the site without PW code, or it won't work at all. Anyway, I strongly discourage you to load content through AJAX if only for templating purposes. Here's how you can do it with CSS: @media only screen and (max-device-width: 720px) { .articles-parent article:nth-child(n+6) { display: none; } } This would hide the last 6 posts when the screen is narrower than 720px.
  17. Thanks for your opinions @tpr. When you visited the site we hadn't still implemented the images resizing, sorry for that , the projects overview page should be much lighter now. I'm a bit surprised with the menu problem. Although it's in German, the truth is that Menü is not that different from Menu, which is quite universal, and I also think the positioning in the right-top corner is also quite standard. Anyway if it confused you, it's great that you brought it up, your idea of referring to the projects page somewhere on the homepage might work pretty well as a guidance to where to go first. We'll consider this for sure!
  18. You have many options. One is to have the pages that you don't want on the main menu as "hidden", and build the second menu by hand. Another is to make a simple menu builder, for example on the home template, with two different page fields. There are more options, but I think those two are already pretty good.
  19. Hey guys, Here is our latest creation, a website for a landscape architecture studio in Freiburg, south of Germany. http://freisign.eu/ As you can see this is a very simple site. The most complex pages are the project pages since here we wanted to give the editors flexibility to construct the content at their will. Because we had a decent amount of different content blocks the obvious choice was to use the "Repeater Matrix" ProField. We also used the oldie "Page List Image Label" by Soma, which works pretty well for organising the admin of this kind of sites. For the slideshows we used the excellent Slick Carousel jQuery plugin. It still amazes me how flexible and easy to use it is The site is responsive, of course. As always, opinions and suggestions are welcome!
  20. diogo

    iLötscher

    Hi @pwired, thanks for your opinions! The blue is the corporate color so we use it as much as we can throughout the website and we think titles and icons are perfect for that. Yes, I think that's the case. The color is exactly the same, but we don't want the blue elements to be visually as strong as the logo, even if having the same color. I don't have anything against css frameworks but our design process doesn't really allow for it. Erika has all the freedom to design the pages as she feels it works well and I do the effort to code exactly what she designed without imposing any previous limitations. That makes it very difficult to have a go-to framework, and even if I know that I could find a framework to fit each individual case the search would take me longer than doing the css by hand. Thanks! We consider this process to be our strong point, so we should be good at doing it
  21. diogo

    iLötscher

    I guys, fresh new website to showcase https://iloetscher.com/ iLötscher is a Swiss company based in Zürich that provides informatics services for Apple devices and networks. We are still working on the English version and the private area. ProcessWire wise, the website is quite simple and the only non-core modules used are the Pro-fields Table and Hanna Code — both, together with Repeaters, to support the creation of the price tables: SSL is provided by the free Let's Encrypt, that I heard from in this forum (Thanks guys!). The hosting didn't support it (and I didn't have Shell access) but they were happy to install the Let's Encrypt extension for Plesk. Just wanted to let you know that it is worth insisting a bit, in case you encounter the same problem. For the time slot reservations we are using Calendly. It works quite well, and the options for embedding the system on the wesite are very flexible also. The site is responsive, of course. Feedback is more than welcome, thanks!
  22. Sorry @abdus, only saw this now. I just merged your pull request, thanks!
  23. You can use from the API: $pages->emptyTrash(); It's even better if you can do it by bootstraping PW from the terminal.
  24. Turns out that the problem is multisite. I removed emptied the $config->MultisiteDomains array, and the script was called normally and I was able to bootstrap PW. It's really strange, and I don't have a clue what is causing this behaviour in that particular environment (as I said, in a new local install, all worked perfectly) but for now I solved it by bypassing the $config->MultisiteDomains for that particular domain. if($_SERVER['SERVER_NAME'] == "alt.domain.com") { $config->MultisiteDomains = array(); } else { $config->MultisiteDomains = array( "domain1.com" => array( "root" => "www.domain1.com", "http404" => 27 ), "domain2.com" => array( "root" => "www.domain2.com", "http404" => 5332 ) ); }
  25. Hi @Soma sorry for the late answer. The version is 006, but I don't think multisite is the problem. Just installed a new multisite locally and I don't get the same problem. I'll dig a bit more and see what really happening.
×
×
  • Create New...