I wonder how i can insert a random value to a field when creating the a subpage via panel once to use it as a token / passphrase as well as if there’s a way to actually tell the blueprint that this field is “read-only” for people viewing the subpage inside the panel.
I haven’t seen any kind of option for both of it, i guess the random value needs to be entered using page creation hook?
You might be interested in this plugin: AutoID Plugin (create unique page ids)
Other than that, yes, a page.create hook would be the way to go.
too bad that something like
default: <?php echo str::random(...) ?>
does not work…
Even if it were possible it would not make sense because you want a value that does not change on every rendering of the blueprint, which would happen if you’d put that kind of logic in the blueprint.
1 Like