Jump to content

3fingers

Members
  • Posts

    437
  • Joined

  • Last visited

  • Days Won

    4

Everything posted by 3fingers

  1. You should also remember to: // Set output formatting off $object->of(false); // add images here with your conditions // Set output formatting to true back again $object->of(true); // at the end save your page $object->save();
  2. I've read those comments too, but more than worrying about Processwire loosing traction I've wondered what other tools those developers are using right now and why. As you know the tech/development stacks vary a lot depending from too many variables to list them all. To me Pw is healthier than ever, even though I'm FIRMLY convinced that pw lacks of marketing share because of "poor/dated" ui/ux design in term of presentation (I'm looking at you). This makes me sad and mad at the same time. Off-topic is over, thanks :)
  3. A quick codepen to get you started: https://codepen.io/3fingers/pen/JjEPWZP
  4. It looks very cool, I'll follow its updates for version 2 release. +1 Here too ??
  5. I have updated Codepen with a solution. Be aware that is an hacky one, because on narrow screen some text clipping might occour. If you play with it a bit and you don't have a lot of text you can use it as a good starting point.
  6. I'm close to approach something similar for the first time. My client has a Wordpress site where he wants to integrate a search functionality (various filters, category and so on). Of course I'm looking for a way to handle it in Processwire. My idea is to leverage the Wp rest api and build upon the json response in Processwire. My concern though is that the search page should live on the same domain (eg. originadomain/search) and I don't know how to handle this request to point to my Processwire installation, nor how to let Wp and Processwire live together happily on the same server. ... and what about trying to integrate my Processwire search page inside an iframe on the Wp page? Does it sound to you like a big hack? Any advice would be very appreciated ? Thanks.
  7. Here is what I came up with: Codepen Let me know if it is what you were after ?
  8. Nope. I'm just investigating upfront because I'm close to start a new project and yours matrix fieldtype looks like a good candidate. Any advice on how to start with Custom PHP Code to do what I'm after? Thanks ?
  9. I'd like to have a single matrix field (yours) inside a RepeaterMatrix (pro-field). For each matrix(yours) I'd like to be able to upload/paste csv definitions and render a table accordingly. Every csv might have different colums/row numbers and definitions.
  10. Hi @kongondo, sorry if this is been answered before. I know it's possibile to upload/paste a CSV to populate row and columns of the matrix, but is it possibile to skip row and columns definition upfront (via selector, etc.) and define them via the CSV itself? I am asking this because I'd like to render on the frontend different tables whom have unique rows/columns definition.
  11. $userPage->order_status = 1; // simple as that
  12. To me it looks like https://www.timeanddate.com/time/map/ is doing what you're after. You can search by name and then you have the timezone of the city you've entered inside the "Timezone" tab.
  13. There are a tons of ways to do what you're asking, so I'm just suggesting something based on your previous example. In the template add a repeater field "repeater" and add to it 3 fields (name whatever you want, just stick to mine if you want copy/paste the code block below): 1) class_string 2) title 3) description All of them are of type "text". Fill them as you like. In the template file then paste this code where you need them to be placed. <?php foreach($page->repeater as $block): ?> <div> <div class="box-pf"> <i class="<?= $block->class_string ?>"></i> <a href=""><span class="uk-text-middle"><i><?= $block->title ?></i> '<?= $block->description ?>'</span></b></a> </div> </div> <?php endforeach; ?>
  14. From the blog post you've linked: Radio input (like the "License" one shown in the image) looks like is not mentioned there, so yes, to me it looks like a misleading example. I read somewhere in the forum that ryan has the intention to make some polish on custom image field, but honestly I don't remember where.
  15. What a project! ? May I ask you some insights? a. Very clever use of the interactive map https://www.shetland.org/map. How you have managed the interaction between the custom search nav and the map reactivity? b. On the vacancies page, how you have made a relationship between the url query string and the filter strip? c. Any insights on you've built the inner search functionality? I'm particularly curious about the ajax refresh ? Last one, I promise: Could you give us a roughly timespan of the project (design and development phases) and an brief indication of the budget your agency had? Thanks and thumbs up again! ??
  16. There you have it: Simple solution for a simple google search :)
  17. That's it. I just don't want to let my clients have the freedom to play with styles, at least not within boundaries I can manage by code. It would be such a pain if I have (as accountable/developer of the project) to fix the mess made by a client inside the editor. Moreover, from my experience, if I give a client some sort of freedom (especially inside the creative side of things) then he will ask me more and more (Can I do this? Can you add this for me?). The editor become their toy, and the front-end the crappiest as ever. On the flip side of the coin I would really love if we, as developers, could have the ability to let editors manage our pre-made components in a more compelling/modern visual way.
  18. Thanks @thomasaull and @Sebi (I've just bought you 3 coffees). Keep up the good work! :)
  19. ... not a module request but I'd love to have a snippet of code to access and expose Repeater Matrix Fields inside the docs :)
  20. @Noel Boss hi! Just here to check if you are still around in the forum, since I'm looking at your module for future projects. Does anybody using it without gotchas with the latest PW releases? :)
  21. You don't need a web host already in place to start using pw, you do need a local server with apache,mysql and php installed as @netcarver already mentioned. I personally use XAMMP. There are a ton of tutorials on how to setup a local environments, like this one specifically on xammp and mac.
  22. For anyone who is interested in integrating tailwind inside a processwire project here is a little walktrough based on my workflow. This little guide is based on Tailwind 1.9.6 (latest before 2.0 release) because some PostCSS library I use are still not compatible with 2.0 version (not a big deal, really). You can find the necessary files here. - Place package.json, tailwind.config.js, postcss.config.js inside your template folder. - Create a "pcss" folder, and make a structure like this: pcss ├── inc │ ├── colors.pcss │ ├── fonts.pcss │ ├── media_queries │ │ ├── lg.pcss │ │ ├── md.pcss │ │ ├── sm.pcss │ │ └── xl.pcss │ └── sitewide.pcss └── kickstart.pcss Now you got everything to get started, let's have a look at the files: package.json Inside "package.json" you have different dependencies I've installed to mimick my "old" scss workflow (importing, nesting, etc..), the important part however is the script section: "start": "npx tailwindcss build pcss/kickstart.pcss -o css/dist.css", "watch": "npx postcss pcss/kickstart.pcss -o css/dist.css --watch", "build": "cross-env NODE_ENV=production npx postcss pcss/kickstart.pcss -o css/dist.css" "start" is the bootstrap script you have to run at first, to let node compile tailwind as a whole. Do it at the beginning of the project or everytime you make some changes to "tailwind.config.js" Change the name of your pcss files accordingly (I've used pcss as an extension, but css would work perfectly fine) "watch" is the next script you have to run in order to have live reload of your stylesheets. "build" is the script you have to invoke once you are ready to deploy to production (you need to specify your purge rules inside postcss.config.js, keep reading.) tailwind.config.js Here you can specify your tailwind configurations, read the docs here. One thing to notice inside mine is that I've set purge: false because I prefer to configure the purge part inside a dedicated file, which is: postcss.config.js This file is responsible to handle postcss options, and purge is one of them. The paths you declare inside the content array are the ones whom will be scanned and purged eventually. Mine could be different than yours, so pay attention. The whitelistPattern array is useful when you want to exclude some classes from the purge phase, below I'm excluding the ones whom starts with "fff-". ... content: [ './*.php', './inc/*.php', './fields/*/*.php' // etc. ], whitelistPatterns: [ // Pattern to exclude during extraction /^(fff-)/ ], ... The other settings are pretty explanatory (cssnano is used in production for minification). As a final note you'll notice that every pcss file I use starts (and ends) with: /* purgecss start ignore */ css... /* purgecss end ignore */ Those tell purgecss to ignore completely the file, since I know I want to retain every rule/class I write in there. If you got everything setup correctly you can start having fun ? Run: npm install then: npm run start and finally: npm run watch Hope this little "guide" could enlighten in using Tailwind ?
×
×
  • Create New...