Jump to content

cst989

Members
  • Content Count

    48
  • Joined

  • Last visited

Community Reputation

8 Neutral

About cst989

  • Rank
    Jr. Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Var dump returns a string but still nothing in the field... It's occurring to me now, maybe I'm misunderstanding this whole thing? Is this actually meant to be populating the html field itself? Will this still work if I'm using embed method C or D on Formbuilder? I'm trying to avoid populating this with javascript but that would be so much easier... perhaps I'll just abandon it.
  2. Hi all, I have a simple issue with inputfield:attr() not setting a value. I'm doing this in ready.php $forms->addHook('FormBuilderProcessor::renderReady', function($e) { $form = $e->arguments(0); if($form->name != 'enquiry_form') return; $inputfield = $form->getChildByName('cart'); if($inputfield) { $cart = json_encode(wire('session')->get('cart')); $inputfield->attr('value', $cart); } }); This is lifted straight from formbuilder hooks and inputfield method specs. If I echo $cart it's definitely a simple string of json, but nothing appears in the cart field (which is a plain text field - later to change to hidden) Is there something obvious I might've overlooked here? As a side question, can anyone think of a better way to do this - add my cart to a Formbuilder submission (it's not a shop, just an enquiry) - while still storing entries easily in the formbuilder entries list.
  3. Thank you, I finally got around to doing this. I was able to combine in || $template->fieldgroup->has('meta_description') as well, and left out the , meta_title='' so you can see them all, empty or otherwise. Only minor oddity remaining is that all the filters generated by this script load in an open position, and you get an odd js glitch when you try to close them the first time - but beggars can't be choosers!
  4. Sorry I should've been clearer. I used the latest version, ie part of Processwire (3.0.1xx) The gifs etc were very big, memory limit was 128M I think. I can't tell you the exact size because I told the person editing the page to make them (much) smaller and reupload. Of course, I can increase the memory and decrease the filesize but the problem was more about being unable to get back into the page without uninstalling the module
  5. In this day and age I feel like the responsive option should be enabled by default! I nearly didn't notice it. How tricky would it be to pass on parameters like ?loop=1 in the URL?
  6. When I enabled this, a page with a rather oversized gif ran out of memory saving, and then proceeded to return a 500 on the front and back-end 🤪
  7. That looks great @Robin S thanks! Would this work with ListerPro as well?
  8. Yeah I absolutely can narrow it down in other ways, its just that if this worked I would have something I could use on any site without modifying the templates checked each time, or having this extra step to check when finishing a site. I build quite a lot of ProcessWire sites so I'm making templates more often than most! I really appreciate the input though, I will make do with what I have for now. Maybe @ryan could weigh in on this one day 🙂
  9. No need to apologise I really appreciate the assistance! Is this still in custom (field=value)? My field exists in about 7/10 templates, when I do meta_title= I get all pages with or without the field.
  10. Hi @dragan thanks for the response, I think I'm misunderstanding or doing it wrong, empty fields are now being excluded. To clarify my field is meta_title - this is what I've done As you can see it matches 14 pages but there should be 16, also the number doesn't change whether using OR or AND
  11. I'd like a bookmark in the admin to a page list of pages that have a "meta title" field, so that you can quickly see which pages need updating. Without just limiting all the templates that have the field, I want something a bit more future-proof. Is this possible? If so how? I don't want to check if its empty or not equal to anything, as it would also serve to review what is there. I have ListerPro as well but can't see how to do it with either.
  12. This seems like one of the nicest, cleanest methods to do this, but for me it doesn't work. I end up on this page instead The Url is /manage/settings but when I click it I'm redirected to /manage/settings/bookmarks What am I doing wrong?
  13. I worked it out while putting the code in this post and trying to remove parts til it works. I had part of my filter like this if(isset($request)) { $filter .= 'price>=".(int) $request['min'].', price<='.(int) $request['max'].', beds>='.(int) $request['beds'].', property_type='.(int) $request['property_type']; } As it turns out, you can't put line breaks in your filter like this! They obviously didn't show up in var_dump or the browser when echoed, so I missed this.
  14. Ok so this is a bit odd, I have actually been doing this: $properties = $pages->find("$filter"); Which is not filtering results properly. However, if I echo out $filter then manually paste the result into the find instead (so it looks more like my example in the first post), it works...?? If I var_dump $filter, it's just a string... I have tried it with and without quotes
  15. Sorry yes, it's not that removing price<=99999.. changes the result, but that nothing changes the result except that Like you say, I am returning all properties, including type 1, type 3, blank type etc., when it should only be type 2. The limit isn't even working, it's returning all 10 properties.
×
×
  • Create New...