Sign in to follow this  
Followers 0

200+200+200 Field-Text/url/textarea into 1 Template

2 posts in this topic

Hi, excuse me but I need any suggest...

I want to create 1 page of my site with 200 plants, 200 description and 200 link to another page.

I begin put in 1 Template 2 field-text, and I see that it appear in Field-List!
If I create 200+200+200 field... I see all in tha list!


If I create 200 article by filed-textarea, I don't see it in Field-List!
I create yet 75 article in 75 pages, but I don't see it in Field-List!

What I don't understand? :/  

Share this post

Link to post
Share on other sites

Hi - I'm totally not following your post.

However, based on your 2nd sentence, this would be my answer:

  1. Create template called plant
    1. add 3 fields
      1. Title (default)
      2. Type: textarea; Title: Description (optionally use CK editor)
      3. Type: page reference; Title: Page Select (page_select); configure this to select the link to another page
  2. Create template called plant-index
    1. one field, title;
    2. configure the family settings to allow children of template plant
    3. configure the allow new pages to 1
    4. Create a new page using this template
  3. Go back to plant template and family settings, no children and plant-index for allowed parent
  4. Go to the page tree and hover over the Plant Index, then 'new' - this will give you a new plant
  5. Add your title, description and select the page you want to link to, save
  6. Repeat steps 4-5, 199 more times.
3 people like this

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  
Followers 0

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By kixe
      As described in this post ( the option 'Name Format Children' under the tab 'Family' in template settings doesn't work properly and also not as expected. I had a look inside the code and made some changes which are working properly, which offers much more options, more consistency and less code too.

      The result is the following. You have 3 Options for generating name and title, which could be combined in endless variations.
      Name is always derived from title, same like creating pages manually.
      type date: if function detects # character anywhere in the string, conversion will be: deletion of # and string will be used as format parameter for PHP date() function type field: if string is a fieldname of the parent page the value of this field will be used type string: if string doesn't fit to the 2 preceeding it will be taken as it is All parts (separated by comma) will be composed in the order of setting. You can use unlimited numbers of parts

      I made a pull request on github:

      Example screenshots

      Setting ...

      will result in

    • By Xonox
      I need to add the original image dimensions (width x height) for the images inserted in the body field, in a few data-fields. Something like:
      <a href="/site/assets/files/1092/image-1.jpg"> <img alt="" src="/site/assets/files/1092/image-1.690x0-is.jpg" width="690" data-width="1500" data-height="1000 "> </a> Where data-width and data-height are the image-1.jpg dimensions.
      I tried to do this through a file, to control the field output:
      templates/fields/post/body.php But turns out the body comes already formatted from the DB, so I can't override the image display, unless I use some cumbersome str_replaces. Even with this solution, it's impossible to achieve the desired result.
      Is there any way I can do this through a ProcessWire process?
      I know it can be done through php, reading the file's header to extract the height and width and then do a str_replace on the body string to insert the desired code. However I'm curious if it can be done in any simpler and more effective way, without having to read the files from disk and do the replaces.
    • By cosmicsafari
      Hi all,
      I am creating a page field (field of type FieldtypePage) via the API, however im still trying to find some documentation as to how I would go about setting the Selectable Pages for said field using the API.
      From what I have found it looks like it involves the use of, albeit this looks like a getter rather than a setter:
      $field->getInputfield($page) Which looks like it would make sense if I wanted to specify the selectable pages by a parent page, but what if I wanted to specify it by say a template?
    • By cosmicsafari
      Hi all,
      Just a quick question before I jump in and inevitably break the module I am working on.
      Is it possible to assign multiple field groups to a single template via the api?
      I am creating a whole bunch of fields, templates and pages on the fly at install and being able to assign multiple field groups to a template would be quite advantageous.
    • By cosmicsafari
      Hi all,
      I am working on a module which creates templates, fields & pages upon install.
      I have ran into an issue where I have a numerous fields which I would like to override their labels depending on the template they are used in.
      Is it possible to do this dynamically via API at the point where I am creating the field group and template using the API.
      The following is the code which I am using at the moment.
      foreach($templatesArray as $name => $cTemplate) { if(array_key_exists('fieldGroup',$cTemplate)) { $fg = new Fieldgroup(); $fg->name = $name . '-fg'; foreach ($cTemplate['fieldGroup'] as $field) { //possibly at this point? $fg->add($this->fields->get($field)); } $fg->save(); } $t = new Template(); $t->name = $name; $t->fieldgroup = $fg; $t->noChildren = 1; $t->setIcon($cTemplate['icon']); $t->save(); } Is this even possible?