Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

19 Good

About sambadave

  • Rank
    Full Member

Recent Profile Visitors

2,443 profile views
  1. 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
  2. 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.
  3. 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?
  4. 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
  5. 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.
  6. 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!
  7. Update: Adding templates fixed by adding auto_increment to id in "fieldgroups" table.
  8. Hi Wanze, thanks for the tips. I updated to 2.6.1 and I'm not receiving the error you quoted any more thankfully. I also tried your other tips but with no luck. I'm a bit closer to a solution though. Although editing existing pages was completely fine I was having a lot of bother creating new pages, new fields, new modules etc. After a bit of googling I was able to set auto increment for primary key in those tables which has fixed a lot of the issues as far as I'm aware. For some reason though I still can't create new templates. I'm getting the following error after trying to add a new template in PW: Session: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0' for key 'PRIMARY' I assumed like the others that this was coming from the templates table so I've set "id" to auto_increment. It doesn't fix my problem though and I'm out of ideas now. It feels like I've definitely made a mistake somewhere along the way when exporting / importing databases so I've only myself to blame here. I'm still learning this side of things.
  9. Sorry folks, I'm having no luck tonight. I can't add any new pages, fields or templates... and I'm not sure if there are any other hidden errors that I haven't come across yet. I'm no SQL expert here but after a bit of looking around I think my database might have fudged at some point (most likely when I was exporting / importing). The client hasn't had to create any new pages until now so I think it's been hiding for a while. It appears to have something to do with auto incrementing and primary keys. Like I say I'm no expert here so after a little bit of editing in phpmyadmin I've managed to sort out some of the problems. I'm not 100% confident with any of the changes I've made and I'm not sure if there might be a lot of other stuff under the bonnet that I'm not aware of that still needs looked at. Can anyone give me any pointers as to how I can begin to fix this?
  10. Thanks MuchDev. I don't appear to be getting the crazy never ending page tree now which is great. I can edit pages fine, but still can't add pages without getting the following error after clicking "save" on the "Add New" screen. Error: Maximum execution time of 30 seconds exceeded (line 1896 of /Applications/MAMP/htdocs/viceroy/wire/core/Pages.php) I wouldn't have thought ProcessWire would be struggle to create a page in 30 seconds?
  11. Hi MuchDev. Thanks for helping out. I'm using version 2.5.3. I was using Firefox but just tried in Chrome too and the same problem exists there too. I'll try and upgrade and let you know how I get on. Do you think there's a good chance that upgrading would fix this? I wasn't sure if "Menus" might be some sort of admin specific name and that's why all the admin pages have jumped in there? The error log is saying this (I've masked out my site url): 2015-11-11 17:09:34 admin Module ProcessPageEdit failed init - Unknown page 2015-11-11 17:09:34 admin Module ProcessPageEdit failed init - Unknown page 2015-11-11 17:09:34 admin Error: Call to a member function is() on a non-object (line 106 of /home/viceroyf/public_html/wire/modules/Process/ProcessPageEdit/ProcessPageEdit.module) 2015-11-11 17:09:37 admin Module ProcessPageEdit failed init - Unknown page 2015-11-11 17:09:37 admin Module ProcessPageEdit failed init - Unknown page 2015-11-11 17:09:37 admin Error: Call to a member function is() on a non-object (line 106 of /home/viceroyf/public_html/wire/modules/Process/ProcessPageEdit/ProcessPageEdit.module) 2015-11-11 17:09:38 admin Module ProcessPageEdit failed init - Unknown page 2015-11-11 17:09:38 admin Module ProcessPageEdit failed init - Unknown page 2015-11-11 17:09:38 admin Error: Call to a member function is() on a non-object (line 106 of /home/viceroyf/public_html/wire/modules/Process/ProcessPageEdit/ProcessPageEdit.module) 2015-11-11 17:12:18 admin Error: Maximum execution time of 30 seconds exceeded (line 165 of /home/viceroyf/public_html/wire/core/Field.php) 2015-11-11 17:12:18 ? Error: Exception: SQLSTATE[HY000]: General error: 2006 MySQL server has gone away (in /home/viceroyf/public_html/wire/core/DatabaseQuery.php line 91) 2015-11-11 17:12:18 ? Error: Exception: SQLSTATE[HY000]: General error: 2006 MySQL server has gone away (in /home/viceroyf/public_html/wire/core/DatabaseQuery.php line 91) 2015-11-11 17:14:06 admin Error: Maximum execution time of 30 seconds exceeded (line 922 of /home/viceroyf/public_html/wire/core/Pages.php) 2015-11-11 17:16:03 admin Error: Maximum execution time of 30 seconds exceeded (line 933 of /home/viceroyf/public_html/wire/core/Pages.php) 2015-11-11 18:13:22 admin Error: Maximum execution time of 30 seconds exceeded (line 938 of /home/viceroyf/public_html/wire/core/Pages.php) 2015-11-11 19:04:56 admin Error: Maximum execution time of 30 seconds exceeded (line 677 of /home/viceroyf/public_html/wire/core/Page.php)
  12. Hey folks. My client has just mentioned that they can't add any pages on their site. I went to have a look and it appears that the tree nav is all over the place. For some reason my tree nav is caught in an endless loop where random admin specific pages keep repeating inside? It goes on for ever. When you click in to a page it uses the same page id, regardless of where in the tree nav you select it from so I'm scared to go deleting pages. Can anyone help me here?
  13. Thanks Soma for the detailed answer. Really appreciate everyone's help here. It'll take me a while to get my head around all the feedback but I'll see how I get on within a safe testing environment first. Thanks again
  14. Hi guys Thanks Andreas – Good to know I can do that. I'm just a little concerned for larger sites as going through all the image folders to delete certain images could take ages and might involve an element of risk if I was to delete the original image by mistake. Unless there is a way to do this with code? tsdtsdtsd – I wonder if there could be a way to toggle this setting through the admin to allow options to be taken into account. It's not a biggie now I know but it would be a shame to have a huge site and have to go through all the images manually. ProcessWire is still awesome though!
  15. Hi folks I recently put a site live and in the last stages of the project decided to do some image optimisation. $options = array( 'quality' => 70, 'upscaling' => false ); $pageImageLargeDesktop = $pageImage->size(960,720,$options)->url; The thing I love about ProcessWire is that you can change the size here and the new images will be generated across all pages. It's such a time saver. However after adding in $options parameters I expected the quality of the images to reduce on a page refresh, howeever the quality settings only seem to be applied during upload. This meant I had to re-upload all my images again into ProcessWire for the changes in quality to appear. Is there a way of getting round this? It wasn't a massive problem for this particular site but I'm thinking more along the lines of a larger site with hundreds or thousands of images. You just couldn't go back in and re-upload every image unless you had a lot of time on your hands. Am I missing a trick? Thanks in advance for any help.
  • Create New...