Posts by walker

    What will you sell instead?

    Ill sell anything the client will buy thats not Wordpress. Wordpress is the only thing clients have heard of, they know they can edit the site themselves and can take it to another developer if they want, no lock in. I used to try and sell the client on Joomla but the plugin subscription model was hard for the client to stomach, a subscription makes it look like a service then they get scared of lock in.

    Since I ditched Joomla three years ago for perch its been great. They are worried it will be difficult to edit, I show them the backend of another clients website and they say "WOW thats a lot easier than Wordpress!". They are worried about lock in, I tell them its a one time price for an open source professional cms that they can then take to any developer and they are sold.

    I will still try and sell my clients on perch, as I think its the best option for them but if I fail they get what they want (most likely wordpress) and you don't get paid. I apologise if my tone comes across as critical, I'm fine with the new model, I am just trying to pass on my clients concerns as ultimately they are the ones paying for perch and making the decision to use it, not me.


    I have got a bit further in debugging it. When I edit the user it updates the memberProperties column in the database but then doesn't render those changes like its being cached.

    I was right. The member properties are pulled from the database and stored in the users session at login. When you call perch_member_get to get a member property it comes from the users session not from the database. This means that the database and user session can get out of sync where the backend shows whats in the database and the front end shows whats in the now out of date session.

    To fix the issue

    I added a new function to the end of "perch_members/runtime.php" called perch_member_sync() which updates the user session from the database.

    I then call perch_member_sync(); at the top (before any data is sent to the user) of any frontend page that was giving me issues.

    > I did a great deal of research about 3 years ago on which CMS I wanted to use, quality, speed, flexibility, control and price were all factors that lead me to Perch.

    Me too but things change in 3 years and my loyalty is to my clients. Joomla extensions have a similar pricing / support model as perch 4 so I am fine with the new model. The old pricing / support model was better than Joomla now it's the same, thats fine but I find clients really don't like the Joomla support model, so I will have a harder time selling perch to clients, so I'm not going to sell as much perch, thats all i'm saying.

    Sorry, Im creating the member in the backend, when I create the user it takes the file fields and it creates the user like I expect. But when I then go to edit the member again in the backend it shows all the file fields as empty. I try uploading the files again or different files but it still shows the file fields as empty on the backend, on the front end it still shows the original files uploaded when the member was created.

    I have got a bit further in debugging it. When I edit the user it updates the memberProperties column in the database but then doesn't render those changes like its being cached.


    I have discovered the same issue with the textarea tag, the code below has been updated to fix this issue too.


    While PerchFieldType->render_inputs($details) looks for $id in $details for whatever reason PerchFieldType_file->render_inputs($details) looks for 'perch_'.$id in $details doesn't find it and things the field is blank. The front end caches the member details in their session, to clear the cache log out and in.

    To fix the backend copy and paste the below code after the opening <?php in "addons/apps/perch_members/modes/".

    1. $PerchedDetails = [];
    2. foreach ($details as $key => $value) {
    3. if (is_array($value)) {
    4. $PerchedDetails['perch_'.$key] = $value;
    5. } else {
    6. $PerchedDetails[$key] = $value;
    7. }
    8. }
    9. $details = $PerchedDetails;

    I have used the old forum for support a lot in the past and thought it was a great solution. I have gotten fast support from the helpful and friendly community, and expert advice and knowledge from Drew and Rachel. I appreciate that its open as I have been helped so many times from other people who have already asked and answered my question.

    The new forum and wording (from support to forum) makes me worried, is developer support no longer a thing? Was it ever supposed to be a thing? Installing a forum and then relying on your community to support your product really isn't support. While the documentation is good it isn't good enough to stand on its own.

    For an extra 50 dollars craft cms does everything perch does, has more documentation and more importantly developer support. The weakened commitment to support kills perch's offering as a professional cms, and it worries me a lot.

    I have added a few file fields to the member.html template so it looks like below.

    1. <perch:members type="text" id="first_name" label="First name" listing="true" order="1" />
    2. <perch:members type="text" id="last_name" label="Last name" listing="true" order="2" />
    3. <perch:members id="document1" type="file" label="Document 1" order="3">
    4. <perch:members id="document2" type="file" label="Document 2" order="3">
    5. <perch:members id="document3" type="file" label="Document 3" order="3">
    6. <perch:members id="document4" type="file" label="Document 4" order="3">
    7. <perch:members id="document5" type="file" label="Document 5" order="3">
    8. <perch:members id="certificate1" type="file" label="Certificate" order="4">

    When I create a new member in the backend it shows all the new fields, I can upload files and it all works great.

    After saving the member, these fields are then empty, I try uploading a different file but it wont take the files are still missing on the backend and they are still the origional files from when I created the member on the front end.