Jump to content

sambadave

Members
  • Posts

    59
  • Joined

  • Last visited

Recent Profile Visitors

3,049 profile views

sambadave's Achievements

Full Member

Full Member (4/6)

19

Reputation

  1. @wbmnfktr We've tried adding the remote database server's IP to our local hosts file. Unfortunately we're not seeing any noticeable improvements. We're asking our IT department about the security measures they have in place and waiting for a rresponse. @rick We've not noticed a delay via SFTP. I'm not too sure about your other questions yet but I've asked other people on the team and have also passed this thread link on to our IT team. I can confirm that one member of our team wasn't using MAMP and still experienced the same issues, so that may rule out anything to do with MAMP setup. I'll let you know if I find out any more information. Thank you both very much for your help so far.
  2. Has anyone noticed abnormally slow page load times when working locally but connected to a remote database? I work within a team and we all have local versions of our PW sites but are connected to the same remote database. This allows us all to work from the one ProcessWire admin area, which we prefer. We have noticed our sites loading really slowly in this scenario and it is really limiting productivity. Average load time comparisons across our websites Working locally, connected to remote development db ~30s to 1 minute (1minute for more complex pages) Hosted development site - connected to same development db ~5s - 10s Live site, optimised with ProCache etc and live db ~3s - 5s Our template setup Overall, the majority of our page templates aren't doing anything particulary fancy. Most templates allow sub pages to be rendered on the parent page as blocks using the $page->render approach. In some cases there may be a number of blocks to display. We recognise that rendering a lot of blocks on a page could slow things down a little but not to the degree we are encountering. Steps taken to identify issues in our code As a test we removed all the rendered blocks from the parent page template logic and went as far as just showing a single static <h1> heading. We still saw times of ~15s with an almost empty page. It feels like this has something to do with the database connection, or maybe something within our MAMP setup on our Macs. It's strange as our hosted development and live sites are so much faster, so this feels like a problem with our local setup. If anyone has any suggestions as to where we are going wrong, we'd be very grateful. It can be quite frustrating when we need to refresh the page regularly to see our changes but we know that we will face up to a minute wait just to see if something has worked. The live sites are really fast so this is definitely something with our setup I would think. Thanks in advance for any words of wisdom ?
  3. Thanks @bernhard I've very little exposure to hooks but I really should have a dig around and this is a great example to work from. Also thanks @DV-JF I never thought of that approach as well, by addidng pages through the page reference field. As always, there are lots of great ways to approach it with PW which is great. I apreciate your help ?
  4. @BitPoet @kongondo Wow, exactly what I needed. This opens up so many possibilities. Thank you! ?
  5. Hi there Short version of question Let's say I have a page in the admin that contains a field... Is it possible to output the content from that field on another page in the admin? Almost like a reference. Longer version of question (with example) A house builder with multiple (60+) developments. They want to be able to create notices/messages that can be added to one or many developments. Handy for things like regional covid lockdowns or temporary office closures due to bad weather. My approach for the admin editing options: Add each message to each development Pros: You edit the message on the development page in context Cons: Very time consuming and repetitive if the same message needs to be applied to 60+ developments Control all the messages from one admin page and say which development each message should be applied to Pros: Easier to add/remove messages to more than one development at a time. Control all messages from one place. Cons: Content is not added on development page, which is where typical admin users may expect to find it I went for option 2 due to flexibility, and created a page within the admin for global development notices. This contains a repeater with: Field for message to display Checkbox list of all developments. The user can select which ones to apply each message to It's working really well but the only thing is that if the user goes to a specific development in the admin, the relevant messages aren't displayed in context (as they aren't edited on that page and instead on the global development notices page)... which may cause confusion when a new staff member / content admin tries to edit the text but there is no field when they go to the development admin page where they expect to see it... Solution??? I don't require the message(s) to also be editable on the development page, but I wondered if there was a nice way to show it/them somehow. I feel like I am missing something really simple as I'm sure ProcessWire will have a nice way of achieving this, or maybe there are field settings that allow this kind of thing to happen? Any ideas on approaches or similar experiences would be much appreciated, even if it is just a much simpler example with the content from one field being shown on another admin page to get the ball rolling. Thanks in advance for any advice :)
  6. Apologies @kongondo I should have mentioned that I changed the settings of the file field to an image field after thinking the same thing. Ihad no idea that this would work with other file types as well so that will be useful on other projects I'm sure. For the website I'm working on an image field was enough though. Icould be wrong about the CMYK thing too. It turns out that the images were huge and had high 300 dpi settings so I think PW just crashed out trying to resize them. Uploading a more sensible image to start with seems to work fine now. Hope that helps ? It's a great module, so thanks for making it available.
  7. It looks like our client has uplaoded CMYK 300res images into the site. Swapping this out with an RGB image and PW seems able to resise it. Maybe PW struggles to resize CMYK images? I appreciate the help @heldercervantes Thanks
  8. Thanks for this great module. @kongondo - When rendering out the base image on the page I tried to add a width using processwire's standard image->width($x, $options) approach however I can't seem to get the image to ender when this is applied. I tried changing the field type to be image instead of file but still no luck. Is there something different about this field to the standard image field that the above approach would usually work on and do you have any suggestions as to how I could output a resized version? The client I am working with has multiple editors and not everyone knows to resize the image before uploading. I could leave a note in the CMS next to the field temporarily I guess. Any help would be much appreciated. Thanks
  9. Hi @teppo is it possible to order the results by the number of times the search query is found so that more important pages are listed first? For example, a page containing the search term 5 times would appear higher than a page with the search query found only once or twice?
  10. Thanks @Macrura and @dragan for the ideas. Selectize looks like it could do the trick! I'll check out that icon module too. Much appreciated Dave
  11. Thanks for such a detailed explanation @bernhard that's new to me and will definitely come in handy. I guess if I was to do this then I'd have to update the hook for any new select options though. If I had a set of 50 icons, 10 colours etc it could end up being quite a chore updating the hook file every time. Correct me if I'm wrong here though. Ideally, I'd like to set up the config area so that other admins that aren't necessarily coders, could add new options through the CMS. The beauty of the page reference select list is being able to select a parent page and show the children as options in a select box/radio/checkbox etc... so if you add a new option through PW admin the list just updates automatically. I'm sure there's a solution to this as is always the case with PW. Thanks again.
  12. Thanks @Sergio I kind of understand how that module works now after a quick skim through. I'm not quite sure how I would go about using that to create a selectable list though. Apologies, my PHP knowledge isn't brilliant. I was hoping that I'd be able to somehow open up the paramenters for the "Custom Page Label Format" on the "Input" tab of the speific page reference field to somehow allow me to add additional php and/or html markup within that, wrapped around the particular field values that I wish to use? Do you think something like that is achievable?
  13. Hi everyone, here's the problem I'm trying to solve. I have a config area in my PW admin that is locked down for admin use. I use pages to store a bunch of settings that I'll use for my clients website. It's mostly used for visual things like colours and theming. This list could be tiny or large, depending on the sites requirements, but its great because I can store any information I want to. So the page tree could look something like this: ADMIN SETUP Home Config Aesthetics Colours Red Field: Custom Label - "Red" Field: Class name - "theme--red' Green Field: Custom Label - "Green" Field: Class name - "theme--green' Blue Field: Custom Label - "Blue" Field: Class name - "theme--blue' etc... Sizes Small Field: Custom Label - "Small" Field: Class name - "sm' Medium Field: Custom Label - "Medium" Field: Class name - "md Large Field: Custom Label - "Medium" Field: Class name - "lg" etc... Icons Target Field: Custom Label - "Hands shaking Icon" Field: Icon SVG - "[svg code]' Target Field: Custom Label - "Target icon" Field: Icon SVG - "[svg code]' Success Field: Custom Label - "Happy face icon" Field: Icon SVG - "[svg code]' etc... HOW I USE THIS I'm then able to set up page reference fields for colour, size and icons. I'll use these fields on particular pages so that my clients can select a particular colour, size or icon, or anything really. Currently, with the page reference field I can create a custom label for the options. So for something like colour I can label the field "Theme" and present a list of colours like "Red, "Green" and "Blue" using the custom page label label format of the colours page. This of course means that I can use this to do some lovely presentation on the front end of the site. With a colour selected I'll then be able to use the page reference to get the class name for that colour theme so that I can update the page's look and feel. So in my markup I'd end up with "theme--red" or "theme--green" etc. THE PROBLEM I have this all working which is great and it's really flexible for the client which they love. However, I'd love to be able to make things more visual for the client. Is there a way to be able to output more than just text in the page reference field? I might have a bunch of different blue colours, so instead of a list like so: Navy Blue Deep Blue Bright Blue Sea Blue ... it would be great to be able to output actual colour swatches, which is a lot mor visual for the client. Taking the icon selector, I would ideally like to show the actual svg that I've stored against that icon as a selectable image instead of seeing text options like: Hands shaking icon Target icon Happy face icon Just a couple of scenarios here, but as you can see there could be any number of reasons to display a more visual method of selection. ANY SOLUTIONS? I've looked at modules like FieldtypeColorPicker which could help in solving the colour issue, but it doesn't allow me to select a colour and then use a particular class name assigned to it the way I describe above. Considering the other use cases I mention above, does anyone know if anything exists already that would help me to create custom presentaion for page reference lists, or if there's anything planned? Thank you in advance for anyone who's read this far and has any words of wisdom! Dave
  14. Good shout @dragan These links could point to any new resources as and when new builds are released. Things like intro videos, the PW cheatsheet, some basics on templating/setting up a field and adding it to a template. I find that when I show a new guy the relationship between fields, templates and some simple back end logic, it sparks a "Are you serious, it can't be that easy!?" comment every time. There's nothing that I can see in the ProcessWire journey that introduces this at the right point... the point of installing and going "What's next?" It might be that people are downloading it, but maybe they're dropping off once they see a blank installation and aren't sure where to go for a really simple breakdown of how to get started with templating. There's a tonne of great content already on proceswire.com explaining this, but it's maybe not structured into this journey in a way that a new user would naturally expect to find it.
  15. I totally agree that we need a new processwire.com. Our existing clients that use PW think it is brilliant but it's always quite hard to sell it in initially to new clients using pages from processwire.com. Admin look and feel I've found that most of our clients aren't concerned with the admin skin. It's simple and does the job really well. That said it could be modernised and it would be more visually appealing. A good example would be Umbraco, who's CMS used to look terrible, until it was given a fresh new face. It's really stripped back now and almost has a kind of Apple, utilitarian feel which lends itself to the task at hand. I think their users increased rapidly following this. Who is ProcessWire for? Everyone... but for different reasons! One thing I've learned from working with ProcessWire, is that it means different things to different people in terms of what is important and how PW tackles the job. A facelift may make it look nicer but I think the site needs to really target a few different audiences with some quick summary pages, highlighting why it's perfect for them. Designers Back end developers Front end developers Project Managers Content Editors Clients Marketing Directors If you can target these groups, under a general "Why ProcessWire is great" kind of entry point, then I think we would see a lot more people hitting that download button. I know the current PW site kind of tackles this, but I would say that it should be more obvious. After Installing PW... what next? When I downloaded Processwire initially I thought "okay what do I do now?". I came from an umbraco background so knew that I would essentially be installing a blank CMS (which I like as there's nothing that I don't need)... but if you're coming from Wordpress or are a first time CMS user, maybe you're expecting more... maybe you're expecting a landing page with links to useful resources and videos... Maybe this landing page could be tailored based on the type of user you are? Video - Tell me stuff I searched on google for demo videos and stumbled across a great video that Ryan had recorded. I think video is the way forward here. If people are time starved, then they just want to be introduced to the admin and all the great things it does. The thing is though, that if an admin reskin is in the pipeline, you can't record your video until that's done. I'm just rambling now... but hopefully some of this is useful. Cheers!
×
×
  • Create New...