Skip to main content
Topic: Post Fields (Read 1964 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Post Fields

Post Fields is an addon that takes the concept of custom profile fields and applies them to posts. This was a long time coming, since I developed it a few years ago, and then... forgot about it. Until now!

You can add some HTML code within the box labeled "Show Enclosed Within Text (Optional):". Special keywords can be used within the markup:
  • {INPUT} - encompasses what is entered into the field when creating/modifying a post
  • {SCRIPTURL} - URL of index.php
  • {IMAGES_URL} - URL of the currently loaded theme's images directory
  • {DEFAULT_IMAGES_URL} - URL of the default (ID #1) theme's images directory

There are five types of fields to chose from
  • Text
  • Large Text - Behaves just like text but uses a textarea.
  • Checkbox - A single checkbox acting as a simple Boolean yes/no value
  • Select Box - There's currently no limit as to the number of options (although the database can hold up to 4096 bytes of JSON encoded lists of options).
  • Radio Buttons - Behaves just like the Select Box option above, but shows an array of radio buttons to choose from.

Validating the input from a user can help to ensure that data is not used in a way you do not expect. For the two textual input types, there are certain input masks to choose from.
  • No HTML tags - a bare-bones check that should be active if no other masks apply.
  • Email - this validates e-mail addresses against the syntax in RFC 822, with the exceptions that comments and whitespace folding and dotless domain names are not supported.
  • floating-point number- A real number (that is, a number that can contain a fractional part).
  • Regular Expression - for advanced users who know how to craft a PCRE to validate against.
  • Whole number - integer



Re: Post Fields

Reply #1

Have to view this on my pc later.

Re: Post Fields

Reply #2

Wow, that's a nice addon!  8) 
sorry for my bad english

Re: Post Fields

Reply #3

Now that I have seen it, I like it.

Re: Post Fields

Reply #4

freaking awesome!! O_O
Bugs creator.
Features destroyer.
Template killer.

Re: Post Fields

Reply #5

So awesome in fact that I plan to use it as a base for other addons. And it is totally capable of that, too ;D
LiveGallery - Simple gallery addon for ElkArte