-
Posts
812 -
Joined
-
Last visited
Everything posted by a-ok
-
I guess it would be nice to open the topic up and find out what's possible... what I'd probably plan to do is setup a separate CMS of PW on a subdomain (intranet., for example) then try to build some sort of 'front-end profile editor'.
- 16 replies
-
- password protected
- admin
-
(and 1 more)
Tagged with:
-
Sorry to bring back old threads but this interested me hugely as I am looking to do the same thing. @ryan, @renobird @Lance any advice from 3 years ago?
- 16 replies
-
- password protected
- admin
-
(and 1 more)
Tagged with:
-
Haha yes! That is brilliant. I'm guessing you can't change the 'Template > Template.label' text to something more user friendly? That's definitely not the end of the world though. Really really appreciated.
- 14 replies
-
- pagetableextended
- pagetable
-
(and 1 more)
Tagged with:
-
Thanks. But do you mean adding this under 'Automatic Page Name Format'? Or here: protected function renderTableCol(Page $item, array $fields, $column, $width, $linkURL = '') { $out = $this->getItemValue($item, $fields, $column); if($linkURL) $out = "<a class='InputfieldPageTableEdit' data-url='$linkURL' href='#'>" . $out->template.label . "</a>"; $attr = $width ? " style='width: $width%'" : ''; return "<td$attr>$out</td>"; }
- 14 replies
-
- pagetableextended
- pagetable
-
(and 1 more)
Tagged with:
-
Thanks for the help. I have put title, but the title is automatically generated as I don't want the user to have to type 'Image' or 'Image' every time. I have hidden this from the editor by default (see attachment) I'd like the title of the type of page to be shown here.
- 14 replies
-
- pagetableextended
- pagetable
-
(and 1 more)
Tagged with:
-
I managed to found out where it is outputting Automatic Page Name Format (flexible-content-block in this case) in the wire protected function renderTableCol(Page $item, array $fields, $column, $width, $linkURL = '') { $out = $this->getItemValue($item, $fields, $column); if($linkURL) $out = "<a class='InputfieldPageTableEdit' data-url='$linkURL' href='#'>$out</a>"; $attr = $width ? " style='width: $width%'" : ''; return "<td$attr>$out</td>"; } So, where it is outputting the `getItemValue` can it not output the label of the template being used? Ideally something like $templateLabel = $template->label; if($linkURL) $out = "<a class='InputfieldPageTableEdit' data-url='$linkURL' href='#'>$templateLabel</a>";
- 14 replies
-
- pagetableextended
- pagetable
-
(and 1 more)
Tagged with:
-
Yep, definitely using the Extended version. But maybe it's to do with the 'Automatic Page Name Format' field? See my screenshots below. Any way to make the 'template label' appear as the type? Do you see what I mean?
- 14 replies
-
- pagetableextended
- pagetable
-
(and 1 more)
Tagged with:
-
Hi folks, I've been using the PageTableExtended recently to create some dynamic/curated sections on my site which is working really well, functionality wise, but the admin layout in the CMS is a little odd to work with. I have attached a screenshot of how one of my setups currently looks. You'll see it's hard to know what 'flexible-content-block' is an image, or text, or embeddable media etc. What would be really useful is to see the 'page' title on this screen. I have attached a screenshot with an idea. So, is something like my proposal currently possible, and if not, could it be added to a feature list? Wordpress's ACF flexible content area use this type of setup and it's a lot easier to maintain and organise. Especially for clients/users. Or, is there a way which I can fork this and build this layout for others to use if they find it useful? Thanks, R
- 14 replies
-
- pagetableextended
- pagetable
-
(and 1 more)
Tagged with:
-
Thank you for all the help and replies. I believe all the page permissions are correct but will go through it all and check. Is there anything obvious I should be looking for? Also, this is not in an extra tab and is in the content tab.
-
How would I double check this? I am sure it is all set up correctly?
-
Thanks. Okay, so I have compared the DOM on a project where it works, and on this one where it doesn't, paying attention to '#_{fieldname}_add_items' you mentioned. See below for two images, the first one is the one that works can you can clearly see some more elements in the DOM relating to the page autocomplete. The setup is exactly the same from what I can see... so why would the '.InputfieldPageAdd' div and its contents be missing from one and not the other?
-
Thanks. I've checked and nothing. When I type in a page name, it looks like a search option is AJAX'd in (see attached) but no errors?
-
Thanks for the reply, but I have all this enabled...
-
Hi folks, I have a simple Page field setup to act as a tag system. This has worked for me, but for some reason it's not working now and I can't find out why. I can select previously added 'Pages' here, but cannot add new ones (comes up with a little warning symbol (see attached)). Any way I can check through to see what I have changed to affect this? Debug mode? What should I be looking for? I have tried to test it alongside another project with a similar setup that still works but all seems to be the same? Thanks guys, R
-
Hi folks, I am building a 'logo' list of supporters/clients. I have two slides and would like to show different ones on each slide, but work with a single repeater on the page. There is two checkboxes within the repeater when adding a logo ('created_for' and 'helped_create'). I thought this code below would work in returning ONLY those 'repeater rows' which has the 'created_for' checkbox checked, but it's still including the logos that have the 'helped_create' checkbox checked too. I think I may have my foreach loops mixed? Any thoughts? <?php $created_for = $pages->find('wwww_slider.created_for=1'); ?> <div class="each-icon-container"> <?php foreach ($created_for as $created) : ?> <?php foreach ($created->wwww_slider as $icon) : ?> <div class="each-icon"> <?php if ( $icon->link ) : ?><a href="<?php echo $icon->link; ?>"><?php endif; ?><img src="<?php echo $icon->logo_off_state->url; ?>" /><?php if ( $icon->link ) : ?></a><?php endif; ?> </div> <?php endforeach; ?> <?php endforeach; ?> </div> Thanks in advance, R
-
Fixed this with <?php if ($page->next->id) : ?>
-
I am setting up some simple pagination for a page, and want to use the $page->next or $page->prev functions. Everything works as I want, except for one part – checking whether a next/prev page exists or not. So, for example, this works within my code <?php if ($page->next->journal_featured_image) : ?> but if I wrapped the whole section in <?php if ($page->next) : ?> it doesn't seem to make any difference. I tried count too... but no use. Any ideas? Thanks, R
-
Thanks all. I worked it out. Below is an example <?php foreach ($page->flexible_layout as $layout) : ?> <?php if ($layout->text) : ?> <div class="row"> <?php echo $layout->text; ?> </div> <?php elseif ($layout->image) : ?> <div class="row"> <?php echo $layout->image; ?> </div> <?php elseif ($layout->wide_image) : ?> <div class="row"> <?php echo $layout->wide_image; ?> </div> <?php elseif ($layout->slider) : ?> <div class="row"> <?php echo $layout->slider; ?> </div> <?php endif; ?> <?php endforeach; ?>
-
But how do I state what I want each 'section' to look like? So my PageTable setup as an image field, images field, text and a wide image field.
-
I mean outputting the data saved to a template from a PageTable. The foreach/if loops etc. I can't find out how to do it...
-
Thanks for all your help here, guys. I'm working through it but the only thing I can't find is how to actually output the layout in a template?
-
Strategy for flexible content types in a template
a-ok replied to jordanlev's topic in Getting Started
This whole topic was so useful, by the way. So thanks all. -
Thanks for your input. I'm still struggling to see how this is similar to the ACF side of things. Why can't it use fields rather than pages. I don't need pages created for a slider to be used on a journal page etc. Do you know what I mean?
-
Thanks all. Is there any docs on PageTable? I'm struggling to find out what it actually is. My guess is that you create templates with the field you want, so you might have a template for a textfield, and a template for an image. Then you add these templates to the PageTable field and then you can organise and add as many as you want? If so, sounds good. Would be nice to do it with just fields rather than pages of fields. Thanks so much
-
Hi folks, I used to be a big fan of WP, but luckily found ProcessWire and in general it has been so great and super flexible... so thanks for that and all your hard work. It's appreciated. One thing I was a big fan of on WP when using the ACF (Advanced Custom Fields) was the 'Flexible Content' add-on (http://www.advancedcustomfields.com/add-ons/flexible-content-field/) which essentially allowed you to build a series of elements to use (textarea, image etc) then when a user came to build this section on the CMS, they could build a flexible page using those defined elements. So one page might be textarea, image, image, textarea and another may be image, textarea, image, image, image, textarea etc. They have the fields and they build the order. Is there anything PW offers in this respect? I was checking out Tables (https://processwire.com/api/modules/profields/table/) but it's quite strict and not that flexible (unless I am missing something!) Thanks and hope you can help, R