Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: davidhs on February 21, 2014, 01:53:17 PM

Title: Custom fields and filters of post
Post by: davidhs on February 21, 2014, 01:53:17 PM
Link to Mod (https://custom.simplemachines.org/mods/index.php?mod=3818)

Custom fields and filters of post

ABOUT...

Custom fields and filters of post, 2.0.3
© 2014-2020 by davidhs
© English and British English language 2017-2018 by sangham.net
© German and German informal language 2015-2018 by sangham.net
© Portuguese for Brazil and Portugal language 2015-2018 by Americano

(https://i.creativecommons.org/l/by/3.0/88x31.png) (https://creativecommons.org/licenses/by/3.0/)
This work is licensed under a Creative Commons Attribution 3.0 Unported License (https://creativecommons.org/licenses/by/3.0/).

DESCRIPTION

Allows to add different groups of custom fields to forum posts and filters for fields of posts.

A group of fields can be of type:

The available predefined filters are:

The actions to be performed on a group of custom fields are: view, add, modify, delete and move.

Furthermore other actions are possible using custom fields:

Administration panel

The administration panel has the list of groups of custom fields, which allows to add new groups, modify or delete existing groups, add, modify or delete fields in a group and define templates to display those fields in a post and in message index.

(https://lh3.googleusercontent.com/Mxi6jrSJ3RX4fWm62ok5fmGzvdYZnlKdtwBvdM2u7WWTmHPgv3J01n8vzIdB4aZt7KFJI7-uHaXPJBuIgII3_0egEXZ2hehhI6d28V9eOJO6EBpBiVw9Lgh3T6rk2jmlkd1rjw84Nw=w2400)     (https://lh3.googleusercontent.com/mCXOIC5ds8f8vHz3Tn6ncHl5E4N12r8kOp6xkAGEBwZxvHovypzbx9dn0bM1-I3PtyH0aU2YfDEfAgzx5MxIPx8Z9KQ4FhJXvdGeEIvT3CVmgRHE47GhJwHr17S6tN-5PN7KYaWYGQ=w2400)

(https://lh3.googleusercontent.com/_BIvNRB7hGK0P7jxjbPRjirQdZJoDMqxle8l6isGI7L5vQgxqA4qXhZs6ILJNbwW1kGGDYp9RuzKi6n67yKg-8WAR4QoavRv_rzRyZ-es5KCxGSWxitCU3_k9bgCpMFWkqKSG-CDPA=w2400)     (https://lh3.googleusercontent.com/RV_ORTBg97dz1yWl8HGLaErNkRM_KzDhPYFkFM7dwtC3aELjwFemAIPdDo6QOURIxX2kjqkfTJxBdQymrW1_bDKU4VV1ZNj2udqA0oItZLNKmWOFFkJWWCEpFXHrrgsVI2njV_tygg=w2400)

Viewing posts with custom fields

When viewing a complete post (on a topic, in recent posts or profile) are displayed its groups (which are enabled when post is create or modify). Groups of type "loose fields" and "record" are shown above the post body, whereas groups of type "fields with several values per member" are shown below, unless was selected "Show as group of fields of the topic" and then is displayed at the beginning and/or end of the topic. If a group has template for posts the fields are displayed according to the template, if has not are displayed with its name and content.

In lists of posts (message index, unread post and replies) are displayed groups with fields visible in message index (according to permissions). If a group has template for message index the fields are displayed according to the template, if has not are displayed with its name and content.

Modifying values on custom fields

In a topic, posts with groups of type "fields with several values per member" have buttons for the user to post new values, and modify or remove existing ones.

For all other groups ("fields loose" and "record"), at create or modify the post are displayed allowed groups. The groups of type "loose fields" always have their fields visible, whereas the groups of type "record" have a checkbox to show or hide their fields. If has been created template for quick input in a record, Quick input field is displayed after the record fields.

Moving a group of custom fields to another post

A group of fields may have to be allocated to another post, for example before removing the post where is the group.

If user has allowed to move a group, when viewing a topic that group will have buttons to move to the first post from the topic or another post (or another topic if the group is of type "fields with several values per member" and have selected "Show as group of fields of the topic").

Filter the message index

If the user has permission to filter by a field, a button is displayed in the message index to filter topics by that field.

Type of filter button depends on the type of field:

If the user can modify a field, that field may be empty and its filter is a select box or combo box, he will see an option in the list to get data with that field empty.

The filter with text button allows to search loose words (separated by spaces) and to use these modifiers:

If the filter is of type text or combo box, by default it is sought that the text is contained in the field value, whereas if the filter is of type select box list is sought that the text matches the value of the field.

Also, with a group of type "filters" can be added predefined filters.

The filters can be of the same group or different groups of fields.

Next to filters there is a button to activate the filters that have been given some value. As a result is obtained the messages index with topics whose first post matches all active filters.

Sort the message index

If the user has permission to sort by one or more fields, a select box is displayed in the message index to sort topics by one of those fields.

Show statistics

If a group of type "fields with several values per member" has a only one field and is of type select box, radio buttons or checkboxes (that is, there is a finite number of values), can be generate statistical data from the values entered in the field.

The statistical data to be displayed include:

The user sees these data only if it has permission. The message index can be sort by the summary data, if it has permission to sort by the field.

Using templates can be inserted the statistical data of any group of fields elsewhere.

Search in fields

In series SMF 2.0.x, under the option "Search" from the menu forum the search pages are located, showing the groups and their fields on which user have search permission. In series SMF 1.1.x, the option "Search posts and records" from the menu forum provides access to the search pages, showing the groups and their fields on which user have search permission.

Groups of type "loose fields", "fields with several values per member" and "filters" can be in several search pages, and each page contain several groups, with the only condition that the groups on a page must be permitted on a common set of posts. As a search result a list of posts is obtained.

For each group of type "register" with search permission have one page. As a result a list of records is obtained with the columns indicated at defining the fields.

In both cases the buttons used in each search field follow the same rule as in the filters.

Counter on the information about the member

The number of each type of record created by the member can be displayed in the information about that member.

This can be seen in several areas, such as the member's profile and the member's information about the poster of each message.

"Administration Center > Forum Maintenance > General Maintenance > Recount all forum totals and statistics" (series SMF 1.1.x) or "Administration Center > Forum Maintenance > Routine > Recount all forum totals and statistics" (series SMF 2.0.x) also recounts the number of each type of record created by members.

Also, the total number of each type of record created can be show on the statistics.

Membergroups based on the number of each type of record can be created in "Administration Center > Membergroups > Based on number of records".

Top posters on statistics

The top 10 posters of each type of records can be shown in the Statistics Center.

List on member's profile (only series SMF 2.0.x)

In the member's profile, under the section "Profile Info > Show Posts", can be show a list for each group of type "record", with posted messages by the member containing this type of group.

List on Moderation Center (only series SMF 2.0.x)

In the Moderation Center is possible to control the content posted by users in the groups of type "fields with several values per member".

For each group which has chosen to show this list will be displayed an access to the list under the section "Posts > Groups of fields on posts" and, optionally, a link under the option "Moderate" from the menu forum.

List of moderation (only series SMF 1.1.x)

Global moderators can to control the content posted by users in the groups of type "fields with several values per member".

The option "Moderate the groups of fields on posts" from the menu forum provides access to list with posted data, one for each group which has chosen to show this list.

Reattribute User Groups (only series SMF 2.0.x)

Allows reattribute to registered member groups of fields published by a guest or another registered member.

This is located in "Administration Center > Forum Maintenance > Members > Reattribute User Groups".

EXAMPLE

Suppose we have a forum where different programs that exist to create a forum are discussed and we want to have a set of file cards with the features of each program. You can write the file cards of each forum in messages or using this MOD to create the file cards.

First we create a board where you write messages that will contain file cards of forums (we call it "Records of forums").

Next we create several types of groups of custom fields in the administration panel of the MOD:
(https://lh3.googleusercontent.com/e4ZZ4Y-ICTDV1EpHF5MsrLh3rYVCF0oL1mqCP_YXytSyr3icgqSuLHUYKNxQ9SmQNkM7QiZUXVbXln9AzAUfkxGwEgtMY42W7Tm112iz3EOB62SfX-YfZVZXoYMQpxwbrJZiC1ZRpQ=w2400)

For easier data entry we add:
Code: [Select]
document.getElementById('cffp_2_column_1').onchange = function (event)
{
subject_forum();
}
document.getElementById('cffp_1_column_1').onchange = function (event)
{
subject_forum();
}
document.getElementById('cffp_1_column_2').onchange = function (event)
{
subject_forum();
}
function subject_forum()
{
document.getElementsByName('subject')[0].value = document.getElementById('cffp_2_column_1').checked ? 'CMS' : '';
if ('' != document.getElementById('cffp_1_column_1').value)
{
if ('' != document.getElementsByName('subject')[0].value)
document.getElementsByName('subject')[0].value += '. ';
document.getElementsByName('subject')[0].value += document.getElementById('cffp_1_column_1').value;

if ('' != document.getElementById('cffp_1_column_2').value)
document.getElementsByName('subject')[0].value += ' (' + document.getElementById('cffp_1_column_2').value + ')';
}
}
Quote
Regular expression:
Code: [Select]
/^\s*Name\s+(.+)\s+(Abbreviation\s+(.+)\s+)?Developer\s+(.+)\s+Current version\s+(.+)\s+Written in\s+(.+)\s+Website\s+(.+)\s*/Parameters:
Code: [Select]
1
0
2
3
4
5
6
subject_forum();
Help:
Code: [Select]
Copy the text here. Must have this format (number and type of spaces between elements does not matter):
[code]Name [NAME]
Abbreviation [ABBREVIATION] // Optional
Developer [DEVELOPER]
Current version [CURRENT_VERSION]
Written in [WRITTEN_IN]
Website [WEBSITE][/ code]
(https://lh3.googleusercontent.com/FXMsq_dMs0G1ED0tvl4SFPpfEphx8xLOczlnyjbLgidfWm1ghOEZT7Y3ELHTklUx_7tTq615zEgdf63xBDoe0S2RHkPjERQp9YxikX2fXxFkcScF2cS5G4Cl7mUL8Miz89dRdaUnoQ=w2400)

The structure is already done. We now create file cards of forums. Go to the board "Records of forums" and create a new topic. If we are to write about a content management system we enable the "CMS" field. To create the file card of a forum we enable the checkbox "Forum" and fill fields of file card with these data:
Quote
Forums

Name   Simple Machines Forum
Abbreviation   SMF
Developer   The SMF Team
Current version   2.0.7 (January 20, 2014)
Written in   PHP
Website   http://www.simplemachines.org/

Name   PHP Bulletin Board
Abbreviation   phpBB
Developer   phpBB Limited
Current version   3.0.12 (September 28, 2013)
Written in   PHP
Website   http://www.phpbb.com/

Name   vBulletin
Abbreviation   vB
Developer   Internet Brands, vBulletin Solutions
Current version   5.1.0 (March 19, 2014)
Written in   PHP
Website   http://www.vbulletin.com/

Name   Invision power board
Abbreviation   IPB, IP.Board or IP Board
Developer   Invision Power Services
Current version   3.4.6 (October 29, 2013)
Written in   PHP
Website   http://www.invisionpower.com/

Name   MyBulletinBoard
Abbreviation   MyBB
Developer   MyBB Group
Current version   1.6.14 (June 30, 2014)
Written in   PHP
Website   http://www.mybb.com/

Name   Yet another Bulletin Board
Abbreviation   YaBB
Developer   YaBB Development Team
Current version   2.5.2 (October 21, 2012)
Written in   Perl
Website   http://www.yabbforum.com/

Name   Ikonboard
Developer   Ikonboard
Current version   3.1.5a (November, 2011)
Written in   PHP, Perl
Website   http://www.ikonboard.net/

Name   JavaBB
Developer   Dalton Camargo
Current version   0.99 (May 31, 2008)
Written in   Java
Website   http://www.javabb.org/



CMS

Name   Joomla!
Developer   The Joomla Project Team
Current version   2.0.20 (April 30, 2014)
Written in   PHP
Website   http://www.joomla.org/

Name   Drupal
Developer   Dries Buytaert
Current version   7.28 (May 8, 2014)
Written in   PHP
Website   https://www.drupal.org/

Name   WordPress
Developer   WordPress Foundation
Current version   3.9.1 (May 8, 2014)
Written in   PHP
Website   https://wordpress.org/

(https://lh3.googleusercontent.com/N-VgHsUzSRfYEoQ1UPBKVzVytB1Jf_JCXN3kyCtD70RsTdJaDB2uKrjN3VjkGGPPamEU5s3S0ZtML9QhGOqBVl_ZoJ6wh813fQJJ8AOTtuYS7Ew69vCCner01kp2V57MBsCczURt9A=w2400)

This image shows the file card that we created. We also see that there are two user comments and statistical data about this forum.
(https://lh3.googleusercontent.com/770NSuGao-zV1qF9NkQVxDjLfnhqMwp-aMNuKeR0t9xe4CQIWvYFqflpC3seB74US8TsqpbMxvjAA8BzdUa5JAjfC5wyHYn1YVf7zvO0ecd9FfZKFQYa8A6TGoHP2-iG0beBlQC0iA=w2400)

Once you have created all the file cards in the index of board "Records of forums" you see some fields next to the post subject and filters above the listing.
(https://lh3.googleusercontent.com/xUUbBVyT16AqWS22x-B0ewh2Z-783Pl2SsdDf6KYhZLyraccc_YZlHhVfemXbhY-bxXtKl4VQG_RNThOyysf-QlTlfXxeKE39jzGwzOPvzGRdSdxS26_Lq2Eywm-c_FnPPkcDp-rsQ=w2400)

To search posts go to "Search > Search posts", where groups and fields with permission to search are displayed.
(https://lh3.googleusercontent.com/6V0TB1L-T8w6cnUobCK0iNfN08u88InZTutV3vB6l5l8Qp1yjZK-fMtfu0eBIOPyYD30pn_MNI_E4dYebQ7mZcxGhMsnsZKxhGx5zpzzozWYElFSLj20FOojmsG4lg1srRI8SsWHOA=w2400)

To search file cards of forums go to menu "Search > Search forums", where the fields on which you can filter the list of file cards of forums are displayed.
(https://lh3.googleusercontent.com/76vnYB2c-5Qi5lPBwU3WMruv6hl86VoT0FrKVe3WVxjwdPrehWgwde-xxyerC_TfkxHSdCCHczUx5Unjw3C-nMomSjoTSja9gtuVEMNzwRK4xZNNBcqizkwYbZMU1a190-QVgL67bw=w2400)

In the member's profile can be shown the groups type "Forum" posted by the user.
(https://lh3.googleusercontent.com/GwsA7v2XEKWayxNcj1D9zQmVaYnwLJMrtjBO4djVMNVSHYWvmDY3K1rwHib6ocKbfJ1YBMn78kU4mBhjlLxBdXUsGNbCBcSAKkvIf5vStfPtjP9xVjIxRNyc8p7VMfIfOK_CeUEnzA=w2400)

In the Moderation Center can be controlled the comments posted by users.
(https://lh3.googleusercontent.com/wDfN7CpMAz33_OpmHklLMR38LgPg_4Al4n0lXBwpYO5-0teGcnVNh3NSaZ7qX6HiaAhpL902ln9bceltPTIF0fMeSii2hIFZGF32KR_ZZxwppuTChsCVvkjimp32-e4tAGL4OV_K6w=w2400)

In Statistics Center can be shown the top 10 posters of records type "Forum".
(https://lh3.googleusercontent.com/5MGvg02XZwqY3xlIIlsjHojzva-40GuL9gCO6ZZhoLGed53kxK1M15jDCFWIY2vCyuK8sqxcAH5sXS3mOUyhHDEmCdCcIRjZ6XV0HpAWUu8YYimTxzbC9gPFYnQGs3jrqR_Rx1MrXw=w2400)

SMF COMPATIBILITY


Support for:

There may be conflict with SEF MODs, which create friendly URLs.

LANGUAGES


DOWNLOAD

Link to MOD (https://custom.simplemachines.org/mods/index.php?mod=3818)

MANUAL INSTALLATION

See https://wiki.simplemachines.org/smf/Manual_installation_of_mods

COLLABORATE WITH THIS MOD

This work is licensed under a Creative Commons Attribution 3.0 Unported License (https://creativecommons.org/licenses/by/3.0/).

You are free to share and adapt this MOD. Also you can collaborate in different ways:

CHANGE LOG

Code: [Select]
Legend:   ! Fixed   + Added   - Removed   * Changed   @ Note

2.0.3   2020-04-27
------------------
! The help text is still too long and generates an error on installation. It is divided in several files.
! Since version 1.1 the non-UTF-8 language text is too long and generates an error on installation. It is divided in several files.

2.0.2   2020-03-08
------------------
! SMF 2.0.x: The Quick Search of the Administration Center look for in settings variables of MOD.
+ SMF compatibility: 2.0.16 to 2.0.17.

2.0.1   2019-01-09
------------------
! Columns with no default value in MySQL must be in the INSERT clause.

2.0     2018-11-15
------------------
! SMF 1.1.x: Error in PHP code.
! SMF 1.1.x: Slashes are stripped from fields in filters and searches.
! SMF 1.1.x: Theme of the generic form of displaying lists.
! SMF 2.0.x: Columns type "text" can not have a default value in MySQL.
! When posts are reattribute to another member, the number of each type of record created by the member is recount only if number of posts is recount.
! Calculation of the number of each type of record created by members.
! Registered member data are displayed instead of poster data.
* If the number of each type of record created by the member is 0 can be hidden.
+ Fields in administration panel to indicate the labels of total and average number of each type of record created.
* The filter with text button allows to use more modifiers: - (do not search for a text), OR (search for one or another text).
+ The average number of each type of record created can be show on the statistics.
+ Show warning messages when data published by the members can be deleted because of changes in settings of groups.
+ Membergroups based on the number of each type of record, in "Administration Center > Membergroups > Based on number of records".
+ Reattribute User Groups, in "Administration Center > Forum Maintenance > Members > Reattribute User Groups".
@ "Administration Center > Forum Maintenance > Members > Reattribute User Posts" section does not exists in SMF 1.1.x and "Reattribute User Groups" section is not added.
+ Actions of Administration panel are logged to Administration log.
@ Administration log does not exists in SMF 1.1.x.
+ Moderation actions are logged to Moderation log.
+ Languages: New language string in german, german-utf8, german_informal, german_informal-utf8, thanks to sangham.net.
+ Languages: New language string in portuguese_brazilian, portuguese_brazilian-utf8, brazilian, brazilian-utf8, portuguese_pt, portuguese_pt-utf8, thanks to Americano.
! Languages: Some language string in english, english-utf8, english_british, english_british-utf8, thanks to sangham.net.

1.5     2017-11-25
------------------
@ There may be conflict with SEF MODs, which create friendly URLs.
+ The number of each type of record created by the member is shown on the information about the member in personal messages.
+ Statistics in groups of type "fields with several values per member": Sum of numeric values.
+ Predefined filters: Types of record.
+ Field in administration panel to indicate if is allowed selecting the operator with which apply the predefined filter.
+ SMF compatibility: 2.0.12 to 2.0.15.
+ Languages: New language string in german, german-utf8, german_informal, german_informal-utf8, thanks to sangham.net.
! Languages: Some language string in english, english-utf8, english_british, english_british-utf8, thanks to sangham.net.

1.4     2015-10-30
------------------
+ Field in administration panel to show, on the statistics, the top 10 posters of each type of records.
+ The total number of each type of record created can be show on the statistics.
+ SMF compatibility: 2.0.11.
+ Languages: New language string in portuguese_brazilian, portuguese_brazilian-utf8, brazilian, brazilian-utf8, portuguese_pt, portuguese_pt-utf8, thanks to Americano.
+ Languages: german, german-utf8, german_informal, german_informal-utf8, thanks to sangham.net.
- SMF 2.0.x: Languages: brazilian, brazilian-utf8, spanish, spanish-utf8 (these are not used).

1.3.2   2015-06-19
------------------
! Errors in source code.

1.3.1   2015-06-13
------------------
! SMF 2.0.x: Error in SQL code.
! Use HTML entities in ISO-8859-1 languages.
! Since version 1.2 the help text is too long and generates an error on installation. It is divided in two operations.

1.3     2015-06-07
------------------
! Error in PHP code.
! Navigation in the message index when a predefined filter is used.
! Delete statistics when topics or messages are deleted.
! When moving a group of type "fields loose" or "record" to another message, the poster of the message is assigned to group.
! SMF 2.0.x: When assigning a message to another member, the groups of type "fields loose" or "record" of that message are assigned to member.
+ Field in administration panel to show, on the information about the member, the number of each type of record created by the member.
+ "Administration Center > Forum Maintenance > Routine > Recount all forum totals and statistics" also recounts the number of each type of record created by members.
+ SMF compatibility: 1.1.21 and 2.0.10.
+ Languages: portuguese_brazilian, portuguese_brazilian-utf8, brazilian, brazilian-utf8, portuguese_pt, portuguese_pt-utf8, thanks to Americano.

1.2     2014-12-16
------------------
! Error in JavaScript code.
! Errors in PHP code.
! SMF 2.0.x: allowedTo('approve_posts') must be used instead of $context['can_approve_posts'].
! Entered values by the user in text box of a combo box with multiple selection can not be duplicated.
! Column width with only one field, in lists of moderation.
! Fields of type select box, radio buttons or checkboxes must have options.
! Empty option of select box must have the label "All" only in filters.
+ SMF 1.1.x: Implemented a generic form of displaying lists, similar to SMF 2.0.x.
+ SMF 1.1.x: Implemented database functions, similar to SMF 2.0.x.
+ Field in administration panel to indicate if quick input field will be show when data are modified.
+ Field in administration panel to add a long description in a custom field.
+ Field in administration panel to add a description in a search field.
+ Field in administration panel to add a long description in a search field.
+ Field in administration panel to indicate if creation date will be show on posted records.
+ Field in administration panel to indicate if last modification date will be show on modified records.
+ Field in administration panel to indicate if only one value per member in groups of type "fields with several values per member" is allowed.
+ Field in administration panel to indicate if is allowed selecting the operator with which apply the filter.
+ Field in administration panel to indicate if one or more filters are hidden under a tag.
+ Field in administration panel to show in filter only those items that used in the current board, if filter is a field with list of items.
+ Fields in administration panel to show statistics in groups of type "fields with several values per member".
+ Permission in administration panel to indicate if a field is used to sort the message index.
+ PHP function in "Show enclosed within text" to display statistics for the group of a message.
+ PHP function in templates to display statistics for the group of a message.
* Reorganization of the fields in the administration panel.
* The filter with text button allows to search loose words (separated by spaces) and/or literal phases (enclosed in double quotes).
* The dates of create/modify of a group (left) and actions on a group (right) are shown on the same line.
* The date of create of groups of type "fields with several values per member" are also displayed on WAP.
* When display data posted by users in the groups of type "fields with several values per member", the background color alternates for readability.
* Forum parameter "Number of posts per page in a topic page" is used in lists of moderation.
* Forum parameter "Number of search results per page" is used in lists of search in custom fields.
* If users can not search for posts and topics then they can not search in custom fields.
* The areas with data of groups of type "fields with several values per member" can be displayed unexpanded, expanded or forever expanded.
* The field "Filter the message index" in administration panel is replaced by permissions.
+ SMF compatibility: 1.1 to 1.1.20 and 2.0.9.
@ SMF 1.1.x: List for each group of type "record" are not show on member's profile.
@ SMF 1.1.x: There is not Moderation Center, but the global moderators can to control the content posted by users in the groups of type "fields with several values per member".

1.1     2014-07-17
------------------
! In WYSIWYG mode, if the user add a record and the post body is empty, the system did not write a period (".") on it.
! If a field with radio buttons or checkboxes is defined as "Not empty value" and is left blank, no error was displayed.
! Each posted data on groups of type "fields with several values per member" must be moved individually, not all from the message at once.
! Languages: english, english-utf8.
+ Support for print topic.
+ Field in administration panel to add BBC before the record when entering data.
+ Field in administration panel to add JavaScript code when a group of fields is created or modified.
+ Field in administration panel to add HTML before and after the input button and the output text in a custom field.
+ Field in administration panel to show expanded the most recent posted data in groups of type "fields with several values per member".
+ Field in administration panel to show most recent posted data at the top in groups of type "fields with several values per member".
+ Field in administration panel to indicate the maximum height of the area with posted data in groups of type "fields with several values per member".
+ Field in administration panel to show, in the member's profile, a list for each group of type "record", with posted messages by the member containing this type of group.
+ Field in administration panel to control, in the Moderation Center, the content posted by users in the groups of type "fields with several values per member".
* Field in administration panel to indicate if a group will be show on the first post of topic is selected by default.
* Field in administration panel to indicate if a group will be show on the replies of topic is selected by default.
+ Quick input field to fill the fields when a record is created.
+ Variable in "Show enclosed within text" to insert ID of the current message.
+ Variable in "Show enclosed within text" to insert field name in database of any custom field.
+ PHP function in "Show enclosed within text" to display a group of a message like in a message or like on the message index.
+ Variable in templates to insert ID of the current message.
+ Variable in templates to insert field name in database of any custom field.
+ PHP function in templates to display a group of a message like in a message or like on the message index.
+ In administration panel is shown each group and field ID.
+ Text field to add multiple options at one time when a custom field with options is created or modified in administration panel.
* Big multi-line text input fields are wider.
* Submit buttons have shortcut key to get focus.
+ SMF compatibility: 2.0.8.

1.0     2014-02-20
------------------
@ This work is licensed under a Creative Commons Attribution 3.0 Unported License https://creativecommons.org/licenses/by/3.0/
+ Groups of custom fields loose in forum posts, to provide extra information.
+ Groups of custom fields in forum posts, called records, that represents an independent entity of the post.
+ Groups of custom fields in forum posts, with several values per member. They may be seen as belonging to the post or to the topic.
+ Groups of predefined filters that can be used on topics and posts.
+ Predefined filters: Boards, Subject, Start of the subject, First character of the subject, Date of topic / Date posted, Date of last reply / Date posted, Posted by, Topic with new posts / New, Sticky, Locked, Replies, Poll.
+ Actions to be performed on a group of custom fields: view, add, modify, delete, move.
+ Filter the message index using custom fields.
+ Search in custom fields of posts, getting a list of posts.
+ Search in custom fields of records, getting a list of records.
+ Support for WAP.
+ Administration panel.
+ SMF compatibility: 2.0 to 2.0.7.
+ Languages: english, english-utf8, english_british, english_british-utf8, spanish, spanish-utf8, spanish_es, spanish_es-utf8, spanish_latin, spanish_latin-utf8.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: kamili34 on February 21, 2014, 03:35:11 PM
Got error on this

Code: [Select]
Znajdź: [Zaznacz]


'unapproved_posts' => $row['unapproved_posts'],
);

Dodaj Po: [Zaznacz]


// BEGIN MOD CustomFieldFilterPost
$id_msg_array[] = $context['topics'][$row['id_topic']]['first_post']['id'];
$context['cffp']['data_msg_topic'][$row['id_first_msg']] = array(
'sticky' => $context['topics'][$row['id_topic']]['is_sticky'] ? 1 : 0,
'locked' => $context['topics'][$row['id_topic']]['is_locked'] ? 1 : 0,
'id_msg' => $context['topics'][$row['id_topic']]['first_post']['id'],
'first_msg' => 1,
'subject' => $context['topics'][$row['id_topic']]['subject'],
);
// END MOD CustomFieldFilterPost



Tried manually edited but when do this cant brose boards. :/
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on February 21, 2014, 04:16:29 PM
Other mod (i.e. mod X) modified these lines and my mod can not install here. :(

Your file have this on line 598
Code: [Select]
'unapproved_posts' => $row['unapproved_posts'],
'description' => $row['description'],

);
and my mod expects this
Code: [Select]
'unapproved_posts' => $row['unapproved_posts'],
);

If you can,
1. uninstall mod X,
2. install my mod and
3. install mod X.

If you can not uninstall mod X or you do not know which it is, you can
1. install my mod with this error and
2. modify your MessageIndex.php, line 598,
after
Code: [Select]
'unapproved_posts' => $row['unapproved_posts'],
'description' => $row['description'],

);
write
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
$id_msg_array[] = $context['topics'][$row['id_topic']]['first_post']['id'];
$context['cffp']['data_msg_topic'][$row['id_first_msg']] = array(
'sticky' => $context['topics'][$row['id_topic']]['is_sticky'] ? 1 : 0,
'locked' => $context['topics'][$row['id_topic']]['is_locked'] ? 1 : 0,
'id_msg' => $context['topics'][$row['id_topic']]['first_post']['id'],
'first_msg' => 1,
'subject' => $context['topics'][$row['id_topic']]['subject'],
);
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: kamili34 on February 21, 2014, 04:24:37 PM
Works. I put it in wrong place after 'unapproved_posts' => $row['unapproved_posts']. Now with your advice is ok. :) Thanks
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: sardonick007 on February 28, 2014, 09:52:25 PM
This is SO brilliant!
One question. When using "record" option, the mod puts a . (period) in the body when there is no body. However, if WYSIWYG is toggled ON by default, this does not work. Is there a way for the . to be entered while the WYSIWYG is toggled on?

This mod is replacing all my forms and multiple pages into one page of selectable forms!!!! AWESOME!
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: sardonick007 on February 28, 2014, 11:39:32 PM
Also, when I use the "print" button on the post, only the post body prints. None of the fields do. Is there a workaround for this? I'm really digging into this mod, it's better than I imagined with only a few little bumps.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on March 01, 2014, 06:48:11 AM
One question. When using "record" option, the mod puts a . (period) in the body when there is no body. However, if WYSIWYG is toggled ON by default, this does not work. Is there a way for the . to be entered while the WYSIWYG is toggled on?
I do not use the WYSIWYG mode and did not think about this. :( I will see.

Now, You must put a ".".

Also, when I use the "print" button on the post, only the post body prints. None of the fields do. Is there a workaround for this? I'm really digging into this mod, it's better than I imagined with only a few little bumps.
Same. I do not use the print option and did not think about this. :( I will see.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: sardonick007 on March 01, 2014, 01:16:00 PM
One question. When using "record" option, the mod puts a . (period) in the body when there is no body. However, if WYSIWYG is toggled ON by default, this does not work. Is there a way for the . to be entered while the WYSIWYG is toggled on?
I do not use the WYSIWYG mode and did not think about this. :( I will see.

Now, You must put a ".".

Also, when I use the "print" button on the post, only the post body prints. None of the fields do. Is there a workaround for this? I'm really digging into this mod, it's better than I imagined with only a few little bumps.
Same. I do not use the print option and did not think about this. :( I will see.

Thank you for your response! I appreciate the effort. Even now it's an excellent script and very useful to me.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: sardonick007 on March 01, 2014, 03:58:16 PM
As I'm using this more now, I also wanted to make sure you knew that you cannot view the information in Tapatalk, only the subject and body. For those using Tapatalk to view the boards they would not see the information in the records.

So for me, the current observations are:
Does not show up on print or when using "send topic" (only subject and body sends)
Does not automatically put a . (period) in the subject when using "Record type" if the body is toggled to WYSIWYG
Does not show information if using Tapatalk

I hope this is helpful because this is such a useful mod for my business.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: margarett on March 01, 2014, 04:51:32 PM
It is actually "normal" that custom information isn't displayed in Tapatalk. They use a custom set of Sources files, meaning that the custom edits to SMF's own files aren't displayed in mobiles. That's not an issue with this mod, more with the way Tapatalk was built...
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: sardonick007 on March 01, 2014, 04:54:53 PM
It is actually "normal" that custom information isn't displayed in Tapatalk. They use a custom set of Sources files, meaning that the custom edits to SMF's own files aren't displayed in mobiles. That's not an issue with this mod, more with the way Tapatalk was built...

Yea, I see that. It's not that big a deal really, since speeds are good enough to use the phone/tablet browser. That was just one of the things I experienced and figured I'd mention. It's really the one thing on my list that is not very important, maybe it'd be nice, but it's not a deal breaker.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on March 02, 2014, 06:49:23 AM
This MOD works in WAP mode but Tapatalk.... I do not know this :(

Is this Tapatalk? http://tapatalk.com/activate_tapatalk.php?plugin=smf
I do not found in SMF MODs section.

I will see.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: sardonick007 on March 02, 2014, 12:37:56 PM
Yes, that's it. However the mod works fine in WAP mode as you said. Tapatalk is just a bonus, nothing major. Printing and seeing the content in announcements, send topic,  and emails would be more important than Tapatalk since mobile web is easy to use and works fine.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: LadyAngel on March 17, 2014, 07:48:06 AM
Thank you so much for this mod - I think it's just become my new favourite!  ;D
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: sardonick007 on April 03, 2014, 04:51:19 PM
One question. When using "record" option, the mod puts a . (period) in the body when there is no body. However, if WYSIWYG is toggled ON by default, this does not work. Is there a way for the . to be entered while the WYSIWYG is toggled on?
I do not use the WYSIWYG mode and did not think about this. :( I will see.

Now, You must put a ".".

Also, when I use the "print" button on the post, only the post body prints. None of the fields do. Is there a workaround for this? I'm really digging into this mod, it's better than I imagined with only a few little bumps.
Same. I do not use the print option and did not think about this. :( I will see.

Have you had any luck with these items? Is there a plan for a future update that might address this? Thanks again for a great mod.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: LadyAngel on April 03, 2014, 05:19:48 PM
I love this mod, I really do, but there's one thing I would change - it would be faster and more efficient if the admin could mass add multiple options at once, say in a text field, rather than having to add the options one by one.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on April 04, 2014, 06:49:25 AM
it would be faster and more efficient if the admin could mass add multiple options at once, say in a text field, rather than having to add the options one by one.
Where? When a field with options is created (i.e radio/check buttom)?
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: LadyAngel on April 04, 2014, 06:55:16 AM
Yes, that kind of thing. Instead of having to input each option at a time, I'd like to be able to paste a column of options, it would just save time. :)
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on April 04, 2014, 08:26:03 AM
I will see on next update. :)
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: LadyAngel on April 04, 2014, 09:19:00 AM
I will see on next update. :)
Lovely, thanks for considering it :)
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: Galaxy Computers on April 20, 2014, 04:39:25 PM
Will this mod do the following:
Topic will be my (Item)
A field for (Price)
A field for (Discription)
A Drop down menu for (City & State)

What I am doing is almost like a online Classified.

Thanks
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on April 22, 2014, 05:47:44 PM
Will this mod do the following:
Topic will be my (Item)
A field for (Price)
A field for (Discription)
A Drop down menu for (City & State)

What I am doing is almost like a online Classified.

Thanks
Yes, of course :)

You can to do this:

1. Create a group of fields
Quote
Name: Item
Type: Record
Boards: Select board where you will create items
Show in sticky topics: No (I suppouse)
Show in locked topics: No (I suppouse)
Show on the first post of topic: Yes
Show on the replies of topic: No
Search page: Search items
Permissions: For example...
- Administrator, Global moderador, Local moderador and Owner of post: check all
- User: View, Search
- Guest: View

2. Create fields of group "Item"
Quote
Name: Price
Order: 1
Show enclosed within text: Write your currency symbol, for example: ${INPUT} (in next update I will add more settings for this)
Show on message index: Yes
Filter the message index: No
Show on records list: Yes, in a column with only this field
Type: Text
Maximum lenght of data: 0
Input mask: [0-9]+(\.[0-9][0-9]?)?   (You will can write 9999, 9999.9, 9999.99; I am not test this regular expression)
Permissions: For example... check all, except Search
Quote
Name: Description
Order: 2
Show on message index: Yes
Filter the message index: Yes
Show on records list: Yes, in a column with only this field
Type: Large text
Maximum lenght of data: 0
Permissions: For example... check all
Quote
Name: State
Order: 3
Show on message index: Yes
Filter the message index: Yes
Show on records list: Yes, in a column with only this field
Type: You have two options:

1. If states are countries of world
Type: Combo box
Options: You can add some states, but is not necessary

2. If states are states of USA
Type: Select box
Options: Add 50 states of USA

Maximum lenght of data: 0
Permissions: For example... check all
Quote
Name: City
Order: 4
Show on message index: Yes
Filter the message index: Yes
Show on records list: Yes, in a column with only this field
Type: Combo box
Maximum lenght of data: 0
Options: You can add some cities, but is not necessary
Permissions: For example... check all
Note: City and State buttons are not related.

3. Modify group Item and select column and order in "Sort search results by"

These are the basic settings. You can create templates for group on post and group on message index.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: Galaxy Computers on April 22, 2014, 08:30:07 PM
Will this mod do the following:
Topic will be my (Item)
A field for (Price)
A field for (Discription)
A Drop down menu for (City & State)

What I am doing is almost like a online Classified.

Thanks
Yes, of course :)

You can to do this:

1. Create a group of fields
Quote
Name: Item
Type: Record
Boards: Select board where you will create items
Show in sticky topics: No (I suppouse)
Show in locked topics: No (I suppouse)
Show on the first post of topic: Yes
Show on the replies of topic: No
Search page: Search items
Permissions: For example...
- Administrator, Global moderador, Local moderador and Owner of post: check all
- User: View, Search
- Guest: View

2. Create fields of group "Item"
Quote
Name: Price
Order: 1
Show enclosed within text: Write your currency symbol, for example: ${INPUT} (in next update I will add more settings for this)
Show on message index: Yes
Filter the message index: No
Show on records list: Yes, in a column with only this field
Type: Text
Maximum lenght of data: 0
Input mask: [0-9]+(\.[0-9][0-9]?)?   (You will can write 9999, 9999.9, 9999.99; I am not test this regular expression)
Permissions: For example... check all, except Search
Quote
Name: Description
Order: 2
Show on message index: Yes
Filter the message index: Yes
Show on records list: Yes, in a column with only this field
Type: Large text
Maximum lenght of data: 0
Permissions: For example... check all
Quote
Name: State
Order: 3
Show on message index: Yes
Filter the message index: Yes
Show on records list: Yes, in a column with only this field
Type: You have two options:

1. If states are countries of world
Type: Combo box
Options: You can add some states, but is not necessary

2. If states are states of USA
Type: Select box
Options: Add 50 states of USA

Maximum lenght of data: 0
Permissions: For example... check all
Quote
Name: City
Order: 4
Show on message index: Yes
Filter the message index: Yes
Show on records list: Yes, in a column with only this field
Type: Combo box
Maximum lenght of data: 0
Options: You can add some cities, but is not necessary
Permissions: For example... check all
Note: City and State buttons are not related.

3. Modify group Item and select column and order in "Sort search results by"

These are the basic settings. You can create templates for group on post and group on message index.

I am also will be needing a custom field for at least 3 references. How can able add that in too?
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on April 23, 2014, 06:53:19 AM
I am also will be needing a custom field for at least 3 references. How can able add that in too?
Are there 3 text fields?

You can add 3 text fields like Price (without "Show enclosed within text" and with other "Input mask").
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: Galaxy Computers on April 23, 2014, 09:27:51 AM
I am also will be needing a custom field for at least 3 references. How can able add that in too?
Are there 3 text fields?

You can add 3 text fields like Price (without "Show enclosed within text" and with other "Input mask").

They will be 3 text field for references.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: Galaxy Computers on April 29, 2014, 09:43:08 PM
I am also will be needing a custom field for at least 3 references. How can able add that in too?
Are there 3 text fields?

You can add 3 text fields like Price (without "Show enclosed within text" and with other "Input mask").

They will be 3 text field for references.

Plus I also need a field where they can upload a image of the item (Optional) into the post.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on April 30, 2014, 05:05:40 AM
I also need a field where they can upload a image of the item (Optional) into the post.
This not exists. If you want:

- Upload images to server, you can attach images like in other message.

- Show external images, you can create a text field for input image url and write this in Show enclosed with text:
Code: [Select]
<img src="{INPUT}">
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: ralph622 on May 03, 2014, 04:11:32 AM
Hi. This modification sounds awesome, but i ve got a problem after manual installation (AUTO doesnt work).
SMF 2.0.7. All files are uploaded and changed, i cant execute code-2.0.php and database-2.0.php. i uploaded these files in my root directory where is SMF and execute from browser.
errors in db
code-2.0.php :
Code: [Select]
Table 'smf_forum.smf_cffp_settings_groups' doesn't exist
File: /home/blabla/domains/[u]blabla[/u]/public_html/smf2/Sources/Themes-CustomFieldFilterPost.php
Linia: 25

database-2.0.php tells me the same problem...

Now i cant view my smf, error is :
Code: [Select]
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
WHERE active = 1
ORDER BY group_order ASC' at line 2
Plik: /home/blablabla/domains/blablabla/public_html/smf2/Sources/Themes-CustomFieldFilterPost.php
Linia: 41

Anyone can help me? ;)
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 03, 2014, 06:21:49 AM
i ve got a problem after manual installation (AUTO doesnt work).
SMF 2.0.7. All files are uploaded and changed, i cant execute code-2.0.php and database-2.0.php. i uploaded these files in my root directory where is SMF and execute from browser.

Try to do these steps:

1. Extract code-2.0.php and database-2.0.php files from MOD package.

2. Open code-2.0.php in a text editor and add this in line 12
Code: [Select]
include_once("Settings.php");
3. Upload these files to your forum directory.

4. Visit these pages in your browser
Quote
www.your-forum/code-2.0.php
www.your-forum/database-2.0.php

Perhaps you see warning like this, you do not worry!
Quote
Strict Standards: strftime() [function.strftime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Paris' for '2.0/DST' instead in ...\Subs.php on line 810

Strict Standards: strftime() [function.strftime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Paris' for '2.0/DST' instead in ...\Sources\Subs.php on line 813

Strict Standards: strftime() [function.strftime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Paris' for '2.0/DST' instead in ...\Sources\Subs.php on line 821
Else, you see an empty page.

5. Settings are installed and database is update. :)
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: ralph622 on May 03, 2014, 06:41:23 AM
Code: [Select]
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
WHERE active = 1
ORDER BY group_order ASC' at line 2
Plik: /home/blabla/domains/blabla/public_html/smf2/Sources/Themes-CustomFieldFilterPost.php
Linia: 41
hmmm... added all to 12 line. db error after executing. forum is still off. it turns on when i delete themes-customfieldpost.php from sources dir.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 03, 2014, 07:11:17 AM
1. About settings, execute this on your database (use phpMyAdmin, i.e)
Code: [Select]
SELECT *
FROM `smf_settings`
WHERE `variable` LIKE 'integrate_%'
and write here the output

2. About tables, have these tables in your database?
Quote
smf_cffp_fields
smf_cffp_settings_fields
smf_cffp_settings_groups
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: ralph622 on May 03, 2014, 07:25:54 AM
Code: [Select]
<?php
/**
 * Export to PHP Array plugin for PHPMyAdmin
 * @version 0.2b
 */

//
// Database `rafaell_clubstage`
//

// `rafaell_clubstage`.`smf_settings`
$smf_settings = array(
  array(
'variable' => 'integrate_actions','value' => 'cffp_actions,simtopics_actions'),
  array(
'variable' => 'integrate_admin_areas','value' => 'cffp_admin_areas,simtopics_admin_areas'),
  array(
'variable' => 'integrate_admin_include','value' => '$sourcedir/Admin-CustomFieldFilterPost.php,$sourcedir/Admin-SimTopics.php'),
  array(
'variable' => 'integrate_load_permissions','value' => 'simtopics_permissions'),
  array(
'variable' => 'integrate_load_theme','value' => 'cffp_load_theme,simtopics_load_theme'),
  array(
'variable' => 'integrate_menu_buttons','value' => 'cffp_menu_buttons,simtopics_menu_buttons'),
  array(
'variable' => 'integrate_modify_modifications','value' => 'cffp_modify_modifications,simtopics_modifications'),
  array(
'variable' => 'integrate_pre_include','value' => '$sourcedir/Subs-CustomFieldFilterPost.php,$sourcedir/Subs-SimTopics.php'),
  array(
'variable' => 'integrate_theme_include','value' => '$sourcedir/Themes-CustomFieldFilterPost.php')
);

There is one table smf_cffp_fields

maybe i should check this mod on a clean SMF copy?
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 03, 2014, 07:51:04 AM
Code: [Select]
<?php
/**
 * Export to PHP Array plugin for PHPMyAdmin
 * @version 0.2b
 */

//
// Database `rafaell_clubstage`
//

// `rafaell_clubstage`.`smf_settings`
$smf_settings = array(
  array(
'variable' => 'integrate_actions','value' => 'cffp_actions,simtopics_actions'),
  array(
'variable' => 'integrate_admin_areas','value' => 'cffp_admin_areas,simtopics_admin_areas'),
  array(
'variable' => 'integrate_admin_include','value' => '$sourcedir/Admin-CustomFieldFilterPost.php,$sourcedir/Admin-SimTopics.php'),
  array(
'variable' => 'integrate_load_permissions','value' => 'simtopics_permissions'),
  array(
'variable' => 'integrate_load_theme','value' => 'cffp_load_theme,simtopics_load_theme'),
  array(
'variable' => 'integrate_menu_buttons','value' => 'cffp_menu_buttons,simtopics_menu_buttons'),
  array(
'variable' => 'integrate_modify_modifications','value' => 'cffp_modify_modifications,simtopics_modifications'),
  array(
'variable' => 'integrate_pre_include','value' => '$sourcedir/Subs-CustomFieldFilterPost.php,$sourcedir/Subs-SimTopics.php'),
  array(
'variable' => 'integrate_theme_include','value' => '$sourcedir/Themes-CustomFieldFilterPost.php')
);
Settings was correct instaled from code-2.0.php. :)

There is one table smf_cffp_fields
When you executed database-2.0.php should have created three tables, not just one. :(
You delete table smf_cffp_fields and create three. Excecute this SQL
Code: [Select]
CREATE TABLE smf_cffp_fields (
  id_cffp int(10) NOT NULL auto_increment,
  id_msg int(10) NOT NULL default '0',
  id_group int(10) NOT NULL default '0',
  id_member int(10) NOT NULL default '0',
  poster_name varchar(255) NOT NULL default '',
  poster_email varchar(255) NOT NULL default '',
  poster_ip varchar(255) NOT NULL default '',
  poster_time int(10) NOT NULL default '0',
  modified_name varchar(255) NOT NULL default '',
  modified_time int(10) NOT NULL default '0',
  PRIMARY KEY  (id_cffp)
);

CREATE TABLE smf_cffp_settings_fields (
  id_field int(10) NOT NULL auto_increment,
  id_group int(10) NOT NULL default '0',
  id_column int(10) NOT NULL default '0',
  name varchar(40) NOT NULL default '',
  field_desc varchar(255) NOT NULL default '',
  description varchar(255) NOT NULL default '',
  field_order tinyint(3) NOT NULL default '0',
  `type` varchar(8) NOT NULL default 'text',
  type_filter varchar(15) NOT NULL default 'text',
  length smallint(5) NOT NULL default '255',
  options text NOT NULL,
  options_text text NOT NULL,
  mask varchar(255) NOT NULL default '',
  bbc tinyint(3) NOT NULL default '0',
  default_value text NOT NULL,
  enclose_type varchar(4) NOT NULL default 'html',
  enclose_text text NOT NULL,
  show_message_index tinyint(3) NOT NULL default '0',
  filter_message_index tinyint(3) NOT NULL default '0',
  show_record_list_type varchar(5) NOT NULL default 'no',
  show_record_list_width varchar(7) NOT NULL default '',
  show_record_list_name varchar(40) NOT NULL default '',
  not_empty_value tinyint(3) NOT NULL default '0',
  unique_value tinyint(3) NOT NULL default '0',
  subset varchar(40) NOT NULL default '',
  permissions text NOT NULL,
  active tinyint(3) NOT NULL default '1',
  PRIMARY KEY  (id_field)
);
CREATE TABLE smf_cffp_settings_groups (
  id_group int(10) NOT NULL auto_increment,
  name varchar(40) NOT NULL default '',
  description varchar(255) NOT NULL default '',
  group_order tinyint(3) NOT NULL default '0',
  text_input text NOT NULL,
  text_output text NOT NULL,
  boards text NOT NULL,
  child_boards tinyint(3) default '0',
  `type` varchar(10) NOT NULL default 'fields',
  show_group_name_message_index tinyint(3) NOT NULL default '0',
  show_group_name_filter tinyint(3) NOT NULL default '0',
  show_group_name_search tinyint(3) NOT NULL default '0',
  show_fields_name tinyint(3) NOT NULL default '1',
  show_fields_set tinyint(3) NOT NULL default '0',
  show_empty_fields_post tinyint(3) NOT NULL default '0',
  show_empty_fields_message_index tinyint(3) NOT NULL default '0',
  show_actions_as varchar(10) NOT NULL default 'icon_text',
  show_member_expanded tinyint(3) NOT NULL default '0',
  show_member_expanded_data tinyint(3) NOT NULL default '0',
  show_member_expanded_new tinyint(3) NOT NULL default '0',
  show_sticky tinyint(3) default NULL,
  show_locked tinyint(3) default NULL,
  show_first_post_topic tinyint(3) NOT NULL default '0',
  show_replies_topic tinyint(3) NOT NULL default '0',
  no_show_with_subject_prefix text NOT NULL,
  show_in_topic varchar(11) NOT NULL default 'no',
  show_filters text NOT NULL,
  search_page_name text NOT NULL,
  search_page_order_by text NOT NULL,
  permissions text NOT NULL,
  active tinyint(3) NOT NULL default '1',
  template_type varchar(4) NOT NULL default 'html',
  template_text text NOT NULL,
  template_message_index_type varchar(4) NOT NULL default 'html',
  template_message_index_text text NOT NULL,
  PRIMARY KEY  (id_group)
);


I expect your forum works!

maybe i should check this mod on a clean SMF copy?
If you can to do this, yes.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: ralph622 on May 03, 2014, 07:58:53 AM
Quote
I expect your forum works!
table deleted, sql executed and it works !
Everything is okay now. I see options, forum works, thanks david :) I am grateful to you for help :)

Edit :
my happiness didnt last too long... after a making new group i see this error :
Code: [Select]
Field 'template_text' doesn't have a default value
Plik: /home/blabla/domains/blabla/public_html/smf2/Sources/Admin-CustomFieldFilterPost.php
Linia: 1687
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 03, 2014, 08:32:18 AM
after a making new group i see this error :
Code: [Select]
Field 'template_text' doesn't have a default value
Plik: /home/blabla/domains/blabla/public_html/smf2/Sources/Admin-CustomFieldFilterPost.php
Linia: 1687
Delete these tables

smf_cffp_settings_fields
smf_cffp_settings_groups

and excecute these SQL
Code: [Select]
CREATE TABLE smf_cffp_settings_fields (
  id_field int(10) NOT NULL auto_increment,
  id_group int(10) NOT NULL default '0',
  id_column int(10) NOT NULL default '0',
  name varchar(40) NOT NULL default '',
  field_desc varchar(255) NOT NULL default '',
  description varchar(255) NOT NULL default '',
  field_order tinyint(3) NOT NULL default '0',
  `type` varchar(8) NOT NULL default 'text',
  type_filter varchar(15) NOT NULL default 'text',
  length smallint(5) NOT NULL default '255',
  options text NOT NULL default '',
  options_text text NOT NULL default '',
  mask varchar(255) NOT NULL default '',
  bbc tinyint(3) NOT NULL default '0',
  default_value text NOT NULL default '',
  enclose_type varchar(4) NOT NULL default 'html',
  enclose_text text NOT NULL default '',
  show_message_index tinyint(3) NOT NULL default '0',
  filter_message_index tinyint(3) NOT NULL default '0',
  show_record_list_type varchar(5) NOT NULL default 'no',
  show_record_list_width varchar(7) NOT NULL default '',
  show_record_list_name varchar(40) NOT NULL default '',
  not_empty_value tinyint(3) NOT NULL default '0',
  unique_value tinyint(3) NOT NULL default '0',
  subset varchar(40) NOT NULL default '',
  permissions text NOT NULL default '',
  active tinyint(3) NOT NULL default '1',
  PRIMARY KEY  (id_field)
);
CREATE TABLE smf_cffp_settings_groups (
  id_group int(10) NOT NULL auto_increment,
  name varchar(40) NOT NULL default '',
  description varchar(255) NOT NULL default '',
  group_order tinyint(3) NOT NULL default '0',
  text_input text NOT NULL default '',
  text_output text NOT NULL default '',
  boards text NOT NULL default '',
  child_boards tinyint(3) default '0',
  `type` varchar(10) NOT NULL default 'fields',
  show_group_name_message_index tinyint(3) NOT NULL default '0',
  show_group_name_filter tinyint(3) NOT NULL default '0',
  show_group_name_search tinyint(3) NOT NULL default '0',
  show_fields_name tinyint(3) NOT NULL default '1',
  show_fields_set tinyint(3) NOT NULL default '0',
  show_empty_fields_post tinyint(3) NOT NULL default '0',
  show_empty_fields_message_index tinyint(3) NOT NULL default '0',
  show_actions_as varchar(10) NOT NULL default 'icon_text',
  show_member_expanded tinyint(3) NOT NULL default '0',
  show_member_expanded_data tinyint(3) NOT NULL default '0',
  show_member_expanded_new tinyint(3) NOT NULL default '0',
  show_sticky tinyint(3) default NULL,
  show_locked tinyint(3) default NULL,
  show_first_post_topic tinyint(3) NOT NULL default '0',
  show_replies_topic tinyint(3) NOT NULL default '0',
  no_show_with_subject_prefix text NOT NULL default '',
  show_in_topic varchar(11) NOT NULL default 'no',
  show_filters text NOT NULL default '',
  search_page_name text NOT NULL,
  search_page_order_by text NOT NULL,
  permissions text NOT NULL default '',
  active tinyint(3) NOT NULL default '1',
  template_type varchar(4) NOT NULL default 'html',
  template_text text NOT NULL default '',
  template_message_index_type varchar(4) NOT NULL default 'html',
  template_message_index_text text NOT NULL default '',
  PRIMARY KEY  (id_group)
);
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: ralph622 on May 03, 2014, 09:21:15 AM
Code: [Select]
CREATE TABLE smf_cffp_settings_fields ( id_field int(10) NOT NULL auto_increment, id_group int(10) NOT NULL default '0', id_column int(10) NOT NULL default '0', name varchar(40) NOT NULL default '', field_desc varchar(255) NOT NULL default '', description varchar(255) NOT NULL default '', field_order tinyint(3) NOT NULL default '0', `type` varchar(8) NOT NULL default 'text', type_filter varchar(15) NOT NULL default 'text', length smallint(5) NOT NULL default '255', options text NOT NULL default '', options_text text NOT NULL default '', mask varchar(255) NOT NULL default '', bbc tinyint(3) NOT NULL default '0', default_value text NOT NULL default '', enclose_type varchar(4) NOT NULL default 'html', enclose_text text NOT NULL default '', show_message_index tinyint(3) NOT NULL default '0', filter_message_index tinyint(3) NOT NULL default '0', show_record_list_type varchar(5) NOT NULL default 'no', show_record_list_width varch[...]

MySQL zwrócił komunikat: Dokumentacja
#1101 - BLOB/TEXT column 'options' can't have a default value

After that i deleted all tables from cffp and execute sql from your previuos post and again from last post. Value is the same... I totally dont know whats wrong...
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 03, 2014, 11:17:04 AM
Code: [Select]
CREATE TABLE smf_cffp_settings_fields ( id_field int(10) NOT NULL auto_increment, id_group int(10) NOT NULL default '0', id_column int(10) NOT NULL default '0', name varchar(40) NOT NULL default '', field_desc varchar(255) NOT NULL default '', description varchar(255) NOT NULL default '', field_order tinyint(3) NOT NULL default '0', `type` varchar(8) NOT NULL default 'text', type_filter varchar(15) NOT NULL default 'text', length smallint(5) NOT NULL default '255', options text NOT NULL default '', options_text text NOT NULL default '', mask varchar(255) NOT NULL default '', bbc tinyint(3) NOT NULL default '0', default_value text NOT NULL default '', enclose_type varchar(4) NOT NULL default 'html', enclose_text text NOT NULL default '', show_message_index tinyint(3) NOT NULL default '0', filter_message_index tinyint(3) NOT NULL default '0', show_record_list_type varchar(5) NOT NULL default 'no', show_record_list_width varch[...]

MySQL zwrócił komunikat: Dokumentacja
#1101 - BLOB/TEXT column 'options' can't have a default value

After that i deleted all tables from cffp and execute sql from your previuos post and again from last post. Value is the same... I totally dont know whats wrong...
I think this is a bug of your version of SQL http://bugs.mysql.com/bug.php?id=47901
Solution, I do not know... perhaps modify sql_mode value.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: Galaxy Computers on May 05, 2014, 01:13:57 PM
David,

I have found this mod for posting:

(Simple Image Upload)
http://custom.simplemachines.org/mods/index.php?mod=1669

I want to know if this mod will interfere with this Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7) mod?

Thanks
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 05, 2014, 04:08:13 PM
David,

I have found this mod for posting:

(Simple Image Upload)
http://custom.simplemachines.org/mods/index.php?mod=1669

I want to know if this mod will interfere with this Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7) mod?

Thanks
No but... yes:
- No: Simple Image Upload works when my mod is install. :)
- Yes: Simple Image Upload add a link for upload images before all textarea fields of my mod. :( (And works in all these).
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: Galaxy Computers on May 05, 2014, 04:19:54 PM
David,

I have found this mod for posting:

(Simple Image Upload)
http://custom.simplemachines.org/mods/index.php?mod=1669

I want to know if this mod will interfere with this Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7) mod?

Thanks
No but... yes:
- No: Simple Image Upload works when my mod is install. :)
- Yes: Simple Image Upload add a link for upload images before all textarea fields of my mod. :( (And works in all these).

Cool,,, I will have to mess with it and see if it will work the way I need it.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 05, 2014, 04:38:15 PM
I will have to mess with it and see if it will work the way I need it.
Simple Image Upload add a link for upload images. When you click on this link, open a windows, you can search an image on your hard disk, click on ok, system upload your image to external image hosting (like imageshack, photobucker or tinypic, but I do nor remember name) and add in textarea this bbc
Code: [Select]
[img]http://image_on_external_host.ext[/img]
No upload images to your server.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: spotlund on May 17, 2014, 11:21:29 AM
This is an incredible mod that i would like to try but will not install through package manager.  I have tried to study how to manually install it and it seems like a lot of work.  Can we work to to try and get the package manager to install it?  Im also on 2.0.7 and get these failed


*    5.    Execute Modification    ./Sources/MessageIndex.php    Test failed
      6.    Replace    ./Sources/MessageIndex.php    Test failed
      9.    Add After    ./Sources/MessageIndex.php    Test failed

and everything else successful.

EDIT:

I have installed this through package manager even though it recommends not to.  It seems to be working like it should.  The only thing i am running into is after every filter or field it is putting text input below the label of the field

Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: Westwegoman on May 18, 2014, 11:36:49 PM
This seems to be just the mod that I need. I have a fishing forum and I would like to add fields for water temperature, air temperature etc... On certain boards. This would only have to show up on the first post of the topic and doesn't have to be visible on the message index.

I tried to install but seems to have a conflict with the global topics mod by Margarett. Before I go about trying to get it to work, will I have issues between the 2 mods and am I understanding correctly about what this mod does? I just want to add information to the body of the post.

EDIT: Doesn't seem to matter. I installed and it works without the 2 edits to message index. Didn't need those since I only want the info in the actual post anyway.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 24, 2014, 05:28:07 PM
This is an incredible mod that i would like to try but will not install through package manager.  I have tried to study how to manually install it and it seems like a lot of work.  Can we work to to try and get the package manager to install it?  Im also on 2.0.7 and get these failed


*    5.    Execute Modification    ./Sources/MessageIndex.php    Test failed
      6.    Replace    ./Sources/MessageIndex.php    Test failed
      9.    Add After    ./Sources/MessageIndex.php    Test failed

and everything else successful.

EDIT:

I have installed this through package manager even though it recommends not to.  It seems to be working like it should.  The only thing i am running into is after every filter or field it is putting text input below the label of the field
David when you get a chance, i have loaded the mod and seems to be working well.  Thanks for the build!  The only thing i truly have ran into is my fields and their inputs are on separate lines and not directly to the right of each other.  Can you point me in the direction to change this please? Both on the new topic and on the first post.

Thanks again.
Hi spotlund,

I paste here your PM because the problem is the same, and it can be usefull for others users.

I think package install fails on MessageIndex.php because you have installed others mods and they modify same file.

If you install with these errors, my mod can work with errors, I do not known.

Modifications on file MessageIndex.php are these:
Code: [Select]
<file name="$sourcedir/MessageIndex.php">
<operation>
<search position="before"><![CDATA[
loadTemplate('MessageIndex');
]]></search>
<add><![CDATA[
// BEGIN MOD CustomFieldFilterPost
loadTemplate('CustomFieldFilterPost');

if (isset($_REQUEST['cffp_filters']))
$_REQUEST['cffp'] = cffpUrlParamsDecompress($_REQUEST['cffp_filters']);
$context['cffp_filters']['params'] = isset($_REQUEST['cffp']) ? ';cffp_filters=' . cffpUrlParamsCompress($_REQUEST['cffp']) : '';

// Load filters of custom post fields.
cffpLoad(0, 0, 'filters');

$context['cffp_filters']['sql'] = cffpGetSqlFilter('filters');
// END MOD CustomFieldFilterPost
]]></add>
</operation>

<operation>
<search position="before"><![CDATA[
// How many topics do we have in total?
]]></search>
<add><![CDATA[ // BEGIN MOD CustomFieldFilterPost
if (!empty($context['cffp_filters']['sql']))
$board_info['total_topics'] = cffpGetTotalTopics();
else
// END MOD CustomFieldFilterPost
]]></add>
</operation>

<operation>
<search position="replace"><![CDATA[$d;sort=' . $_REQUEST['sort'] . (isset($_REQUEST['desc']) ? ';desc' : ''), $_REQUEST['start']]]></search>
<add><![CDATA[$d;sort=' . $_REQUEST['sort'] . (isset($_REQUEST['desc']) ? ';desc' : '') /* BEGIN MOD CustomFieldFilterPost */ . $context['cffp_filters']['params'] /* END MOD CustomFieldFilterPost */, $_REQUEST['start']]]></add>
</operation>

<operation>
<search position="replace"><![CDATA[$d', $_REQUEST['start']]]></search>
<add><![CDATA[$d' /* BEGIN MOD CustomFieldFilterPost */ . $context['cffp_filters']['params'] /* END MOD CustomFieldFilterPost */, $_REQUEST['start']]]></add>
</operation>

<operation>
<search position="replace"><![CDATA[SELECT
t.id_topic]]></search>
<add><![CDATA[SELECT' /* BEGIN MOD CustomFieldFilterPost */ . (!empty($context['cffp_filters']['sql']) ? ' DISTINCT' : '') . /* END MOD CustomFieldFilterPost */ '
t.id_topic]]></add>
</operation>

<operation>
<search position="replace"><![CDATA['
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')')]]></search>
<add><![CDATA[/* BEGIN MOD CustomFieldFilterPost */ (empty($context['cffp_filters']['sql']) ? '' : '
' . $context['cffp_filters']['sql']['from']) . /* END MOD CustomFieldFilterPost */ '
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') /* BEGIN MOD CustomFieldFilterPost */ . (empty($context['cffp_filters']['sql']) ? '' : '
AND ' . $context['cffp_filters']['sql']['cond']) /* END MOD CustomFieldFilterPost */]]></add>
</operation>

<operation>
<search position="replace"><![CDATA[
array(
'current_board' => $board,
'current_member' => $user_info['id'],
'topic_list' => $topic_ids,
'is_approved' => 1,
'find_set_topics' => implode(',', $topic_ids),
'start' => $start,
'maxindex' => $maxindex,
)
]]></search>
<add><![CDATA[
// BEGIN MOD CustomFieldFilterPost
array_merge(!empty($context['cffp_filters']['sql']) ? $context['cffp_filters']['sql']['query_parameters'] : array(), array(
'current_board' => $board,
'current_member' => $user_info['id'],
'topic_list' => $topic_ids,
'is_approved' => 1,
'find_set_topics' => implode(',', $topic_ids),
'start' => $start,
'maxindex' => $maxindex,
)
)
// END MOD CustomFieldFilterPost
]]></add>
</operation>

<operation>
<search position="before"><![CDATA[
// Begin 'printing' the message index for current board.
]]></search>
<add><![CDATA[ // BEGIN MOD CustomFieldFilterPost
$id_msg_array = array();
// END MOD CustomFieldFilterPost
]]></add>
</operation>

<operation>
<search position="before"><![CDATA[
'unapproved_posts' => $row['unapproved_posts'],
);
]]></search>
<add><![CDATA[
// BEGIN MOD CustomFieldFilterPost
$id_msg_array[] = $context['topics'][$row['id_topic']]['first_post']['id'];
$context['cffp']['data_msg_topic'][$row['id_first_msg']] = array(
'sticky' => $context['topics'][$row['id_topic']]['is_sticky'] ? 1 : 0,
'locked' => $context['topics'][$row['id_topic']]['is_locked'] ? 1 : 0,
'id_msg' => $context['topics'][$row['id_topic']]['first_post']['id'],
'first_msg' => 1,
'subject' => $context['topics'][$row['id_topic']]['subject'],
);
// END MOD CustomFieldFilterPost
]]></add>
</operation>

<operation>
<search position="before"><![CDATA[
determineTopicClass($context['topics'][$row['id_topic']]);
}
$smcFunc['db_free_result']($result);
]]></search>
<add><![CDATA[
// BEGIN MOD CustomFieldFilterPost
// Load custom post fields.
cffpLoadValueOfFieldsByMsg($id_msg_array);
foreach ($context['topics'] as $t => $topic)
{
cffpLoad($topic['first_post']['id'], $topic['first_post']['member']['id'], 'message_index');
cffpLoad($topic['first_post']['id'], 0, 'message_index_member');
$context['topics'][$t]['first_post']['cffp']['message_index'] = $context['cffp']['message_index'];
$context['topics'][$t]['first_post']['cffp']['message_index_member'] = $context['cffp']['message_index_member'];
}
// END MOD CustomFieldFilterPost
]]></add>
</operation>
</file>
I recommend you to see which have not been applied and making them by hand.

About second problem, fields and their inputs are on separate lines and not directly to the right of each other, I think problems is CSS code (perhaps it was not copied when you install with errors, or you do not install on all themes.

Open your CSS file
FORUM_FOLDER/Themes/YOUR_THEME/css/index.css
and copy this code at end
Code: [Select]
/* BEGIN MOD CustomFieldFilterPost */
/* You do not modify this CSS style. Add your style before line "BEGIN MOD CustomFieldFilterPost" */
div.cffp_post,
div.cffp_member,
div.cffp_search
{
padding: 0.5em;
overflow: hidden;
}
div.cffp_post div.cffp_data,
div.cffp_member div.cffp_data,
div.cffp_search div.cffp_data
{
}
div.cffp_post dl.cffp_data dt,
div.cffp_member dl.cffp_data dt,
div.cffp_search dl.cffp_data dt
{
float: left;
padding: 0;
margin: .5em 0 0 0;
font-weight: bold;
clear: both;
}
div.cffp_post dl.cffp_data dd,
div.cffp_member dl.cffp_data dd,
div.cffp_search dl.cffp_data dd
{
float: left;
padding: 0;
margin: .3em 0;
}
div.cffp_post dl.cffp_data dt,
div.cffp_member dl.cffp_data dt
{
width: 20%;
}
div.cffp_post dl.cffp_data dd,
div.cffp_member dl.cffp_data dd
{
width: 78%;
}
div.cffp_search dl.cffp_data dt
{
width: 40%;
}
div.cffp_search dl.cffp_data dd
{
width: 58%;
}
form#cffp_edit_group .roundframe,
form#cffp_search .roundframe
{
padding: 0 12%;
}
div.cffp_post p.righttext,
div.cffp_member p.righttext
{
margin-top: 12px;
margin-bottom: 12px;
}
div.cffp_post .moderatorbar,
div.cffp_member .moderatorbar
{
margin: 0;
}
div.cffp_post ul.quickbuttons,
div.cffp_member ul.quickbuttons
{
}
div.cffp_member div.cffp_member_fields
{
border-bottom: 1px solid #c4c4c4;
}
div.cffp_member div.cffp_member_fields_first
{
border-top: 1px solid #c4c4c4;
}
div.cffp_member div.cffp_member_new_title
{
margin: 10px 0px;
}
div.cffp_member > fieldset legend a,
div.cffp_member div.cffp_member_data > fieldset legend a,
div.cffp_member div.cffp_member_new_title a
{
color: #444;
text-decoration: none;
}
div.cffp_member div.cffp_member_data_fields,
div.cffp_member div.cffp_member_new_fields
{
}
form#cffp_search div.cffp_column
{
margin: 0;
padding: 0;
width: 50%;
}
form#cffp_search div.cffp_column div.cffp_search
{
padding: 0 12px;
}
form#cffp_search div.cffp_roundframe
{
padding: 0 24%;
}
div.cffp_message_index,
div.cffp_message_index_member
{
}
div.cffp_message_index span,
div.cffp_message_index_member span
{
font-weight: bold;
margin-right: 1em;
}
div.cffp_message_index div.cffp_data,
div.cffp_message_index dl.cffp_data,
div.cffp_message_index dl.cffp_data dt,
div.cffp_message_index_member div.cffp_data,
div.cffp_message_index_member dl.cffp_data,
div.cffp_message_index_member dl.cffp_data dt
{
display: inline;
}
div.cffp_message_index dl.cffp_data dd,
div.cffp_message_index_member dl.cffp_data dd
{
display: inline-block;
margin-left: 0;
margin-right: 1em;
}
div.cffp_message_index_member div.cffp_member_fields
{
border-bottom: 1px solid #c4c4c4;
}
div.cffp_message_index_member div.cffp_member_fields_first
{
border-top: 1px solid #c4c4c4;
}
form#cffp_filters
{
margin-top: 1em;
}
form#cffp_filters div.cffp_filters span
{
font-weight: bold;
margin-right: 1em;
}
form#cffp_filters div.cffp_filters,
form#cffp_filters div.cffp_filters dl,
form#cffp_filters div.cffp_filters dt,
form#cffp_filters div.cffp_filters_button
{
display: inline;
}
form#cffp_filters div.cffp_filters dd
{
display: inline;
margin-left: 0;
margin-right: 1em;
}
ul.quickbuttons li.move_button
{
background: url(../images/icons/quick_move.gif) no-repeat 0 0;
}
/* END MOD CustomFieldFilterPost */





This seems to be just the mod that I need. I have a fishing forum and I would like to add fields for water temperature, air temperature etc... On certain boards. This would only have to show up on the first post of the topic and doesn't have to be visible on the message index.

I tried to install but seems to have a conflict with the global topics mod by Margarett. Before I go about trying to get it to work, will I have issues between the 2 mods and am I understanding correctly about what this mod does? I just want to add information to the body of the post.

EDIT: Doesn't seem to matter. I installed and it works without the 2 edits to message index. Didn't need those since I only want the info in the actual post anyway.
My mod works without the 2 edits to message index (it can be create unimportant warnings messages in logs). If you want applies by hand these 2 edit, read my reply to spotlund.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: spotlund on May 28, 2014, 09:05:55 AM
I have double checked both of these and all is as you have said in both messageindex and index.css.

I even removed and readded everything in index.css.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 28, 2014, 12:01:45 PM
I have double checked both of these and all is as you have said in both messageindex and index.css.

I even removed and readded everything in index.css.
Can you put here an image of your forum? Or send to me by PM your forum url...
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: spotlund on May 28, 2014, 01:37:11 PM
website is www.precisiontechsupport.com (http://www.precisiontechsupport.com) or forums.precisiontechsupport.com (http://forums.precisiontechsupport.com)
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on May 28, 2014, 03:12:33 PM
website is www.precisiontechsupport.com (http://www.precisiontechsupport.com) or forums.precisiontechsupport.com (http://forums.precisiontechsupport.com)
I visited your forum as guest. I did not see any post with custom fields but I saw index.css file and did not have this at the end (paste this at end of index.css)
Code: [Select]
/* BEGIN MOD CustomFieldFilterPost */
/* You do not modify this CSS style. Add your style before line "BEGIN MOD CustomFieldFilterPost" */
div.cffp_post,
div.cffp_member,
div.cffp_search
{
padding: 0.5em;
overflow: hidden;
}
div.cffp_post div.cffp_data,
div.cffp_member div.cffp_data,
div.cffp_search div.cffp_data
{
}
div.cffp_post dl.cffp_data dt,
div.cffp_member dl.cffp_data dt,
div.cffp_search dl.cffp_data dt
{
float: left;
padding: 0;
margin: .5em 0 0 0;
font-weight: bold;
clear: both;
}
div.cffp_post dl.cffp_data dd,
div.cffp_member dl.cffp_data dd,
div.cffp_search dl.cffp_data dd
{
float: left;
padding: 0;
margin: .3em 0;
}
div.cffp_post dl.cffp_data dt,
div.cffp_member dl.cffp_data dt
{
width: 20%;
}
div.cffp_post dl.cffp_data dd,
div.cffp_member dl.cffp_data dd
{
width: 78%;
}
div.cffp_search dl.cffp_data dt
{
width: 40%;
}
div.cffp_search dl.cffp_data dd
{
width: 58%;
}
form#cffp_edit_group .roundframe,
form#cffp_search .roundframe
{
padding: 0 12%;
}
div.cffp_post p.righttext,
div.cffp_member p.righttext
{
margin-top: 12px;
margin-bottom: 12px;
}
div.cffp_post .moderatorbar,
div.cffp_member .moderatorbar
{
margin: 0;
}
div.cffp_post ul.quickbuttons,
div.cffp_member ul.quickbuttons
{
}
div.cffp_member div.cffp_member_fields
{
border-bottom: 1px solid #c4c4c4;
}
div.cffp_member div.cffp_member_fields_first
{
border-top: 1px solid #c4c4c4;
}
div.cffp_member div.cffp_member_new_title
{
margin: 10px 0px;
}
div.cffp_member > fieldset legend a,
div.cffp_member div.cffp_member_data > fieldset legend a,
div.cffp_member div.cffp_member_new_title a
{
color: #444;
text-decoration: none;
}
div.cffp_member div.cffp_member_data_fields,
div.cffp_member div.cffp_member_new_fields
{
}
form#cffp_search div.cffp_column
{
margin: 0;
padding: 0;
width: 50%;
}
form#cffp_search div.cffp_column div.cffp_search
{
padding: 0 12px;
}
form#cffp_search div.cffp_roundframe
{
padding: 0 24%;
}
div.cffp_message_index,
div.cffp_message_index_member
{
}
div.cffp_message_index span,
div.cffp_message_index_member span
{
font-weight: bold;
margin-right: 1em;
}
div.cffp_message_index div.cffp_data,
div.cffp_message_index dl.cffp_data,
div.cffp_message_index dl.cffp_data dt,
div.cffp_message_index_member div.cffp_data,
div.cffp_message_index_member dl.cffp_data,
div.cffp_message_index_member dl.cffp_data dt
{
display: inline;
}
div.cffp_message_index dl.cffp_data dd,
div.cffp_message_index_member dl.cffp_data dd
{
display: inline-block;
margin-left: 0;
margin-right: 1em;
}
div.cffp_message_index_member div.cffp_member_fields
{
border-bottom: 1px solid #c4c4c4;
}
div.cffp_message_index_member div.cffp_member_fields_first
{
border-top: 1px solid #c4c4c4;
}
form#cffp_filters
{
margin-top: 1em;
}
form#cffp_filters div.cffp_filters span
{
font-weight: bold;
margin-right: 1em;
}
form#cffp_filters div.cffp_filters,
form#cffp_filters div.cffp_filters dl,
form#cffp_filters div.cffp_filters dt,
form#cffp_filters div.cffp_filters_button
{
display: inline;
}
form#cffp_filters div.cffp_filters dd
{
display: inline;
margin-left: 0;
margin-right: 1em;
}
ul.quickbuttons li.move_button
{
background: url(../images/icons/quick_move.gif) no-repeat 0 0;
}
/* END MOD CustomFieldFilterPost */
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: spotlund on May 28, 2014, 03:52:38 PM
thanks! i was only checking my default theme but it didnt make it to the theme that is set as default as well.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: MESWEB on June 21, 2014, 05:33:51 PM
I need a setup mod that adds a field in a Wysiwyg to choose form. Example: I start a new thread and in Wysiwyg choose between the value of "a" - "f". I will chose the value "b" and this value is added automatically to topic. Is this possible?
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on June 22, 2014, 07:50:31 AM
I need a setup mod that adds a field in a Wysiwyg to choose form. Example: I start a new thread and in Wysiwyg choose between the value of "a" - "f". I will chose the value "b" and this value is added automatically to topic. Is this possible?
I am not sure what you want. You can add a radio buttom or select with options a, b, c, d, e, f and you will can select one option...
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: MESWEB on June 22, 2014, 03:46:31 PM
I don't need radio button. I need dropdown list. When I select one the value are added to topic name. Example drop down list:
1 Windows XP
2 Windows Vista
3 Windows 7

I chose 2 "Windows Vista"and write the subject "How to install?". When are finish post and click "post" then automatically "Windows Vista" is added to subect like "[Windows Vista] How to install?"

Is this possible
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on June 23, 2014, 08:25:17 AM
Now this is not possible. Perhaps if you add javascript to a button (on next versions)... but now is not possible.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: MESWEB on June 24, 2014, 02:50:28 PM
Or just add value to database MySQL.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: MrMike on June 25, 2014, 08:28:22 PM
Wow, I just came across this and I have to say that this is an extremely impressive mod. Good stuff. :)

Very nice work, thank you for making this!

Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: MrMike on June 25, 2014, 08:37:37 PM
Now this is not possible. Perhaps if you add javascript to a button (on next versions)... but now is not possible.

Maybe a default handler could be added to some or all of the buttons/fields so that people could add their own JS functions to run when the button is pressed (or when the field is changed or focused/unfocused on).

Have it call a default javascript "do nothing" function, which could then be edited by the user to do whatever it is that  they want. For example, running some validation code or showing a dialog box, etc)

(I suppose you could also achieve the same effect via jQuery using the "Loading For SMF v1.0 (http://custom.simplemachines.org/mods/index.php?mod=3862)" mod, but it would be better to have it built in.)

I may not have explained this well, if so please let me know. It wouldn't be the first time. :)
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on June 28, 2014, 08:07:54 AM
Now this is not possible. Perhaps if you add javascript to a button (on next versions)... but now is not possible.

Maybe a default handler could be added to some or all of the buttons/fields so that people could add their own JS functions to run when the button is pressed (or when the field is changed or focused/unfocused on).

Have it call a default javascript "do nothing" function, which could then be edited by the user to do whatever it is that  they want. For example, running some validation code or showing a dialog box, etc)

(I suppose you could also achieve the same effect via jQuery using the "Loading For SMF v1.0 (http://custom.simplemachines.org/mods/index.php?mod=3862)" mod, but it would be better to have it built in.)

I may not have explained this well, if so please let me know. It wouldn't be the first time. :)
You do not worry, soon I update this MOD with some enhancements, and I will add possibility to add JavaScript code in groups of fields :)
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: luuuciano on July 07, 2014, 06:24:50 PM
Hola David!

I have installed your mod, and have been trying to use it... but maybe I do not quite understand it...
I have created a few fields, asigned them to a forum, did a simple output template... and then?
Well, then I went to that forum... clicked over the New post button... and nothing... nothing changed, nothing new... just the regular smf stuff...

The main idea is that I will see those new fields there, right?
To fill them... and then after submit the post, the template will show them?

What can be wrong?
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on July 08, 2014, 08:30:08 AM
Are you check permissions for users and actions? All groups and fields have permissions section at bottom of page. All are unckecked by default.

If you have problems, made images of your settings and post with custom groups of fields.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: luuuciano on July 08, 2014, 04:50:44 PM
Are you check permissions for users and actions? All groups and fields have permissions section at bottom of page. All are unckecked by default.

I think I did... here a couple of screenshots:

(http://imageshack.com/a/img856/1787/2rxx.png)

(http://imageshack.com/a/img841/2306/hdwh.png)

(http://imageshack.com/a/img820/9487/4kia.png)

Any idea?
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: davidhs on July 09, 2014, 08:12:24 AM
I saw the problem. :)

Groups has properties
- Show on the first post of topic / Mostrar en el primer mensaje del tema
- Show on the replies of topic / Mostrar en las respuestas del tema
and these are unchecked by default.

You must check some of these and you will see your group on first post and/or replies.

On next update I will change this and these properties will be checked by default.
Title: Re: Custom fields and filters of post, 1.0 (SMF 2.0-2.0.7)
Post by: luuuciano on July 10, 2014, 11:04:51 AM
You must check some of these and you will see your group on first post and/or replies.

Oops, thanks! :)
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on July 17, 2014, 07:32:03 PM
New version:
Code: [Select]
1.1     2014-07-17
------------------
! In WYSIWYG mode, if the user add a record and the post body is empty, the system did not write a period (".") on it.
! If a field with radio buttons or checkboxes is defined as "Not empty value" and is left blank, no error was displayed.
! Each posted data on groups of type "fields with several values per member" must be moved individually, not all from the message at once.
! Languages: english, english-utf8.
+ Support for print topic.
+ Field in administration panel to add BBC before the record when entering data.
+ Field in administration panel to add JavaScript code when a group of fields is created or modified.
+ Field in administration panel to add HTML before and after the input button and the output text in a custom field.
+ Field in administration panel to show expanded the most recent posted data in groups of type "fields with several values per member".
+ Field in administration panel to show most recent posted data at the top in groups of type "fields with several values per member".
+ Field in administration panel to indicate the maximum height of the area with posted data in groups of type "fields with several values per member".
+ Field in administration panel to show, in the member profile, a list for each group of type "record", with posted messages by the member containing this type of group.
+ Field in administration panel to control, in the Moderation Center, the content posted by users in the groups of type "fields with several values per member".
* Field in administration panel to indicate if a group will be show on the first post of topic is selected by default.
* Field in administration panel to indicate if a group will be show on the replies of topic is selected by default.
+ Quick input field to fill the fields when a record is created.
+ Variable in "Show enclosed within text" to insert ID of the current message.
+ Variable in "Show enclosed within text" to insert field name in database of any custom field.
+ PHP function in "Show enclosed within text" to display a group of a message like in a message or like on the message index.
+ Variable in templates to insert ID of the current message.
+ Variable in templates to insert field name in database of any custom field.
+ PHP function in templates to display a group of a message like in a message or like on the message index.
+ In administration panel is shown each group and field ID.
+ Text field to add multiple options at one time when a custom field with options is created or modified in administration panel.
* Big multi-line text input fields are wider.
* Submit buttons have shortcut key to get focus.
+ SMF compatibility: 2.0.8.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: MESWEB on July 19, 2014, 11:16:17 AM
Installation error nr.9:
Code: [Select]
'
LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . '
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on July 19, 2014, 04:22:22 PM
Installation error nr.9:
Code: [Select]
'
LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . '
This code are not installed by my mod (I write my text between
Code: [Select]
/* BEGIN MOD CustomFieldFilterPost */ ... /* END MOD CustomFieldFilterPost */
Are you sure the problem is my mod? Attach your php file and I will see.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: MESWEB on July 19, 2014, 06:57:47 PM
Installation error nr.9:
Code: [Select]
'
LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . '

This is are existing code. I need replace:
Code: [Select]
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')')
But when I replace the code I got error php.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on July 20, 2014, 10:39:18 AM
Installation error nr.9:
Code: [Select]
'
LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . '

This is are existing code. I need replace:
Code: [Select]
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')')
But when I replace the code I got error php.

We have a problem :( You have installed "Best Answer" and "NiceTooltips" mods. These mods do changes on MessageIndex.php and my mod do changes on same code.

You can not install these mods without errors. If you want install my mod you can to do these.

0. I suppose you have installed "Best Answer" and "NiceTooltips" mods.

1. Install my mod with errors. You must to have 2 errors on MessageIndex.php (actions #6 and #9)

2. You do these manual changes on MessageIndex.php.

2.1. Action #6, 1st part -> Search (line 388)
Code: [Select]
LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`
and replace by
Code: [Select]
LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`' . /* BEGIN MOD CustomFieldFilterPost */ (empty($context['cffp_filters']['sql']) ? '' : '
' . $context['cffp_filters']['sql']['from']) . /* END MOD CustomFieldFilterPost */ '

2.2. Action #6, 2nd part -> Search (line 391)
Code: [Select]
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . '
and replace by
Code: [Select]
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') /* BEGIN MOD CustomFieldFilterPost */ . (empty($context['cffp_filters']['sql']) ? '' : '
AND ' . $context['cffp_filters']['sql']['cond']) /* END MOD CustomFieldFilterPost */ . '

2.3. Action #9 -> Search (line 547)
Code: [Select]
'unapproved_posts' => $row['unapproved_posts'],
'best_answer' => array(
'id_msg' => $row['best_answer'],
'href' => $scripturl . '?topic=' . $row['id_topic'] . '.msg' . $row['best_answer'] . '#msg' . $row['best_answer']
),
);
and replace by
Code: [Select]
'unapproved_posts' => $row['unapproved_posts'],
'best_answer' => array(
'id_msg' => $row['best_answer'],
'href' => $scripturl . '?topic=' . $row['id_topic'] . '.msg' . $row['best_answer'] . '#msg' . $row['best_answer']
),
);

// BEGIN MOD CustomFieldFilterPost
$id_msg_array[] = $context['topics'][$row['id_topic']]['first_post']['id'];
$context['cffp']['data_msg_topic'][$row['id_first_msg']] = array(
'sticky' => $context['topics'][$row['id_topic']]['is_sticky'] ? 1 : 0,
'locked' => $context['topics'][$row['id_topic']]['is_locked'] ? 1 : 0,
'id_msg' => $context['topics'][$row['id_topic']]['first_post']['id'],
'first_msg' => 1,
'subject' => $context['topics'][$row['id_topic']]['subject'],
);
// END MOD CustomFieldFilterPost

But... if you uninstall my mod, you need undo these changes.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: MESWEB on July 20, 2014, 11:14:15 AM
Something is wrong with code.
Quote
Parse error: syntax error, unexpected '.' in /Sources/MessageIndex.php on line 406

I just delete dot from end of comment
Quote
/* END MOD CustomFieldFilterPost */ . '

Is this correct?
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on July 20, 2014, 12:06:19 PM
Something is wrong with code.
Quote
Parse error: syntax error, unexpected '.' in /Sources/MessageIndex.php on line 406

I just delete dot from end of comment
Quote
/* END MOD CustomFieldFilterPost */ . '

Is this correct?
Yes, of course. It is a typo. :-[ (I correct on previous post)
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: MESWEB on July 20, 2014, 12:52:03 PM
Ok thanks.

How to delete large empty space?
How to add value from selected list to subject? Like: [Windows XP] How to install?
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on July 20, 2014, 03:12:54 PM
How to delete large empty space?
Modify CSS file (YOUR_FORUM/Themes/default/css/index.css). Go to at end of file. This control width of fieldset
Code: [Select]
div.cffp_post dl.cffp_data dt,
div.cffp_member dl.cffp_data dt
{
width: 20%;
}
div.cffp_post dl.cffp_data dd,
div.cffp_member dl.cffp_data dd
{
width: 78%;
}
- cffp_post is for a record or field loose
- cffp_member is for a group with several values per member
- dt is space of field name
- dd is space of field button
total width must be around 98% (not 100%). i.e dt 20% + dd 78% = 98%

For example, you can rewrite this like
Code: [Select]
div.cffp_post dl.cffp_data dt,
div.cffp_member dl.cffp_data dt
{
width: 15%;
}
div.cffp_post dl.cffp_data dd,
div.cffp_member dl.cffp_data dd
{
width: 83%;
}
or others values.

How to add value from selected list to subject? Like: [Windows XP] How to install?
You see example on first message of this topic. You can add JavaScript code to a group of fields.

Your select button "System" has ID like "cffp_X_column_Y" (see source code). This copy value of select button checked to your subject:
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
document.getElementsByName("subject")[0].value = this.value;
}

With JavaScript can to do many things when an event occurs over a button (value is changed, loose focus, get focus, is checked,...):
- Update value of others buttons.
- Hide/show fields.
- Write text on subject or body of message.
- Change icon.
- ...
but is necessary know JavaScript and HTML, of course.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: MESWEB on July 20, 2014, 06:08:30 PM
Modify CSS file (YOUR_FORUM/Themes/default/css/index.css). Go to at end of file. This control width of fieldset
But when You use different Theme go to other catalog.
Code: [Select]
div.cffp_post dl.cffp_data dt,
div.cffp_member dl.cffp_data dt
{
width: 20%;
}
div.cffp_post dl.cffp_data dd,
div.cffp_member dl.cffp_data dd
{
width: 78%;
}
What happens if I will use 7 % + 78% = 85%. Does it cause any errors in displaying?
You see example on first message of this topic. You can add JavaScript code to a group of fields.

Your select button "System" has ID like "cffp_X_column_Y" (see source code). This copy value of select button checked to your subject:
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
document.getElementsByName("subject")[0].value = this.value;
}
How to put a square bracket to:
Quote
document.getElementById("cffp_X_column_Y").onchange = function (event)
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on July 20, 2014, 06:42:58 PM
Modify CSS file (YOUR_FORUM/Themes/default/css/index.css). Go to at end of file. This control width of fieldset
But when You use different Theme go to other catalog.
You should modify CSS of your theme.

Code: [Select]
div.cffp_post dl.cffp_data dt,
div.cffp_member dl.cffp_data dt
{
width: 20%;
}
div.cffp_post dl.cffp_data dd,
div.cffp_member dl.cffp_data dd
{
width: 78%;
}
What happens if I will use 7 % + 78% = 85%. Does it cause any errors in displaying?
No cause error. Width will be 7% (label) + 78% (buttons) + 15% (space).

You see example on first message of this topic. You can add JavaScript code to a group of fields.

Your select button "System" has ID like "cffp_X_column_Y" (see source code). This copy value of select button checked to your subject:
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
document.getElementsByName("subject")[0].value = this.value;
}
How to put a square bracket to:
Quote
document.getElementById("cffp_X_column_Y").onchange = function (event)
Do you not found keys "[ ]" on your keyboard? In each country or language is different.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: MESWEB on July 21, 2014, 10:25:06 AM
Do you not found keys "[ ]" on your keyboard? In each country or language is different.

Questions
1. You don't understand me  ;D. I need to add "[ ]" automatic. Example - when You select "Windows XP" from drop down list then subject looks like " [ Windows XP ] "
2. When I first write subject and next select from drop down list then subject is gone. Is there any chance to change this?
3. Is it possible to force a user to chose from drop down list? If he does not select then warning message popup should be displayed.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on July 21, 2014, 12:33:36 PM
 :-[ :D

Questions
1. You don't understand me  ;D. I need to add "[ ]" automatic. Example - when You select "Windows XP" from drop down list then subject looks like " [ Windows XP ] "
2. When I first write subject and next select from drop down list then subject is gone. Is there any chance to change this?
3. Is it possible to force a user to chose from drop down list? If he does not select then warning message popup should be displayed.
1. Easy... (+ is for concatenate strings in JavaScript)
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
document.getElementsByName("subject")[0].value = "[" + this.value + "]";
}

2. This change subject only if is empty.
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
if ("" == document.getElementsByName("subject")[0].value)
document.getElementsByName("subject")[0].value = "[" + this.value + "]";
}

3. Yes. 8) Edit field settings in Administrator Panel. Check Advanced settings > Not empty value. This shows a warning in red color like when subject or body is leave empty.
Also you can check a default option.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: Westwegoman on August 21, 2014, 01:00:18 AM
I just noticed that I get a database error when I try to search posts.

Quote
Not unique table/alias: 't'
File: /community/Sources/Subs-CustomFieldFilterPost.php
Line: 879

Also in error log, the following:
Quote
Database Error: Not unique table/alias: 't'
File: /community/Sources/Subs-CustomFieldFilterPost.php
Line: 879
 
Quote
8: Undefined index: can_approve_posts
File: /community/Sources/Subs-CustomFieldFilterPost.php
Line: 1592
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on August 21, 2014, 07:58:09 AM
I will see these bugs...
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: Westwegoman on August 21, 2014, 09:01:23 AM
Ok. Something strange. It doesn't give error on my test forum. Maybe a problem on my regular forum from something else.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on August 22, 2014, 07:50:17 AM
Ok. Something strange. It doesn't give error on my test forum. Maybe a problem on my regular forum from something else.
I have a bug in Subs-CustomFieldFilterPost.php of mod version 1.1. This is only executed when you have checked "approve any posts before they are shown".


I soon will update to version 1.2 with more bugs fixed and many enhancements. :)

At this moment you can fixed this bug with RAR attached. I suppose you have installed last version (1.1) of my mod. In this archive you can see two files:

smf2.0-2.0.7/Subs-CustomFieldFilterPost.php -- replace your file with this if your forum is SMF 2.0 to 2.0.7
smf2.0.8-2.0.99/Subs-CustomFieldFilterPost.php -- replace your file with this if your forum is SMF 2.0.8
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: kak2z on October 04, 2014, 03:11:20 PM
Hello. Thanks for a very useful mod.
I receive an error
Quote
index.php?board=114.0;a4f33eb90=9ed6e40691d1c80b6d518e174edc5de8Undefined index: can_approve_posts
/Sources/Subs-CustomFieldFilterPost.php
line: 1626
After you install this mod I could not install modification Karma Post Rating
I made these changes.



Code: [Select]
$context['page_index'] = constructPageIndex($scripturl . '?action=profile;u=' . $memID . ';area=showposts' . ($context['is_topics'] ? ';sa=topics' : '') . (!empty($board) ? ';board=' . $board : '') . (!empty($context['kpr_profile_sort']) ? ';rating' : '') . ((!empty($context['kpr_profile_sort']) && $context['kpr_profile_sort'] == 'rating_time') ? '=time' : '') . (!empty($context['kpr_profile_sort_desc']) ? ';desc' : '') , $context['start'], $msgCount, $maxIndex);

need
Code: [Select]
$context['page_index'] = constructPageIndex($scripturl . '?action=profile;u=' . $memID . ';area=showposts' . ($context['is_topics'] ? ';sa=topics' : '') . /* BEGIN MOD CustomFieldFilterPost */ ($context['is_cffp_record'] ? ';sa=cffp_record_' . $context['is_cffp_record'] : '') . /* END MOD CustomFieldFilterPost */ (!empty($board) ? ';board=' . $board : ''), $context['start'], $msgCount, $maxIndex);
my changes
Code: [Select]
$context['page_index'] = constructPageIndex($scripturl . '?action=profile;u=' . $memID . ';area=showposts' . ($context['is_topics'] ? ';sa=topics' : '') . /* BEGIN MOD CustomFieldFilterPost */ ($context['is_cffp_record'] ? ';sa=cffp_record_' . $context['is_cffp_record'] : '') . /* END MOD CustomFieldFilterPost */ (!empty($board) ? ';board=' . $board : '') . (!empty($context['kpr_profile_sort']) ? ';rating' : '') . ((!empty($context['kpr_profile_sort']) && $context['kpr_profile_sort'] == 'rating_time') ? '=time' : '') . (!empty($context['kpr_profile_sort_desc']) ? ';desc' : '') , $context['start'], $msgCount, $maxIndex);

Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: davidhs on October 05, 2014, 06:50:59 AM
Thanks for your warning. I will see Karma Post Rating and I will rewrite my mod if it is possible.

NOTE: I do not find download link for Karma Post Rating. :(
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: kak2z on October 05, 2014, 08:10:46 AM
About the modifications you have written to the PM.

Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.9)
Post by: davidhs on October 09, 2014, 07:27:28 AM
Compatible with SMF 2.0.9.
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.9)
Post by: digger on November 18, 2014, 05:09:17 AM
Some suggestions:

1) Can you add the ability to filter numbers and dates by range?
>х, <y

2) If there is a field with list of items, can you add an option to show in filter only those items that used in this board?
e.g. cities
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.9)
Post by: davidhs on November 18, 2014, 07:40:56 AM
Some suggestions:

1) Can you add the ability to filter numbers and dates by range?
>х, <y

2) If there is a field with list of items, can you add an option to show in filter only those items that used in this board?
e.g. cities
I do not know. I will see. Thanks.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 17, 2014, 12:51:42 PM
Some suggestions:

1) Can you add the ability to filter numbers and dates by range?
>х, <y

2) If there is a field with list of items, can you add an option to show in filter only those items that used in this board?
e.g. cities
Done.



New version:
Code: [Select]
1.2     2014-12-16
------------------
! Error in JavaScript code.
! Errors in PHP code.
! SMF 2.0.x: allowedTo('approve_posts') must be used instead of $context['can_approve_posts'].
! Entered values by the user in text box of a combo box with multiple selection can not be duplicated.
! Column width with only one field, in lists of moderation.
! Fields of type select box, radio buttons or checkboxes must have options.
! Empty option of select box must have the label "All" only in filters.
+ SMF 1.1.x: Implemented a generic form of displaying lists, similar to SMF 2.0.x.
+ SMF 1.1.x: Implemented database functions, similar to SMF 2.0.x.
+ Field in administration panel to indicate if quick input field will be show when data are modified.
+ Field in administration panel to add a long description in a custom field.
+ Field in administration panel to add a description in a search field.
+ Field in administration panel to add a long description in a search field.
+ Field in administration panel to indicate if creation date will be show on posted records.
+ Field in administration panel to indicate if last modification date will be show on modified records.
+ Field in administration panel to indicate if only one value per member in groups of type "fields with several values per member" is allowed.
+ Field in administration panel to indicate if is allowed selecting the operator with which apply the filter.
+ Field in administration panel to indicate if one or more filters are hidden under a tag.
+ Field in administration panel to show in filter only those items that used in the current board, if filter is a field with list of items.
+ Fields in administration panel to show statistics in groups of type "fields with several values per member".
+ Permission in administration panel to indicate if a field is used to sort the message index.
+ PHP function in "Show enclosed within text" to display statistics for the group of a message.
+ PHP function in templates to display statistics for the group of a message.
* Reorganization of the fields in the administration panel.
* The filter with text button allows to search loose words (separated by spaces) and/or literal phases (encloused in double quotes).
* The dates of create/modify of a group (left) and actions on a group (right) are shown on the same line.
* The date of create of groups of type "fields with several values per member" are also displayed on WAP.
* When display data posted by users in the groups of type "fields with several values per member", the background color alternates for readability.
* Forum parameter "Number of posts per page in a topic page" is used in lists of moderation.
* Forum parameter "Number of search results per page" is used in lists of search in custom fields.
* If users can not search for posts and topics then they can not search in custom fields.
* The areas with data of groups of type "fields with several values per member" can be displayed unexpanded, expanded or forever expanded.
* The field "Filter the message index" in administration panel is replaced by permissions.
+ SMF compatibility: 1.1 to 1.1.20 and 2.0.9.
@ SMF 1.1.x: List for each group of type "record" are not show on member profile.
@ SMF 1.1.x: There is not Moderation Center, but the global moderators can to control the content posted by users in the groups of type "fields with several values per member".
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 19, 2014, 08:05:37 PM
Nice work!
Do you not found keys "[ ]" on your keyboard? In each country or language is different.

Questions
1. You don't understand me  ;D. I need to add "[ ]" automatic. Example - when You select "Windows XP" from drop down list then subject looks like " [ Windows XP ] "
2. When I first write subject and next select from drop down list then subject is gone. Is there any chance to change this?
3. Is it possible to force a user to chose from drop down list? If he does not select then warning message popup should be displayed.

In Board index there are box with list (I create selectable different items) default of this box is "any" but when I create new message there is no choice to select "any". How can change this?
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 20, 2014, 05:21:52 AM
In Board index there are box with list (I create selectable different items) default of this box is "any" but when I create new message there is no choice to select "any". How can change this?
This should work.  ??? Can you attach images? Image of setting of your custon field and image of new message where this field is used.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 20, 2014, 04:02:11 PM
There is a board index with list box default value is "wszystkie"
http://obeznany.pl/index.php?board=75.0 (http://obeznany.pl/index.php?board=75.0)

In attachment You see no "Wszystkie" when message is creating.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 20, 2014, 05:55:31 PM
There is a board index with list box default value is "wszystkie"
http://obeznany.pl/index.php?board=75.0 (http://obeznany.pl/index.php?board=75.0)

In attachment You see no "Wszystkie" when message is creating.
It is correct.

You have a group, Telefony LG, with only one field, Model. Model is a field of type "Select box" with only one option, G3, and this option is the default value of field.

Option G3 of field Mode is the default option. This means that when you create a post with group Telefony LG, the field Mode takes the default value (G3). You can not select an empty option on this field because in settings you are selected "Not empty value".

In filters type "select box" default option is always All. In message index (or board index), is displayed a filter Model with options All (Wszystki in Polish) and the options of the field (in this case only one, G3). Filters are used for see all posts (when you select Model=All=Wszystki) or see post with one model (when you select Model=G3 you will see only posts of model G3).

In order to test this mod you should add more options to field Model (i.e. L3, L4,...) and create posts with different models.

Option All is not a real option of the field Model. Only will be displayed on filters and means "return list with any model". You could add an option Any to field Model but... Does this make sense?

Note: Your are not using the latest version of this mod (1.2). You should update, it has many enhancements! :)
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 20, 2014, 07:19:15 PM
I can't update. Errors:
5.6
5.9
5.10

Can You help me? Here is my file.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 21, 2014, 07:09:10 AM
I can't update. Errors:
5.6
5.9
5.10

Can You help me? Here is my file.
First you must uninstall previous version. Can you uninstall without errors?
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 21, 2014, 08:36:02 AM
I can't uninstall coz this errors is showing after uninstall action.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 21, 2014, 09:36:43 AM
I can't uninstall coz this errors is showing after uninstall action.
Ok. You should uninstall before other/s mod/s (installed after my mod).

Have you a mod like "best answer"?
1. Uninstall "best answer"
2. Uninstall my mod (if errors attach MessageIndex.php again, perhaps you need uninstall more mods first)
3. Install "best answer"
4. Install my mod (if errors install first my mod and after install "best answer")
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 21, 2014, 03:59:19 PM
Uninstalling Best Answer showing errors too. Can You make better installation file to avoid situation like this?
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 21, 2014, 04:21:15 PM
Can You make better installation file to avoid situation like this?
Sorry, it is not possible. There are many mods and I can not see all. :(

I suppouse you can not uninstall Best Answer.

Can you modify the file MessageIndex.php of your server? If yes, we can try a manual uninstall of my mod. You are agree?

You say to me the version of my mod (1.0 or 1.1) and check that there is only errors in the file MessageIndex.php when try uninstall
5.6
5.9
5.10
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 21, 2014, 04:53:30 PM
I have version 1.1 and when I uninstall with errors what I should do?
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Westwegoman on December 21, 2014, 05:31:52 PM
From what I am experiencing, Global Topics also affects this mod if it was installed after. Global Topics is also giving me errors on uninstall so, I'm going to try to work around mine when I get the time.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 21, 2014, 06:38:01 PM
I have version 1.1 and when I uninstall with errors what I should do?
There is a problem. Perhaps you can not install this mod (in automatic mode) after install Best Answer, but it can be install with errors and then do manual edit.

Steps for uninstall my mod:

1. Uninstall with errores (without delete tables!)

2. Open MessageIndex.php and modify:

2.1. Fix error 6. Before line 414, search
Code: [Select]
LEFT JOIN {db_prefix}log_mark_read AS lmr ON (lmr.id_board = {int:current_board} AND lmr.id_member = {int:current_member})'). ' LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`' . /* BEGIN MOD CustomFieldFilterPost */ (empty($context['cffp_filters']['sql']) ? '' : '
' . $context['cffp_filters']['sql']['from']) . /* END MOD CustomFieldFilterPost */ '
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : ' AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') /* BEGIN MOD CustomFieldFilterPost */ . (empty($context['cffp_filters']['sql']) ? '' : '
AND ' . $context['cffp_filters']['sql']['cond']) /* END MOD CustomFieldFilterPost */ . '
ORDER BY ' . ($pre_query ? 'FIND_IN_SET(t.id_topic, {string:find_set_topics})' : (!empty($modSettings['enableStickyTopics']) ? 'is_sticky' . ($fake_ascending ? '' : ' DESC') . ', ' : '') . $_REQUEST['sort'] . ($ascending ? '' : ' DESC')) . '
and replace by
Code: [Select]
LEFT JOIN {db_prefix}log_mark_read AS lmr ON (lmr.id_board = {int:current_board} AND lmr.id_member = {int:current_member})'). ' LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`' . '
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . '
ORDER BY ' . ($pre_query ? 'FIND_IN_SET(t.id_topic, {string:find_set_topics})' : (!empty($modSettings['enableStickyTopics']) ? 'is_sticky' . ($fake_ascending ? '' : ' DESC') . ', ' : '') . $_REQUEST['sort'] . ($ascending ? '' : ' DESC')) . '

2.2. Fix error 9. Before line 583, search
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
$id_msg_array[] = $context['topics'][$row['id_topic']]['first_post']['id'];
$context['cffp']['data_msg_topic'][$row['id_first_msg']] = array(
'sticky' => $context['topics'][$row['id_topic']]['is_sticky'] ? 1 : 0,
'locked' => $context['topics'][$row['id_topic']]['is_locked'] ? 1 : 0,
'id_msg' => $context['topics'][$row['id_topic']]['first_post']['id'],
'first_msg' => 1,
'subject' => $context['topics'][$row['id_topic']]['subject'],
);
// END MOD CustomFieldFilterPost
determineTopicClass($context['topics'][$row['id_topic']]);
and replace by
Code: [Select]
determineTopicClass($context['topics'][$row['id_topic']]);

2.3. Fix error 10. After lines of error 9, search
Code: [Select]
$smcFunc['db_free_result']($result);

// BEGIN MOD CustomFieldFilterPost
// Load custom post fields.
cffpLoadValueOfFieldsByMsg($id_msg_array);
foreach ($context['topics'] as $t => $topic)
{
cffpLoad($topic['first_post']['id'], $topic['first_post']['member']['id'], 'message_index');
cffpLoad($topic['first_post']['id'], 0, 'message_index_member');
$context['topics'][$t]['first_post']['cffp']['message_index'] = $context['cffp']['message_index'];
$context['topics'][$t]['first_post']['cffp']['message_index_member'] = $context['cffp']['message_index_member'];
}
// END MOD CustomFieldFilterPost
and replace by
Code: [Select]
$smcFunc['db_free_result']($result);


3. The End. :)

Now try install version 1.2. There are errors?
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 22, 2014, 04:10:18 AM

1. Uninstall with errores (without delete tables!)

2. Open MessageIndex.php and modify:

2.1. Fix error 6. Before line 414, search
Code: [Select]
LEFT JOIN {db_prefix}log_mark_read AS lmr ON (lmr.id_board = {int:current_board} AND lmr.id_member = {int:current_member})'). ' LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`' . /* BEGIN MOD CustomFieldFilterPost */ (empty($context['cffp_filters']['sql']) ? '' : '
' . $context['cffp_filters']['sql']['from']) . /* END MOD CustomFieldFilterPost */ '
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : ' AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') /* BEGIN MOD CustomFieldFilterPost */ . (empty($context['cffp_filters']['sql']) ? '' : '
AND ' . $context['cffp_filters']['sql']['cond']) /* END MOD CustomFieldFilterPost */ . '
ORDER BY ' . ($pre_query ? 'FIND_IN_SET(t.id_topic, {string:find_set_topics})' : (!empty($modSettings['enableStickyTopics']) ? 'is_sticky' . ($fake_ascending ? '' : ' DESC') . ', ' : '') . $_REQUEST['sort'] . ($ascending ? '' : ' DESC')) . '
and replace by
Code: [Select]
LEFT JOIN {db_prefix}log_mark_read AS lmr ON (lmr.id_board = {int:current_board} AND lmr.id_member = {int:current_member})'). ' LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`' . '
WHERE ' . ($pre_query ? 't.id_topic IN ({array_int:topic_list})' : 't.id_board = {int:current_board}') . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . '
ORDER BY ' . ($pre_query ? 'FIND_IN_SET(t.id_topic, {string:find_set_topics})' : (!empty($modSettings['enableStickyTopics']) ? 'is_sticky' . ($fake_ascending ? '' : ' DESC') . ', ' : '') . $_REQUEST['sort'] . ($ascending ? '' : ' DESC')) . '

2.2. Fix error 9. Before line 583, search
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
$id_msg_array[] = $context['topics'][$row['id_topic']]['first_post']['id'];
$context['cffp']['data_msg_topic'][$row['id_first_msg']] = array(
'sticky' => $context['topics'][$row['id_topic']]['is_sticky'] ? 1 : 0,
'locked' => $context['topics'][$row['id_topic']]['is_locked'] ? 1 : 0,
'id_msg' => $context['topics'][$row['id_topic']]['first_post']['id'],
'first_msg' => 1,
'subject' => $context['topics'][$row['id_topic']]['subject'],
);
// END MOD CustomFieldFilterPost
determineTopicClass($context['topics'][$row['id_topic']]);
and replace by
Code: [Select]
determineTopicClass($context['topics'][$row['id_topic']]);

3. The End. :)

Now try install version 1.2. There are errors?

This 2 errors are not that same like my errors. I uninstall with errors and delete manual my errors. So guess what i found after uninstall this mod? Lot of codes  CustomFieldFilterPost in message.index.php.

I have errors with install 1.2:
5.4
5.5
5.8
5.10
5.14
5.15

You should repair installation file that would be better for everyone.

SMF installation is a piece of ****** example:
error 5.4 find:
Code: [Select]
$d;sort=' . $_REQUEST['sort'] . (isset($_REQUEST['desc']) ? ';desc' : ''), $_REQUEST['start']Smf installation can't find this line. Why? I open message in Notepad++ an paste this code so what they found? This fu...king line. I don't understand why SMF install can't find line which one has been found in other programs.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 22, 2014, 08:09:04 AM
Before install my mod

Edit MessageIndex.php again:

1. Fix error 5.4. Line 91. Search

Code: [Select]
$context['page_index'] = constructPageIndex($scripturl . '?board=' . $board . '.%1$d;sort=' . $_REQUEST['sort'] . (isset($_REQUEST['desc']) ? ';desc' : '') , $_REQUEST['start'], $board_info['total_topics'], $maxindex, true);
replace by
Code: [Select]
$context['page_index'] = constructPageIndex($scripturl . '?board=' . $board . '.%1$d;sort=' . $_REQUEST['sort'] . (isset($_REQUEST['desc']) ? ';desc' : ''), $_REQUEST['start'], $board_info['total_topics'], $maxindex, true);
(after (isset($_REQUEST['desc']) ? ';desc' : '') there is an extra space, Why? I do not know...)

2. Fix error 5.5. Line 93. Search
Code: [Select]
$context['page_index'] = constructPageIndex($scripturl . '?board=' . $board . '.%1$d' , $_REQUEST['start'], $board_info['total_topics'], $maxindex, true);
replace by
Code: [Select]
$context['page_index'] = constructPageIndex($scripturl . '?board=' . $board . '.%1$d', $_REQUEST['start'], $board_info['total_topics'], $maxindex, true);
(after '?board=' . $board . '.%1$d' there is an extra space, Why? I do not know...)

3. Line 354. Important error! Search
Code: [Select]
LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`
ORDER BY ' . (!empty($modSettings['enableStickyTopics']) ? 'is_sticky' . ($fake_ascending ? '' : ' DESC') . ', ' : '') . $_REQUEST['sort'] . ($ascending ? '' : ' DESC') . '
replace by (also this fix error 5.8 )
Code: [Select]
LEFT JOIN {db_prefix}best_answer AS `ba` ON `t`.`id_topic` = `ba`.`id_topic`' . '
WHERE t.id_board = {int:current_board}' . (!$modSettings['postmod_active'] || $context['can_approve_posts'] ? '' : '
AND (t.approved = {int:is_approved}' . ($user_info['is_guest'] ? '' : ' OR t.id_member_started = {int:current_member}') . ')') . '
ORDER BY ' . (!empty($modSettings['enableStickyTopics']) ? 'is_sticky' . ($fake_ascending ? '' : ' DESC') . ', ' : '') . $_REQUEST['sort'] . ($ascending ? '' : ' DESC') . '

4. Line 377. Important error! Search
Code: [Select]
$result = $smcFunc['db_query']('substring', '
t.id_topic, t.num_replies, t.locked, t.num_views, t.is_sticky, t.id_poll, t.id_previous_board,
and write a "SELECT" between (also this fix error 5.10)
Code: [Select]
$result = $smcFunc['db_query']('substring', '
SELECT
t.id_topic, t.num_replies, t.locked, t.num_views, t.is_sticky, t.id_poll, t.id_previous_board,

5. Fix error 5.15. Line 561. Search
Code: [Select]
determineTopicClass($context['topics'][$row['id_topic']]);
and put 3 tabs at begin of line
Code: [Select]
determineTopicClass($context['topics'][$row['id_topic']]);

Instal my mod (1.2)

Error 5.14 can not be fix. It is because Best Answer and my mod modify same line.

Install my mod with error 5.14

After install my mod

Edit MessageIndex.php. Fix error 5.14. Line 555. Search
Code: [Select]
'best_answer' => array(
'id_msg' => $row['best_answer'],
'href' => $scripturl . '?topic=' . $row['id_topic'] . '.msg' . $row['best_answer'] . '#msg' . $row['best_answer']
),
);
and add text after, replace by
Code: [Select]
'best_answer' => array(
'id_msg' => $row['best_answer'],
'href' => $scripturl . '?topic=' . $row['id_topic'] . '.msg' . $row['best_answer'] . '#msg' . $row['best_answer']
),
);

// BEGIN MOD CustomFieldFilterPost
$id_msg_array[] = $context['topics'][$row['id_topic']]['first_post']['id'];
$context['cffp']['data_msg_topic'][$row['id_first_msg']] = array(
'sticky' => $context['topics'][$row['id_topic']]['is_sticky'] ? 1 : 0,
'locked' => $context['topics'][$row['id_topic']]['is_locked'] ? 1 : 0,
'id_msg' => $context['topics'][$row['id_topic']]['first_post']['id'],
'first_msg' => 1,
'subject' => $context['topics'][$row['id_topic']]['subject'],
);
// END MOD CustomFieldFilterPost

I expect now works!

NOTE: Use tab character (no space character) for indent text, is important! You make sure that Notepad++ not replace tab for space when write or save file.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: margarett on December 22, 2014, 08:11:36 AM
Easy on the language, yes? ;)

SMF  is perfectly able to find patterns of code. The problem is that the search pattern isn't exactly the same as the one in code (eg, 1 extra space, etc) and that causes it to fail. You, while searching manually, instinctively select just the text out of the search pattern ;)

Nice one, davidhs :-)
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MrMike on December 24, 2014, 12:13:48 PM
davidhs,

I'm looking at mods that might be suitable for creating a recipe site and I'm wondering if you think your mod might lend itself to that?

Would your mod be a practical way to add specific form fields to a post form, such a 'recipe title', 'ingredients', recipe instructions', and so on?

The mod looks amazing but I'm wondering if it might be overkill for my application, which is basically just a simple recipe form with a only a few inputs. (??)

Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 24, 2014, 12:44:29 PM
davidhs,

I'm looking at mods that might be suitable for creating a recipe site and I'm wondering if you think your mod might lend itself to that?

Would your mod be a practical way to add specific form fields to a post form, such a 'recipe title', 'ingredients', recipe instructions', and so on?

The mod looks amazing but I'm wondering if it might be overkill for my application, which is basically just a simple recipe form with a only a few inputs. (??)


Yes, I think you can use my mod.

You can create a group of fields (Recipe) with some fields: Title (text), ingredients (long text), instructions (long text),... image (text, for write url of image), type (select box with options: dessert,...),...

Also, you can create a board Recipes and allow only here create recipes, add filters or a search page and search recipes,...
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MrMike on December 24, 2014, 01:03:46 PM
Yes, I think you can use my mod.

You can create a group of fields (Recipe) with some fields: Title (text), ingredients (long text), instructions (long text),... image (text, for write url of image), type (select box with options: dessert,...),...

Also, you can create a board Recipes and allow only here create recipes, add filters or a search page and search recipes,...

I'll have a look. It seems like the learning curve is a bit steep, but I'll try it on a test site and see what I can do.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 24, 2014, 02:29:46 PM
Yes, I think you can use my mod.

You can create a group of fields (Recipe) with some fields: Title (text), ingredients (long text), instructions (long text),... image (text, for write url of image), type (select box with options: dessert,...),...

Also, you can create a board Recipes and allow only here create recipes, add filters or a search page and search recipes,...

I'll have a look. It seems like the learning curve is a bit steep, but I'll try it on a test site and see what I can do.
Yes, at the beginning it is complicated. If you have doubts, ask here.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 24, 2014, 03:59:10 PM
How modify this code:

Code: [Select]
document.getElementById("cffp_1_column_1").onchange = function (event)
{
document.getElementsByName("subject")[0].value = "[" + this.value + "]";
}

To not deleting words entered already in subject?
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 26, 2014, 06:12:35 PM
How modify this code:

Code: [Select]
document.getElementById("cffp_1_column_1").onchange = function (event)
{
document.getElementsByName("subject")[0].value = "[" + this.value + "]";
}

To not deleting words entered already in subject?
See this post, point 2 ;)
http://www.simplemachines.org/community/index.php?topic=518886.msg3722447#msg3722447
Title: Re: Custom fields and filters of post, 1.1 (SMF 2.0-2.0.8)
Post by: MESWEB on December 27, 2014, 12:15:43 PM
2. This change subject only if is empty.
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
if ("" == document.getElementsByName("subject")[0].value)
document.getElementsByName("subject")[0].value = "[" + this.value + "]";
}

I want to put this value at the beginning of the subject when it has already been written , or not
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 27, 2014, 06:44:49 PM
I want to put this value at the beginning of the subject when it has already been written , or not
Test this code
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
var subject = document.getElementsByName("subject")[0].value;

document.getElementsByName("subject")[0].value = "[" + this.value + "]";
if ("" != subject)
document.getElementsByName("subject")[0].value += " " + subject;
}
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 28, 2014, 07:40:37 AM
Yeahhh!!!! It's working. But when I still change the value from the select box then I have lot of the value like:
Code: [Select]
[value][value][value][value][value]subjectShould be better when next values are not added if any one value are added from the select box.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 28, 2014, 08:22:50 AM
Yeahhh!!!! It's working. But when I still change the value from the select box then I have lot of the value like:
Code: [Select]
[value][value][value][value][value]subjectShould be better when next values are not added if any one value are added from the select box.
Yes, it is a problem :(

Perhaps... if first character is a "[" do nothing, else write at begining.
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
var subject = document.getElementsByName("subject")[0].value;
var write = "" == subject || "[" != subject.charAt(0);

if (write)
{
document.getElementsByName("subject")[0].value = "[" + this.value + "]";
if ("" != subject)
document.getElementsByName("subject")[0].value += " " + subject;
}
}
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 29, 2014, 02:41:30 PM
This code not working property. When I select one value then has been added to subject correctly but when I change value it's nothing happened and still showing first value without change effect.

I think this would be helpful:
If some value has been added then don't increment by adding next one. $i = 1
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 29, 2014, 05:35:55 PM
Test this
Code: [Select]
document.getElementById("cffp_X_column_Y").onchange = function (event)
{
var subject = document.getElementsByName("subject")[0].value;
var match = subject.match(/^\[.+\](.*)/);

document.getElementsByName("subject")[0].value = "[" + this.value + "]";
if (null == match)
{
if ("" != subject)
document.getElementsByName("subject")[0].value += " " + subject;
}
else
document.getElementsByName("subject")[0].value += match[1];
}
If subject contains a "[option]" at begining, replace with "[new_option]"
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 29, 2014, 05:44:07 PM
Working Perfect.  :D . How to use require function to this select box? Example - info or popup where is "You need select value from selectbox before post new message". Can You insert more useful java codes to Your mod with select box to use them? That would be powerful mod here.

By the way. I found error incoming from this mod:
Code: [Select]
/index.php?pretty;action=admin&amp;area=logs;c4d57f882=9b2477f037b2c6cba8d42fae4ca2abc1
8: Undefined variable: smf_version_1
File: /Themes/default/languages/Modifications.english.php
Line: 477

Line 477:
Code: [Select]
$txt['cffp_records'] = 'Records';
if (!$smf_version_1)
$txt['cffp_moderation_area'] = 'Groups of fields on posts';
else
$txt['cffp_moderation_area'] = 'Moderate groups of fields on posts';
I change:
Code: [Select]
if (!$smf_version_1)To
Code: [Select]
if (empty($smf_version_1))
Now I testing this. Here is solution - http://www.simplemachines.org/community/index.php?topic=531723.msg3777045#msg3777045
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 29, 2014, 06:36:04 PM
How to use require function to this select box? Example - info or popup where is "You need select value from selectbox before post new message". Can You insert more useful java codes to Your mod with select box to use them? That would be powerful mod here.
JavaScript and popup not is necesary for this. In SMF if you saves a post without subject or body, you see a warning in red color. This mod do same. Just do this
3. Edit field settings in Administrator Panel. Check Advanced settings > Not empty value.


By the way. I found error incoming from this mod:
Code: [Select]
/index.php?pretty;action=admin&amp;area=logs;c4d57f882=9b2477f037b2c6cba8d42fae4ca2abc1
8: Undefined variable: smf_version_1
File: /home/messiah/domains/obeznany.pl/public_html/Themes/default/languages/Modifications.english.php
Line: 477

Line 477:
Code: [Select]
$txt['cffp_records'] = 'Records';
if (!$smf_version_1)
$txt['cffp_moderation_area'] = 'Groups of fields on posts';
else
$txt['cffp_moderation_area'] = 'Moderate groups of fields on posts';
I change:
Code: [Select]
if (!$smf_version_1)To
Code: [Select]
if (empty($smf_version_1))
Now I testing this. Here is solution - http://www.simplemachines.org/community/index.php?topic=531723.msg3777045#msg3777045
Thanks. This is an important bug. :(

Your solution is valid only in SMF 2.0.x, but in SMF 1.1.x it do not work.

Before line
Code: [Select]
if (!$smf_version_1)must write
Code: [Select]
global $forum_version;
$smf_version_1 = 0 === strpos($forum_version, 'SMF 1');

I will fix this bug in next update.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Arantor on December 29, 2014, 06:51:21 PM
You should not have such things in the language files. Should really have both strings, pick which one you need in the main code.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Biology Forums on December 29, 2014, 07:01:56 PM
Could someone explain what this modification does in a nutshell? I'm looking at this and it's like reading Chinese.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: MESWEB on December 30, 2014, 04:17:49 AM
I have next errors:
Code: [Select]
/index.php?pretty;board=a.40&amp;sort=replies;desc
8: Undefined index: cffp
File:/Themes/havvo/MessageIndex.template.php
Line: 272 and 273

Line 272 & 273:
Code: [Select]
270:// BEGIN MOD CustomFieldFilterPost
271:// Show custom post fields.
272:$context['cffp']['message_index'] = $topic['first_post']['cffp']['message_index'];
==>273:$context['cffp']['message_index_member'] = $topic['first_post']['cffp']['message_index_member'];
274:template_cffp_show('message_index');
275:template_cffp_show('message_index_member');
276:// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on December 30, 2014, 06:33:45 AM
You should not have such things in the language files. Should really have both strings, pick which one you need in the main code.
I will see this, but I do not want duplicate more language files... :(

Could someone explain what this modification does in a nutshell? I'm looking at this and it's like reading Chinese.
Now, a message have two fields (subject and body). This mod allow add more fields.

I have next errors:
Code: [Select]
/index.php?pretty;board=a.40&amp;sort=replies;desc
8: Undefined index: cffp
File:/Themes/havvo/MessageIndex.template.php
Line: 272 and 273

Line 272 & 273:
Code: [Select]
270:// BEGIN MOD CustomFieldFilterPost
271:// Show custom post fields.
272:$context['cffp']['message_index'] = $topic['first_post']['cffp']['message_index'];
==>273:$context['cffp']['message_index_member'] = $topic['first_post']['cffp']['message_index_member'];
274:template_cffp_show('message_index');
275:template_cffp_show('message_index_member');
276:// END MOD CustomFieldFilterPost
:( :( I will see and fix in next update, soon.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on January 02, 2015, 02:52:34 PM
Hello  :D

I Like Custom fields and filters of post and I want to make two changes.

I want to put color in the selection. If possible enable code html in configuration to do this activity.

See image 1 (ok)  ;)

See Image 2 (modification)

The 2nd request

I want to put a custom counter for the user always  that use the form.

See image 2 (modification).
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on January 03, 2015, 08:10:15 AM
I want to put color in the selection. If possible enable code html in configuration to do this activity.

See image 1 (ok)  ;)

See Image 2 (modification)
In settings of field Review you can use property Show enclosed within text

For example, this write all values in green:
Quote
Type = HTML
Code
Code: [Select]
<span style="color: green;">{INPUT}</span>
and this write each value in one color:
Quote
Type = PHP
Code
Code: [Select]
$color = array('Positive' => 'green', 'Medium' => 'orange', 'Negative' => 'red');
echo '<span style="color: ', $color['{INPUT}'], ';">{INPUT}</span>';

The 2nd request

I want to put a custom counter for the user always  that use the form.

See image 2 (modification).
Now this is not possible. I will see.



You have a group-record with title-director and review of one user.

Instead of, you can to do this:
- A group-Record (Film) with title-director and other data.
- A group-Fields with several values per member (Review) with only one field (select box Review) and statistics. All user can add review for one film and view statistical data.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on January 03, 2015, 11:09:07 AM
I got the color. It was excellent!

Thank you very much.

Please, I need this custom counter for form by each users.

If possible, I want a filter in the profile to find all user reviews. Equal in the search.

For example:

profile

Post: 1 (ok)
Reviews: 1 (mod)
See my reviews (link to access)

Se image 3

Thank you

I do the translation in Portuguese, if you want.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on January 04, 2015, 07:43:23 AM
If possible, I want a filter in the profile to find all user reviews. Equal in the search.

For example:

profile

Post: 1 (ok)
Reviews: 1 (mod)
See my reviews (link to access)

Se image 3
I do not put a link to access to users reviews in profile area at left of message, because SMF do not put a link to users posts.
But I add a list of group of type record created by an user in profile of user, near posts, topics and attachment.

In example of first post of this topic, I have groups of records called "Forums".
(https://googledrive.com/host/0B7M1e_-FeoeEMXhYTElBQnRUeTA/cffp_example_profile.png)

I do the translation in Portuguese, if you want.
Yes, of course. Thanks. :)
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Bruce the Shark on January 07, 2015, 04:15:38 AM
Will this mod allow me to custom my fields to who may see this information.
I was hoping i could remove this as seen in the image below.
Avatar box, personal message, personal profile.
Currently with my theme i am not able to hide this.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: sneakers on January 19, 2015, 12:54:51 PM
Hello,
Is it possible that custom fields are required for all users?
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on January 19, 2015, 05:18:10 PM
I do not know about php, but if I have something wrong, let me know.

I'll do a review

See my translation

Modifications.portuguese_brazilian.php

Code: [Select]
// BEGIN MOD CustomFieldFilterPost
$txt['cffp'] = 'Campos personalizados e filtros de mensagens';
$txt['cffp_desc'] = 'Painel de administra&ccedil;&atilde;o para o & quot; Os campos personalizados e filtros de mensagens & quot; MOD';
$txt['cffp_settings_display'] = 'Defini&ccedil;&otilde;es do campo';
$txt['cffp_settings_input'] = 'Configura&ccedil;&otilde;es de entrada';
$txt['cffp_settings_advanced'] = 'Ferramentas extras';
$txt['cffp_settings_grouptype'] = 'Configura&ccedil;&otilde;es para o tipo de &quot;%s&quot;'; // %s is a group type
$txt['cffp_field'] = 'Campo';
$txt['cffp_fields'] = 'Campos';
$txt['cffp_group'] = 'Grupo';
$txt['cffp_group_of_fields'] = 'Grupo de campos';
$txt['cffp_none_field'] = 'Você n&atilde;o adicionou nenhum campo para o grupo!';
$txt['cffp_none_group'] = 'Você n&atilde;o criou nenhum grupo de campos personalizados ainda!';
$txt['cffp_order'] = 'Ordem';
$txt['cffp_order_desc'] = 'Ordem do Display.';
$txt['cffp_text'] = 'Texto';
$txt['cffp_name'] = 'Nome';
$txt['cffp_field_description'] = 'Descri&ccedil;&atilde;o do campo';
$txt['cffp_field_description_desc'] = 'Exibido junto ao nome do.';
$txt['cffp_description'] = 'Descri&ccedil;&atilde;o';
$txt['cffp_text_previous'] = 'Texto anterior';
$txt['cffp_text_previous_desc'] = 'HTML para colocar antes do bot&atilde;o de entrada e sa&iacute;da do texto. Se o campo "Exibe fechado dentro do texto" &eacute; utilizada para o texto de sa&iacute;da deve ser escrito <tt>{TEXT_PREVIOUS}</tt> vari&aacute;vel nesse.';
$txt['cffp_text_next'] = 'Pr&oacute;ximo texto';
$txt['cffp_text_next_desc'] = 'HTML para colocar depois do bot&atilde;o de entrada e fim do texto. Se o campo "Exibe anexado dentro do texto" &eacute; utilizada para o texto de sa&iacute;da deve ser escrito <tt>{TEXT_NEXT}</tt> vari&aacute;vel nesse.';
$txt['cffp_enclose'] = 'Mostrar anexado dentro do texto';
$txt['cffp_enclose_desc'] = 'N&oacute;s <strong>fortemente</strong> recomendamos usar uma m&aacute;scara de entrada para validar a entrada fornecida pelo utilizador.';
$txt['cffp_text_input_before'] = 'Texto no display antes dos campos quando entrar com os dados';
$txt['cffp_text_input_before_desc'] = 'Admite BBC.';
$txt['cffp_text_input'] = 'Texto a ser exibido ao digitar os dados';
$txt['cffp_text_input_desc'] = 'Admite BBC.';
$txt['cffp_text_output'] = 'Texto a ser exibido durante a visualiza&ccedil;&atilde;o de dados';
$txt['cffp_text_output_desc'] = 'Admite BBC.';
$txt['cffp_type'] = 'Tipo';
$txt['cffp_type_filter'] = 'Tipo de campo';
$txt['cffp_type_filter_desc'] = 'Tipo de acionamento usado no filtro de indicador de mensagens e T&oacute;picos de pesquisa.';
$txt['cffp_fieldtype_text'] = 'Texto';
$txt['cffp_fieldtype_textarea'] = 'Grande texto';
$txt['cffp_fieldtype_select'] = 'Caixa de escolha';
$txt['cffp_fieldtype_combobox'] = 'Caixa de combina&ccedil;&atilde;o';
$txt['cffp_fieldtype_radio'] = 'Acionamento tipo Radio';
$txt['cffp_fieldtype_check'] = 'Caixas de sele&ccedil;&atilde;o';
$txt['cffp_fieldtype_boolean'] = 'Booleano';
$txt['cffp_grouptype_fields'] = 'Campos soltos';
$txt['cffp_grouptype_record'] = 'Campos personalizados';
$txt['cffp_grouptype_member'] = 'Os campos com v&aacute;rios valores por membro';
$txt['cffp_grouptype_filters'] = 'Filtros de busca';
$txt['cffp_length'] = 'O comprimento m&aacute;ximo de dados';
$txt['cffp_length_desc'] = '0 por nenhum limite.';
$txt['cffp_length_text_desc'] = 'A largura do campo proporcional a este valor. Se for 0 ou maior do que ou igual a 100, o campo ocupa a largura total.';
$txt['cffp_dimension'] = 'Medida da largura';
$txt['cffp_dimension_row'] = 'Fileiras';
$txt['cffp_dimension_col'] = 'Colunas';
$txt['cffp_dimension_col_desc'] = 'Se o &quot; Colunas&quot; se 0 ou maior do que ou igual a 100, o campo ocupa a largura total.';
$txt['cffp_mask'] = 'Disfarce de entrada';
$txt['cffp_mask_desc'] = 'Para campos de texto de um disfarce de entrada pode ser selecionado para validar os dados.';
$txt['cffp_mask_email'] = 'Email';
$txt['cffp_mask_number'] = 'N&uacute;mero';
$txt['cffp_mask_nohtml'] = 'Nunhum HTML';
$txt['cffp_mask_regex'] = 'Comando regular (Extra)';
$txt['cffp_select_multiple'] = 'Selecionar mais de um';
$txt['cffp_select_size'] = 'Quantidade de campos vistos';
$txt['cffp_allow_bbc'] = 'Permitir BBC';
$txt['cffp_options'] = 'Escolhas';
$txt['cffp_options_desc'] = 'Deixe a caixa de escolha em branco para remover. Tecla de escolha ou caixa de escolha seleciona as alternativas marcadas..';
$txt['cffp_options_more'] = 'Mais';
$txt['cffp_options_add_multi'] = 'Adicionar mais de uma escolha';
$txt['cffp_options_add_multi_desc'] = 'Escreva uma escolha em cada linha. Cada escolha tem valor e texto, separados por virgulas. Texto opcional.';
$txt['cffp_options_add_multi_combo_desc'] = 'Escreva um alternativa para cada linha';
$txt['cffp_default_value'] = 'Valor oficial';
$txt['cffp_boards'] = 'Sub-F&oacute;runs';
$txt['cffp_child_boards'] = 'Incluir Sub-F&oacute;runs descendentes';
$txt['cffp_child_boards_until'] = 'At&eacute; %d n&iacute;vel';
$txt['cffp_show_group_name_message_index'] = 'Ver nome do grupo no &iacute;ndice da mensagem';
$txt['cffp_show_group_name_message_index_desc'] = 'Se nenhum grupo for selecionado, nenhum grupo exibido no &iacute;ndice da mensagem.';
$txt['cffp_show_group_name_filter'] = 'Ver o nome do grupo nos filtros';
$txt['cffp_show_group_name_filter_desc'] = 'Se nenhum nome de grupo de filtros for selecionado, nenhum grupo exibido no &iacute;ndice da mensagem.';
$txt['cffp_show_group_name_search'] = 'Ver o nome do grupo na busca';
$txt['cffp_show_group_name_search_desc'] = 'Se nenhum nome de grupo for selecionado, nenhum gropo exibido na busca.';
$txt['cffp_show_fields_name'] = 'Ver nome dos campos';
$txt['cffp_show_fields_name_desc'] = 'Se nenhum nome for selecionado, nada exibido ao lado dos campos do grupo.';
$txt['cffp_show_fields_set'] = 'Ver campos como um conjunto';
$txt['cffp_show_fields_set_desc'] = 'Se selecionado os campos, agrupa-se sob o nome do grupo.';
$txt['cffp_show_empty_fields_post'] = 'Ver campos vazios na mensagem';
$txt['cffp_show_empty_fields_message_index'] = 'Ver campos vazios no &iacute;ndice da mensagem';
$txt['cffp_show_actions_as'] = 'Ver atos como';
$txt['cffp_show_actions_as_button'] = 'Teclas';
$txt['cffp_show_actions_as_icon_text'] = 'Elemento e texto';
$txt['cffp_show_actions_as_icon'] = 'Elementos';
$txt['cffp_show_actions_as_text'] = 'Texto';
$txt['cffp_show_member_expanded'] = 'Ver expandido';
$txt['cffp_show_member_expanded_data'] = 'Ver expandido os dados postados';
$txt['cffp_show_member_expanded_data_recent'] = 'Ver expandido o mais recente dados postados';
$txt['cffp_show_member_expanded_data_recent_desc'] = '0 para todos.';
$txt['cffp_show_member_expanded_new'] = 'Ver expandido o nova respota';
$txt['cffp_show_member_recent_at_top'] = 'Ver o mais recente dados da mensagens no topo';
$txt['cffp_member_max_height'] = 'Maior altura do campo dos dados postados';
$txt['cffp_member_max_height_px'] = 'px';
$txt['cffp_member_max_height_desc'] = '0 para ilimitado.';
$txt['cffp_show_sticky'] = 'Ver em t&oacute;picos fixos';
$txt['cffp_show_locked'] = 'Mostrar em t&oacute;picos bloqueados';
$txt['cffp_show_first_post_topic'] = 'Ativar na primeira mensagem do t&oacute;pico';
$txt['cffp_show_replies_topic'] = 'Ativar nas respostas do topico';
$txt['cffp_no_show_with_subject_prefix'] = 'Exibir nenhum campo para inserir junto ao assunto';
$txt['cffp_no_show_with_subject_prefix_desc'] = 'Prefixos separados por v&iacute;rgulas. Exemplo:;.';
$txt['cffp_show_in_topic'] = 'Exibir como grupo de campos do t&oacute;pico';
$txt['cffp_show_in_topic_desc'] = 'Se o grupo estive no campo em apenas no primeiro post desde o t&oacute;pico pode ser visto como pertencente ao t&oacute;pico ao inv&eacute;s do post, e exibido em outra &aacute;rea do tema, diferente para postar.';
$txt['cffp_show_in_topic_no'] = 'Nenhum (O grupo visto no campo da primeira mensagem)';
$txt['cffp_show_in_topic_begin_all'] = 'Sim, no come&ccedil;o de todos as p&aacute;ginas do t&oacute;picos';
$txt['cffp_show_in_topic_end_all'] = 'Sim, inserido no fim de todas as p&aacute;ginas do t&oacute;picos';
$txt['cffp_show_in_topic_begin_first'] = 'Sim, no come&ccedil;o da primeira p&aacute;gina do t&oacute;picos';
$txt['cffp_show_in_topic_end_first'] = 'Sim, no final do primeira p&aacute;gina do t&oacute;picos';
$txt['cffp_show_filters'] = 'Filtros';
$txt['cffp_show_filters_desc'] = 'Selecionar o filtro a ser utilizado.';
$txt['cffp_show_filters_boards'] = 'Sub-F&oacute;runs';
$txt['cffp_show_filters_subject_start'] = 'Comece do assunto';
$txt['cffp_show_filters_subject_first_char'] = 'Primeiro caractere do sujeito';
$txt['cffp_show_filters_date_topic'] = 'Dados do t&oacute;picos';
$txt['cffp_show_filters_date_replies'] = 'Dados da última resposta';
$txt['cffp_show_filters_date_lastdays'] = 'Último %s dias';
$txt['cffp_show_filters_topic_new_posts'] = 'T&oacute;picos com novos post';
$txt['cffp_show_filters_sticky'] = 'Fixos';
$txt['cffp_show_filters_sticky_disabled'] = 'T&oacute;picos fixos desativados. O Filtro n&atilde;o ser&aacute; exibido.';
$txt['cffp_show_filters_locked'] = 'Trancado';
$txt['cffp_show_filters_sticky_locked'] = 'Fixos e trancados';
$txt['cffp_javascript'] = 'C&oacute;digo JavaScript';
$txt['cffp_javascript_desc'] = 'C&oacute;digo executado quando um grupo de campos for criado ou modificado.';
$txt['cffp_search_page'] = 'Procurar t&oacute;picos';
$txt['cffp_search_page_post_desc'] = 'Escrever o nome dos t&oacute;picos e seleccione a ordem dos resultados de cada. Para remover um tema simplesmente esvaziar a caixa de texto para esse tema. Para adicionar um tema j&aacute; existente, selecione-o na lista.';
$txt['cffp_search_page_post_default'] = 'T&oacute;picos predefinidos';
$txt['cffp_search_page_post_more'] = 'Mais';
$txt['cffp_search_page_post_add'] = 'Adicionar um t&oacute;picos existente';
$txt['cffp_search_page_record_desc'] = 'Predefinido: &quot;Procurar por...&quot;.';
$txt['cffp_search_page_order_by'] = 'Ordenar resultados da pesquisa por';
$txt['cffp_search_page_order_by2'] = 'Ordenar por';
$txt['cffp_search_page_order_by_desc'] = 'Para que um campo seja mostrada aqui, deve ser exibido em uma coluna com apenas esse campo ou seja o primeiro campo na coluna.';
$txt['cffp_profile_list'] = 'Lista no perfil de membro';
$txt['cffp_profile_list_desc'] = 'Nome predefinido: Nome do grupo.';
$txt['cffp_profile_list_show'] = 'Exibir lista';
$txt['cffp_profile_list_name'] = 'Nome';
$txt['cffp_moderation_list'] = 'Lista no centro de Moderar';
$txt['cffp_moderation_list_desc'] = 'Nome predefinido: Nome do grupo. Para que um campo seja mostrado aqui, deve ser exibido em uma coluna com apenas esse campo ou seja o primeiro campo na coluna.';
$txt['cffp_moderation_list_show'] = 'Exibir lista';
$txt['cffp_moderation_list_menu'] = 'Exibir link no menu do F&oacute;rum';
$txt['cffp_moderation_list_name'] = 'Nome';
$txt['cffp_moderation_list_order_by'] = 'Ordenar por';
$txt['cffp_show_message_index'] = 'Exibir no &iacute;ndice de mensagens';
$txt['cffp_show_message_index_desc'] = 'Aplica-se, se for no primeiro post do t&oacute;picos.';
$txt['cffp_filter_message_index'] = 'Filtrar o &iacute;ndice de mensagens';
$txt['cffp_filter_message_index_desc'] = 'Mostra um tecla no &iacute;ndice de mensagens para filtrar t&oacute;picos por este campo.';
$txt['cffp_show_record_list_type'] = 'Mostrar em listas de registros';
$txt['cffp_show_record_list_type_desc'] = 'Mostra este campo em uma coluna das listas de registros (por exemplo, na busca de registos).';
$txt['cffp_show_moderation_list_type'] = 'Show on lists of Moderation Center';
$txt['cffp_show_moderation_list_type_desc'] = 'Mostra este campo em uma coluna das listas de Centro de Moderar.';
$txt['cffp_show_list_type_no'] = 'Nenhum';
$txt['cffp_show_list_type_one'] = 'Sim, em uma coluna com apenas este campo';
$txt['cffp_show_list_type_multi'] = 'Sim, em uma coluna juntamente com outros campos';
$txt['cffp_show_list_width'] = 'A largura da coluna';
$txt['cffp_show_list_width_desc'] = '0 para automatizado.';
$txt['cffp_show_list_width_unit_auto'] = 'Automatizado';
$txt['cffp_show_list_width_unit_%'] = 'Incostante';
$txt['cffp_show_list_width_unit_px'] = 'Fixo';
$txt['cffp_show_list_column'] = 'Coluna com variados campos';
$txt['cffp_show_list_column_other'] = 'Outro...';
$txt['cffp_show_list_name'] = 'Nome da coluna';
$txt['cffp_show_list_name_desc'] = 'Se n&atilde;o for especificado a coluna conter&aacute; somente neste campo.';
$txt['cffp_not_empty_value'] = 'N&atilde;o tem valor vazio';
$txt['cffp_not_empty_value_desc'] = 'Se selecionado este campo n&atilde;o pode ser deixado em branco.';
$txt['cffp_unique_value'] = 'Valor &uacute;nico';
$txt['cffp_unique_value_desc'] = 'Se selecionado n&atilde;o pode ter dois valores iguais neste campo.';
$txt['cffp_subset'] = 'Subconjunto';
$txt['cffp_subset_desc'] = 'O campo &eacute; exibido dentro de um subconjunto. Os campos de um subconjunto devem ser adjacentes.';
$txt['cffp_permissions'] = 'Permiss&otilde;es';
$txt['cffp_permissions_field_desc'] = 'As a&ccedil;&otilde;es que um membro pode executar ao longo deste campo, sujeitos &agrave;s permiss&otilde;es do f&oacute;rum.';
$txt['cffp_permissions_group_desc'] = 'As a&ccedil;&otilde;es que um membro pode executar ao longo deste grupo, sujeitos &agrave;s permiss&otilde;es do f&oacute;rum.';
$txt['cffp_owner_post'] = 'Dono da mensagem';
$txt['cffp_owner_group'] = 'Dono do grupo';
$txt['cffp_local_moderator'] = 'Moderador local';
$txt['cffp_global_moderator'] = 'Moderador global';
$txt['cffp_administrator'] = 'Administrador';
$txt['cffp_view_message_index'] = 'Veja no &iacute;ndice de mensagens';
$txt['cffp_add'] = 'adicionar';
$txt['cffp_move'] = 'Mover';
$txt['cffp_active'] = 'Ativo';
$txt['cffp_active_field_desc'] = 'Se n&atilde;o for selecionado este campo n&atilde;o ser&aacute; mostrado a ningu&eacute;m.';
$txt['cffp_active_group_desc'] = 'Se n&atilde;o for selecionado este grupo n&atilde;o ser&aacute; mostrado a ningu&eacute;m.';
$txt['cffp_more_info'] = 'Mais informa&ccedil;&otilde;es';
$txt['cffp_id'] = 'ID';
$txt['cffp_make_new_field'] = 'Novo campo';
$txt['cffp_make_new_group'] = 'Novo grupo';
$txt['cffp_add_field_title'] = 'Adicionar campo';
$txt['cffp_add_group_title'] = 'Adicionar grupo de campos';
$txt['cffp_edit_field_title'] = 'Editar campo';
$txt['cffp_edit_group_title'] = 'Editar grupo de campos';
$txt['cffp_edit_delete_field_sure'] = 'Tem certeza de que deseja apagar este campo? Todos os dados da mensagens relacionados ser&atilde;o perdidos!';
$txt['cffp_edit_delete_group_sure'] = 'Tem certeza de que deseja excluir este grupo? Todos os dados da mensagens relacionados ser&atilde;o perdidos!';
$txt['cffp_template'] = 'Template para mensagens';
$txt['cffp_template_message_index'] = 'Template para &iacute;ndice de mensagem';
$txt['cffp_template_quick_input'] = 'Template para entrada r&aacute;pida';
$txt['cffp_template_quick_input_regex'] = 'Express&atilde;o regular';
$txt['cffp_template_quick_input_regex_desc'] = 'Compat&iacute;vel com JavaScript. Usado em <tt>String.match(regex)</tt> m&eacute;todo e deve ser obtida uma matriz de valores de campo come&ccedil;ando com a tecla 1.';
$txt['cffp_template_quick_input_params'] = 'Par&acirc;metros';
$txt['cffp_template_quick_input_params_desc'] = 'Para cada elemento da matriz obtida a partir da express&atilde;o regular acrescenta uma linha com o campo ID, ou 0 se ele n&atilde;o corresponder a qualquer campo. Para a formata&ccedil;&atilde;o de um valor antes de copi&aacute;-lo em seu campo, abaixo do campo de ID para adicionar outra linha com o c&oacute;digo JavaScript.<tt>valor</tt>vari&aacute;vel cont&eacute;m o valor original e deve conter o valor transformado. Com <tt>field_obj [</tt>FIELD_ID<tt>]</tt> pode acessar um campo de formul&aacute;rio.';
$txt['cffp_template_quick_input_help'] = 'Ajuda';
$txt['cffp_template_quick_input_help_desc'] = 'Texto que o utilizador ver&aacute; em vez da express&atilde;o regular. permitir BBC.';
$txt['cffp_template_type_html'] = 'HTML';
$txt['cffp_template_type_bbc'] = 'BBC';
$txt['cffp_template_type_php'] = 'PHP';
$txt['cffp_add_templates'] = 'Adicionar templates';
$txt['cffp_edit_templates'] = 'Editar templates';
$txt['cffp_warning_cannot_see_group_fields'] = 'Você n&atilde;o pode ver os campos deste grupo.';
$txt['cffp_warning_group_subject'] = 'Esses campos ser&atilde;o removidos se o post sujeito come&ccedil;a com: %s.';
$txt['cffp_quick_input_field'] = 'Campo de entrada r&aacute;pida';
$txt['cffp_quick_input_field_desc'] = 'Escrever valores para entrar em campos diferentes de acordo com esta express&atilde;o regular:';
$txt['cffp_quick_input_match'] = 'Os campos s&atilde;o preenchidos.';
$txt['cffp_quick_input_no_match'] = 'Conteúdo do "campo de entrada r&aacute;pida" n&atilde;o est&aacute; formatado corretamente. Campos n&atilde;o pode ser preenchido.';
$txt['cffp_quick_input_apply'] = 'Preencha os campos';
$txt['cffp_created'] = 'Criado';
$txt['cffp_edit_group'] = 'Editar %s';
$txt['cffp_show'] = 'Exibir';
$txt['cffp_show_previous'] = 'Mostrar anterior';
$txt['cffp_move_to_first_post'] = 'Mover-se para o primeiro post neste t&oacute;picos';
$txt['cffp_move_to_other_post'] = 'Mover-se para um outro post';
$txt['cffp_move_to_other_topic'] = 'Mover-se para um outro t&oacute;picos';
$txt['cffp_move_group_to_other_post'] = 'Mover-se %s para outro post';
$txt['cffp_move_group_to_other_topic'] = 'Mover-se %s para outro t&oacute;picos';
$txt['cffp_move_to_post'] = 'Mover-se para o post';
$txt['cffp_move_to_post_desc'] = 'Publicar ID. exemplo:index.php?topic=4043.msg23892, use 23892.';
$txt['cffp_move_to_topic'] = 'Mover-se para o t&oacute;picos';
$txt['cffp_move_to_topic_desc'] = 'T&oacute;picos ID. Exemplo: index.php?topic=4043.0, use 4043.';
$txt['cffp_filter'] ='Filtro';
$txt['cffp_search_posts'] = 'Procurar posts';
$txt['cffp_search_posts_desc'] = 'Escreva o texto e / ou selecione as op&ccedil;&ccedil;&otilde;s nos campos em que deseja pesquisar. Você vai ter uma lista de posts que contenham esses valores em seus campos.';
$txt['cffp_search_records_type'] = 'Pesquisar registros do tipo %s';
$txt['cffp_search_records_desc'] = 'Escreva o texto e / ou selecione as op&ccedil;&ccedil;&otilde;s nos campos em que deseja pesquisar. Você vai ter uma lista de registros que contêm esses valores em seus campos.';
$txt['cffp_show_fields'] = 'Mostrar campos';
$txt['cffp_hide_fields'] = 'Ocultar campos';
$txt['cffp_record_type'] = 'Registros do tipo %s';
$txt['cffp_moderation_area'] = 'Grupos de campos em postes';
$txt['cffp_moderation_area_desc'] = 'Aqui você pode rever todos os dados postados por membros em grupos de campos personalizados.';
$txt['cffp_moderation_area_delete_sure'] = 'Tem certeza de que deseja apagar estes dados?';
$txt['cffp_moderation_area_none'] = 'N&atilde;o existem dados publicados';
$txt['cffp_poster_time'] = 'Dados postados';
$txt['cffp_topic_without_replies'] = 'T&oacute;picos sem respostas';
$txt['cffp_symbol'] = 'S&iacute;mbolo';
$txt['cffp_number'] = 'Número';
$txt['cffp_alphabet_letters'] = 'A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z'; //Alfabeto Inglês (letras maiúsculas separados por vírgula)
$txt['cffp_field_empty_value'] = 'Nenhum dados';
$txt['cffp_field_non_empty_value'] = 'H&aacute; dados';
$txt['cffp_filtertype_empty_non_empty'] = $txt['cffp_field_empty_value'] . ' / ' . $txt['cffp_field_non_empty_value'];
$txt['cffp_order_by_asc'] = 'Ordem ascendente';
$txt['cffp_order_by_desc'] = 'Ordem decrescente';
$txt['cffp_wireless_end_group'] = 'Fim %s';
// END MOD CustomFieldFilterPost

Errors.portuguese_brazilian.php

Code: [Select]
// BEGIN MOD CustomFieldFilterPost
$txt['error_cffp_field_need_name'] = 'O campo deve ter um nome!';
$txt['error_cffp_group_need_name'] = 'O grupo de campos deve ter um nome!';
$txt['error_cffp_field_need_options'] = 'O campo deve ter op&ccedil;&otilde;es!';
$txt['error_cffp_search_page_in_use'] = 'A p&aacute;gina de pesquisa j&aacute; est&aacute; em uso!';
$txt['error_cffp_search_page_in_use_record'] = 'A p&aacute;gina de pesquisa j&aacute; est&aacute; em uso por um registro!';
$txt['error_cffp_group_no_name'] = 'Nenhum nome foi fornecido em grupo &quot;%s&quot;.';
$txt['error_cffp_group_long_name'] = 'O nome que voc&ecirc; tentou usar em grupo &quot;%s&quot; era muito longo.';
$txt['error_cffp_group_bad_name'] = 'O nome que voc&ecirc; apresentou, em grupo &quot;%s&quot; n&atilde;o pode ser utilizado, uma vez que &eacute; ou cont&eacute;m um nome reservado.';
$txt['error_cffp_group_no_email'] = 'Nenhum endere&ccedil;o de e-mail fornecido no grupo &quot;%s&quot;.';
$txt['error_cffp_group_bad_email'] = 'Um endere&ccedil;o de e-mail inv&aacute;lido foi dada em grupo &quot;%s&quot;.';
$txt['error_cffp_group_invalid_email'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; deve ser um endere&ccedil;o de email v&aacute;lido.';
$txt['error_cffp_group_not_number'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; deve ser num&eacute;rico.';
$txt['error_cffp_group_inproper_format'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; &eacute; um formato inv&aacute;lido.';
$txt['error_cffp_group_empty'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; n&atilde;o pode ser deixado em branco.';
$txt['error_cffp_group_value_not_unique'] = 'O valor do campo &quot;%s&quot; no grupo &quot;%s&quot; j&aacute; existe.';
$txt['error_cffp_params'] = 'par&acirc;metros incorretos';
$txt['error_cffp_move_missing_post'] = 'A mensagem alvo &eacute; inexistente.';
$txt['error_cffp_move_missing_topic'] = 'O t&oacute;pico alvo &eacute; inexistente.';
$txt['error_cffp_move_board_post_not_allowed'] = 'Os dados n&atilde;o podem estar na categoria de mensagem de destino.';
$txt['error_cffp_move_board_topic_not_allowed'] = 'Os dados n&atilde;o podem estar na categoria de t&oacute;pico de destino.';
$txt['error_cffp_move_post_not_allowed'] = 'Os dados n&atilde;o podem ser na mensagem alvo.';
$txt['error_cffp_move_topic_not_allowed'] = 'Os dados n&atilde;o podem ser no t&oacute;pico alvo.';
$txt['error_cffp_move_already_has_data'] = 'A mensagem de destino j&aacute; tem este tipo de dados.';
$txt['error_cffp_move_post_already_has_data'] = 'O membro j&aacute; tem este tipo de dados na mensagem de destino.';
$txt['error_cffp_move_topic_already_has_data'] = 'O membro j&aacute; tem este tipo de dados no t&oacute;pico alvo.';
$txt['error_cffp_search_not_allowed'] = 'N&atilde;o definiu campos pesquis&aacute;veis ou voc&ecirc; n&atilde;o tem permiss&atilde;o para pesquisar.';
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on January 19, 2015, 05:26:26 PM
Help.portuguese_brazilian.php

Code: [Select]
// BEGIN MOD CustomFieldFilterPost
global $forum_version;
$smf_version_1 = 0 === strpos($forum_version, 'SMF 1');
$helptxt['cffp'] = '<b>Campos personalizados e filtros de mensagens</b><br />
Permite adicionar diferentes grupos de campos personalizados para posts no f&oacute;rum e filtros para os campos de mensagens.<br />
Um grupo de campos podem ser do tipo:<br />
<ul class="normallist">
<li>Campos soltos: Seus campos são adicionados a um post para fornecer informa&ccedil;&otilde;es extra. Na busca de dados em campos soltos de um post &eacute; obt&eacute;m uma lista de posts.</li>
<li>Registros: &Eacute; um conjunto de campos que representa uma entidade independente do post. Na busca de dados em campos de um registro é obt&eacute;m-se uma lista de registros. O corpo do post n&atilde;o pode ser deixado em branco, mas um post com registro n&atilde;o precisa de corpo. Se o usu&aacute;rio ir&aacute; adicionar um registro e o corpo do post estiver vazio, o sistema grava um per&iacute;odo(&quot;.&quot;) sobre ele e o usu&aacute;rio n&atilde;o precisa escrever nada.</li>
<li>Os campos com v&aacute;rios valores por membro: &Eacute; um conjunto de campos onde v&aacute;rios usu&aacute;rios podem inserir valores diferentes. Isso pode ser usado para os membros para fazer coment&aacute;rios ou avalia&ccedil;&otilde;es sobre o post. Se esses campos est&atilde;o localizados em apenas na primeira mensagem de um t&oacute;pico pode ser apresentado como pertencente ao t&oacute;pico.</li>
<li>Filters: Este &eacute; um tipo especial de grupo sem campos. Usado para habilitar um conjunto de filtros pr&eacute;-definidos que podem ser usados em t&oacute;picos e mensagens.</li>
</ul>
Os filtros predefinidos dispon&iacute;veis s&atilde;o:<br />
<ul class="normallist">
<li>Sub-F&oacute;rum.</li>
<li>Assunto.</li>
<li>Come&ccedil;o do assunto.</li>
<li>Primeiro caractere do assunto.</li>
<li>Dados do t&oacute;pico / Dado publicado.</li>
<li>Dados da &uacute;ltima resposta / Dado publicado.</li>
<li>Postado por.</li>
<li>T&oacute;pico com novos posts / Novo.</li>
<li>Fixos.</li>
<li>Trancado.</li>
<li>Respostas.</li>
<li>Enquete.</li>
</ul>
As a&ccedil;&otilde;es a serem realizadas em um grupo de campos personalizados s&acirc;o: vis&acirc;o, adicionar, modificar, apagar e mover.<br />
Furthermore other actions are possible using custom fields:<br />
<ul class="normallist">
<li>Filtrar o &iacute;ndice de mensagens.</li>
<li>Organizar o &iacute;ndice de mensagens.</li>
<li>Mostrar estat&iacute;sticas.</li>
<li>Pesquisar nas &aacute;reas de mensagens, obter uma lista de posts.</li>
<li>Pesquisar nas &aacute;reas de registros, obtendo uma lista de registros.</li>
</ul>
<br />
<b>Painel de administra&ccedil;&atilde;o</b><br />
O painel de administra&ccedil;&atilde;o tem a lista dos grupos de campos personalizados, o que permite adicionar novos grupos, modificar ou excluir grupos existentes, adicionar, modificar ou excluir campos de um grupo e definir modelos para exibir esses campos em um post e no &iacute;ndice de mensagens.<br />
<br />
<b>Visualizando posts com campos personalizados</b><br />
Ao visualizar um post completo (em um t&oacute;pico, em posts ou perfil recentes) s&atilde;o apresentados seus grupos (que s&atilde;o ativados quando o post &eacute; criado ou modificado). Grupo do tipo &quot;solto campos&quot; e &quot;registros&quot; s&atilde;o mostrados acima do corpo do post, Considerando que os grupos de tipo &quot;campos com v&aacute;rios valores por membro&quot; s&atilde;o apresentados a seguir, a menos o que foi selecionado &quot;Mostrar como grupo de campos do t&oacute;pico&quot; e, em seguida, &eacute; apresentado no in&iacute;cio e/ou e do t&oacute;pico. Se um grupo tem o template por mensagens os campos s&atilde;o exibidos de acordo com o template, se n&atilde;o s&atilde;o exibidos com o seu nome e conte&uacute;do.<br />
Em listas de posts (&iacute;ndice de mensagens, mensagem n&atilde;o lida e respostas) s&atilde;o grupos exibida com campos vis&iacute;veis no &iacute;ndice de mensagem (de acordo com as permiss&otilde;es). Se um grupo tem o template para o &iacute;ndice de mensagem os campos s&atilde;o exibidos de acordo com o template, se n&atilde;o s&atilde;o exibidos com o seu nome e conte&uacute;do.<br />
<br />
<b>Modificando valores em campos personalizados</b><br />
Em um tópico, posts com grupos de tipo &quot;campos com v&aacute;rios valores por membro&quot;t&ecirc;m bot&ocirc;es para o usu&aacute;rio postar novos valores, e modificar ou remover os existentes.<br />
Para todos os outros grupos (&quot;campos solto&quot; e &quot;registro&quot;), a criar ou modificar o post s&atilde;o exibidos grupos permitidos. Os grupos de tipo &quot;solto campos&quot; sempre t&ecirc;m seus campos vis&iacute;veis, enquanto que os grupos de tipo &quot;registro&quot; tem uma caixa de sele&ccedil;&atilde;o para mostrar ou ocultar os seus campos. Se tem sido modelo criado para a entrada r&aacute;pida em um registro, <strong>Campo de entrada r&aacute;pida</strong> &eacute; exibido ap&oacute;s os campos de registro.<br />
<br />
<b>Movendo um grupo de campos personalizados para outro post</b><br />
Um grupo de campos pode ter de ser atribu&iacute;do a um outro post, por exemplo, antes de remover o post onde &eacute; o grupo.<br />
Se o utilizador tem permiss&atilde;o para mover um grupo, ao visualizar um tema que grupo ter&aacute; bot&otilde;es para ir para o primeiro post do t&oacute;pico ou outro post (ou outro t&oacute;pico se o grupo &eacute; do tipo &quot;campos com v&aacute;rios valores por membro&quot; e selecionou &quot; Mostrar como grupo de campos do t&oacute;pico&quot;).<br />
<br />
<b>Filtrar o &iacute;ndice de mensagens</b><br />
Se o utilizador tem permiss&atilde;o para filtrar por um campo, um bot&atilde;o &eacute; exibido no &iacute;ndice de mensagens para filtrar t&oacute;picos por esse campo.<br />
Tipo de bot&atilde;o de filtro depende do tipo de campo:<br />
<ul class="normallist">
<li>O filtro para o texto ou campos de texto grandes &eacute; um bot&atilde;o de texto em que entrar na cadeia de pesquisa, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
<li>Campos tipo caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de ter pelo filtro de um bot&atilde;o de texto, uma caixa de sele&ccedil;&atilde;o ou uma caixa de combina&ccedil;&atilde;o em que digitar ou selecionar o texto a procurar, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
<li>Para campos do tipo boolean o filtro &eacute; uma caixa de sele&ccedil;&atilde;o com os valores &quot;Sim&quot; e &quot;Nenhum&quot;.</li>
</ul>
Se o usu&aacute;rio pode modificar um campo, que o campo pode estar vazio e seu filtro &eacute; uma caixa de sele&ccedil;&atilde;o ou caixa de combina&ccedil;&atilde;o, ele verá uma op&ccedil;&atilde;o na lista para obter dados com esse campo vazio.<br />
Al&eacute;m disso, com um grupo de tipo &quot;filtros&quot; podem ser adicionados filtros predefinidos.<br />
O filtro com o bot&atilde;o texto permite pesquisar palavras soltas (separados por espa&ccedil;os) e/ou fases literais (entre aspas duplas).<br />
Se o filtro &eacute; do tipo de texto ou caixa de combina&ccedil;&atilde;o, por padr&atilde;o, ele &eacute; procurado que o texto est&aacute; contido no valor do campo, enquanto que se o filtro &eacute; o tipo de lista de sele&ccedil;&atilde;o de caixa &eacute; pedido que o texto corresponde ao valor do campo.<br />
Os filtros podem ser do mesmo grupo ou grupos diferentes de campos.<br />
Ao lado de filtros h&aacute; um bot&atilde;o para ativar os filtros que foram dadas algum valor. Como resultado obt&eacute;m-se o &iacute;ndice de mensagens com t&oacute;picos cujo cargo primeira corresponde a todos os filtros ativos.<br />
<br />
<b>Organizar o &iacute;ndice de mensagens</b><br />
Se o usu&aacute;rio tem permiss&atilde;o para classificar por um ou mais campos, uma caixa de sele&ccedil;&atilde;o &eacute; exibido no &iacute;ndice de mensagens para classificar t&oacute;picos por um desses campos.<br />
<br />
<b>Mostrar estat&iacute;sticas</b><br />
Se um grupo de tipo &quot;campos com v&aacute;rios valores por membro&quot; tem um &uacute;nico campo e &eacute; de tyoe caixa de sele&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas (isto &eacute;, existe um n&uacute;mero finito de valores), pode ser gerar dados estat&iacute;sticos a partir dos valores inseridos no campo.<br />
Os dados estat&iacute;sticos a serem exibidos incluem:<br />
<ul class="normallist">
<li>Gr&aacute;fico com m&eacute;dia: &Eacute; constitu&iacute;da por uma barra horizontal onde o valor m&eacute;dio, o valor mais baixo permitido e o maior valor permitido est&atilde;o localizados.</li>
<li>Gr&aacute;fico com barras horizontais: Representa a utilização de cada valor permitido atrav&eacute;s de barras horizontais.</li>
<li>Gr&aacute;fico com barras verticais: Representa a utilização de cada valor permitido por meio de barra vertical.</li>
<li>Summary: Um conjunto de dados obtidos a partir dos valores de entrada (m&eacute;dia, o valor mais alto e mais baixo permitido, maior eo menor valor usado, valor mais e menos frequente).</li>
</ul>
O usu&aacute;rio v&ecirc; estes dados apenas se tiver permiss&atilde;o. O &iacute;ndice de mensagem pode ser ordenado por os dados de resumo, se ele tem permiss&atilde;o para classificar pelo campo.<br />
Usando templates podem ser inseridos os dados estat&iacute;sticos de qualquer grupo de campos em outro lugar.<br />
<br />
<b>Pesquisa em campos</b><br />
' . (!$smf_version_1 ? 'Sob a op&ccedil;&atilde;o &quot;Pesquisa&quot; a partir do f&oacute;rum menu p&aacute;ginas de pesquisa est&atilde;o localizados' : 'A op&ccedil;&atilde;o &quot;Mensagens de pesquisa e registros&quot; a partir do menu f&oacute;rum fornece acesso &agrave;s p&aacute;ginas de pesquisa') . ', mostrando os grupos e seus campos no qual o usu&aacute;rio tem permiss&atilde;o de busca.<br />
Grupos de tipo &quot;solto campos&quot;, &quot;campos com v&aacute;rios valores por membro&quot; e &quot;filtros&quot; pode estar em v&aacute;rias p&aacute;ginas de busca, e cada p&aacute;gina cont&eacute;m v&aacute;rios grupos, com a &uacute;nica condi&ccedil;&atilde;o de que os grupos em uma p&aacute;gina deve ser permitida em um conjunto comum de mensagens. Como resultado de pesquisa uma lista de postos &eacute; obtido.<br />
Para cada grupo de tipo &quot;registro&quot; com a permiss&atilde;o de busca tem uma p&aacute;gina. Como resultado, uma lista de registos &eacute; obtido com as colunas indicadas na defini&ccedil;&atilde;o dos campos.<br />
Em ambos os casos, os bot&otilde;es usados em cada campo de busca seguir a mesma regra que nos filtros.<br />' . (!$smf_version_1 ? '
<br />
<b>Lista no perfil de membro</b><br />
No perfil de membro, na se&ccedil;&atilde;o &quot;Informa&ccedil;&otilde;es do perfil &gt; Exibi Posts&quot;, pode ser mostrar uma lista para cada grupo de tipo &quot;registro&quot;, com mensagens postadas pelo pr&oacute;prio usu&aacute;rio contendo este tipo de grupo.<br />
<br />
<b>Lista em Centro Modera&ccedil;&atilde;o</b><br />
No Centro de modera&ccedil; &atilde;o &eacute; poss&iacute;vel controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
Para cada grupo que escolheu para mostrar esta lista ser&aacute; exibido um acesso &agrave; lista na se&ccedil;&atilde;o &quot;Posts &gt; Grupo de campos no posts&quot; e, opcionalmente, um link abaixo da op&ccedil;&atilde;o&quot;Moderado&quot; a partir do menu de f&oacute;rum.' : '
<br />
<b>Lista de modera&ccedil;&atilde;o</b><br />
Moderadores globais podem controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
A op&ccedil;&atilde;o &quot;Moderar os grupos de campos em mensagens&quot; a partir do menu f&oacute;rum fornece acesso &agrave; lista com dados lan&ccedil;ados, um para cada grupo, que escolheu para mostrar esta lista.');
$helptxt['cffp_enclose'] = 'Envolve a entrada do usu&aacute;rio entre algum texto(criado com HTML, BBC or PHP). Isso permitir&aacute; que voc&ecirc; adicione mais provedores de mensagens instant&acirc;neas, imagens ou uma incorpora&ccedil;&atilde;o etc. Por exemplo:<br />
<br />
&lt;a href="http://website.com/{INPUT}"&gt;&lt;img src="{DEFAULT_IMAGES_URL}/icon.gif" alt="{INPUT}" /&gt;&lt;/a&gt;<br />
<br />
Note que voc&ecirc; pode usar as seguintes vari&aacute;veis:<br />
<ul class="normallist">
<li><tt>{INPUT}</tt> - A entrada especificada pelo utilizador.</li>
<li><tt>{TEXT_PREVIOUS}</tt> - HTML para colocar antes do texto de sa&iacute;da.</li>
<li><tt>{TEXT_NEXT}</tt> - HTML para colocar a seguir o texto de sa&iacute;da.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_DATABASE}</tt> - O nome do campo no banco de dados do campo ID <i>n</i>. O campo pode ser de qualquer grupo.</li>
<li><tt>{ID_MSG}</tt> - ID da mensagem atual.</li>
<li><tt>{BOARDURL}</tt> - URL a pasta f&oacute;rum.</li>
<li><tt>{SCRIPTURL}</tt> - Endere&ccedil;o da Web do f&oacute;rum.</li>
<li><tt>{IMAGES_URL}</tt> - URL a pasta de imagens no usu&aacute;rios tema atual.</li>
<li><tt>{DEFAULT_IMAGES_URL}</tt> - URL para a pasta de imagens no tema padr&atilde;o.</li>
</ul>
No PHP, voc&ecirc; tamb&eacute;m pode usar as seguintes fun&ccedil;&otilde;es:<br />
<ul class="normallist">
<li><tt>{SHOW_GROUP_MSG}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>)</tt> - Exibe o grupo de uma mensagem como em uma mensagem.</li>
<li><tt>{SHOW_GROUP_MSGINDEX}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>)</tt> - Exibe o grupo de uma mensagem como no &iacute;ndice de mensagens.</li>
<li><tt>{SHOW_GROUP_MSG_STATS}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>, &apos;</tt><i>type</i><tt>&apos;, &apos;</tt><i>params</i><tt>&apos;)</tt> - Exibe as estat&iacute;sticas para o grupo de uma mensagem (se s&atilde;o ativados). o par&acirc;metro <i>type</i> pode ser:
<ul class="normallist">
<li><tt>chart_average</tt> - Exibe o gr&aacute;fico com a m&eacute;dia. o par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio mostrado), <tt>minmax</tt> (valor mais baixo e mais alto permitido mostrado), <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
<li><tt>chart_hbars</tt> - Apresenta o gr&aacute;fico com barras horizontais. o par&acirc;metro <i>params</i> n&atilde;o &eacute; utilizada.</li>
<li><tt>chart_vbars</tt> - Exibe o gr&aacute;fico com barras verticais. o par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
<li><tt>summary</tt> - Exibe o resumo. o par&acirc;metro <i>params</i> indica valores para mostrar, separados por v&iacute;rgulas. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
<li><tt>value</tt> - Exibe um valor de resumo. o par&acirc;metro <i>params</i> indica o valor a ser exibido. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
</ul></li>
</ul>';
$helptxt['cffp_mask'] = 'A m&aacute;scara de entrada &eacute; importante para o seu forum\'s seguran&ccedil;a. Validando a entrada de um usu&aacute;rio pode ajudar a garantir que os dados não &eacute; utilizado de uma forma que você n&atilde;o espera. N&oacute;s fornecemos algumas express&otilde;es regulares simples como sugest&otilde;es.<br /><br />
<div class="smalltext" style="margin: 0 2em">
&quot;[A-Za-z]+&quot; - Combinar todos os casos de caracteres do alfabeto superiores e inferiores.<br />
&quot;[0-9]+&quot; - Combinar todos os caracteres num&eacute;ricos.<br />
&quot;[A-Za-z0-9]{7}&quot; - Combinar todos os caracteres mai&uacute;sculas e min&uacute;sculas do alfabeto e num&eacute;ricos sete vezes.<br />
&quot;[^0-9]?&quot; - Proibir qualquer n&uacute;mero de ser correspondido.<br />
&quot;^([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6})$&quot; - Permitir somente 3 ou 6 hexcodes caracteres.<br />
</div><br /><br />
Adicionalmente, metacharacters especiais ?+*^$ e {xx} pode ser definida.
<div class="smalltext" style="margin: 0 2em">
? - Nenhum ou uma partida de express&atilde;o anterior.<br />
+ - Um ou mais de express&atilde;o anterior.<br />
* - Nenhum ou mais de express&atilde;o anterior.<br />
{xx} - Um n&uacute;mero exato de express&atilde;o anterior.<br />
{xx,} - Um n&uacute;mero exato ou mais a partir da express&atilde;o anterior.<br />
{,xx} - Um n&uacute;mero exato ou menos a partir da express&atilde;o anterior.<br />
{xx,yy} - Uma correspond&ecirc;ncia exata entre os dois n&uacute;meros a partir da express&atilde;o anterior.<br />
^ - In&iacute;cio da string.<br />
$ - Fim da string.<br />
\\ - Sair do pr&oacute;ximo caractere.<br />
</div><br /><br />
Mais informa&ccedil;&otilde;es e t&eacute;cnicas avan&ccedil;adas pode ser encontrado na internet.';
$helptxt['cffp_fieldtype'] = 'Tipos de campos que podem ser criados s&atilde;o:<br />
<ul class="normallist">
<li>Text: O campo no qual pode digitar o texto de uma linha.</li>
<li>Large text: O campo que permite que tipo multi-linha de texto.</li>
<li>Select box: O campo que exibe um menu de op&ccedil;&otilde;es para selecionar. O campo pode ser &uacute;nica sele&ccedil;&atilde;o (permite selecionar apenas uma op&ccedil;&atilde;o) ou m&uacute;ltiplo (permite selecionar v&aacute;rias op&ccedil;&otilde;es de uma s&oacute; vez).</li>
<li>Combo box: Combina&ccedil;&atilde;o de caixa de sele&ccedil;&atilde;o (sele&ccedil;&atilde;o &uacute;nica ou m&uacute;ltipla) e caixa de texto, permitindo digitar um valor (ou valores separados por vírgulas) ou escolher a partir de uma lista de op&ccedil;&otilde;es.</li>
<li>Radio buttons: Conjunto de op&ccedil;&otilde;es a partir do qual s&oacute; pode escolher um.</li>
<li>Checkboxes: Conjunto de op&ccedil;&otilde;es a partir do qual voc&ecirc; pode escolher v&aacute;rios de uma vez.</li>
<li>Boolean: Apenas uma op&ccedil;&otilde;o que pode ser seleccionado (valor &quot;verdadeiro&quot;) ou n&atilde;o (valor &quot;falso&quot;).</li>
</ul>';
$helptxt['cffp_grouptype'] = 'Um grupo de campos podem ser do tipo:<br />
<ul class="normallist">
<li>Campos soltos: Seus campos são adicionados a um post para fornecer informa&ccedil;&otilde;es extra. Na busca de dados em campos soltos de um post obtendo uma lista de posts.</li>
<li>Registro: &Eacute; um conjunto de campos que representa uma entidade independente do post. Na busca de dados em campos de um registro &eacute; obt&eacute;m uma lista de registros. O corpo do post n&atilde;o pode ser deixado em branco, mas um post com registro n&atilde;o precisa de corpo. Se o usu&aacute;rio ir&aacute; adicionar um registro e o corpo do post estiver vazio, o sistema grava um per&iacute;odo (&quot;.&quot;) sobre ele e o usu&aacute;rio n&atilde;o precisa escrever nada.</li>
<li>Os campos com v&aacute;rios valores por membro: Ele &eacute; definido de campos onde v&aacute;rios usu&aacute;rios podem inserir valores diferentes. Isso pode ser usado para os membros para fazer coment&aacute;rios ou avalia&ccedil;&otilde;es sobre o post.</li>
<li>Filtros: Este &eacute; um tipo especial de grupo sem campos. Usado para habilitar um conjunto de filtros pr&eacute;-definidos que podem ser usados em t&oacute;picos e mensagens.</li>
</ul>';
$helptxt['cffp_type_filter'] = 'Tipo de bot&atilde;o de filtro depende do tipo de campo:<br />
<ul class="normallist">
<li>O filtro para o texto ou campos de texto grandes &eacute; um bot&atilde;o de texto para entrar na cadeia de pesquisa, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
<li>Campos tipo caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de ter pelo filtro de um bot&atilde;o de texto, uma caixa de sele&ccedil;&atilde;o ou uma caixa de combina&ccedil;&atilde;o em que digitar ou selecionar o texto a procurar, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
<li>Para campos do tipo boolean o filtro &eacute; uma caixa de sele&ccedil; &atilde;o com os valores &quot;Sim&quot; e &quot;N&atilde;o&quot;.</li>
</ul>
Se o usu&aacute;rio pode modificar um campo, que o campo pode estar vazio e seu filtro &eacute; uma caixa de sele&ccedil;&atilde;o ou caixa de combina&ccedil;&atilde;o, ele ver&aacute; uma op&ccedil;&atilde;o na lista para obter dados com esse campo vazio.<br />
O filtro com o bot&atilde;o texto permite pesquisar palavras soltas (separados por um espa&ccedil;o) e/ou fases literais (entre aspas duplas).<br />
Se o filtro &eacute; do tipo de texto ou caixa de combina&ccedil;&atilde;o, por padr&atilde;o, ele &eacute; procurado que o texto est&aacute; contido no valor do campo, enquanto que se o filtro &eacute; o tipo de lista de sele&ccedil;&atilde;o de caixa &eacute; pedido que o texto corresponde ao valor do campo.';
$helptxt['cffp_options'] = 'Esta se&ccedil;&atilde;o define as op&ccedil;&otilde;es que o usu&aacute;rio pode escolher a partir de uma caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de sele&ccedil;&atilde;o. Existem alguns pontos-chave a serem observados nesta se&ccedil;&atilde;o:<br />
<ul class="normallist">
<li>As op&ccedil;&otilde;es padr&atilde;o: Qualquer que seja a caixa de opop&ccedil;&otilde;eses tem a &quot;bot&atilde;o de r&aacute;dio&quot; (pode haver apenas um) ou &quot;checkbox&quot; (pode ser v&aacute;rias) ao lado desse selecionado ser&aacute; as sele&ccedil;&otilde;es padr&atilde;o para o utilizador quando entram dados.</li>
<li>Remo&ccedil;&atilde;o de opcionais: Para remover uma op&ccedil;&atilde;o simplesmente vazia na caixa de texto para essa op&ccedil;&atilde;o - todas as mensagens com o seleccionado ter&aacute; sua op&ccedil;&atilde;o desmarcada.</li>
<li>Reordenar op&ccedil;&otilde;es: Voc&ecirc; pode reordenar as op&ccedil;&otilde;es movendo texto em torno entre as caixas. Contudo - uma nota importante - voc&ecirc; deve se certificar do que voc&ecirc; faz <strong>n&atilde;o</strong> mudar o texto quando reordena&ccedil;&atilde;o op&ccedil;&otilde;es em contr&aacute;rio dados postados ser&atilde;o perdidos.</li>
<li>Texto (dispon&iacute;vel se o bot&atilde;o n&atilde;o &eacute; uma caixa de combina&ccedil;&atilde;o): Uma op&ccedil;&atilde;o pode ser exibido com valor real ou com um texto mais significativo para o usu&aacute;rio.</li>
<li>Adicione v&aacute;rias op&ccedil;&otilde;es: Permite adicionar v&aacute;rias op&ccedil;&otilde;es de uma s&oacute; vez, escrevendo cada op&ccedil;&atilde;o em uma linha do campo de texto grande. Cada op&ccedil;&atilde;o tem valor e, se o bot&atilde;o n&atilde;o &ecirc; uma caixa de combinaç&atilde;o, texto, separados por v&iacute;rgulas. Texto &ecirc; opcional.</li>
</ul>';
$helptxt['cffp_javascript'] = 'C&oacute;digo JavaScript executado quando um grupo de campos &eacute; criado ou modificado.<br />
Permite a execu&ccedil;&atilde;o de c&oacute;digo quando um evento ocorre ao longo de um bot&atilde;o de formul&aacute;rio ou outro elemento HTML.<br />
Isto pode ser escrito como:<br />
<br />
<tt>document.getElementsByName(</tt><i>html_element_name</i><tt>)[0].</tt><i>event_name</i><tt> = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;// ...<br />
}<br />
document.getElementById(</tt><i>html_element_id</i><tt>).</tt><i>event_name</i><tt> = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;// ...<br />
}</tt><br />
<br />
Por exemplo, este c&oacute;digo mostra uma mensagem quando o usu&aacute;rio clica no bot&atilde;o <tt>id1</tt> e copiar o valor do bot&atilde;o <tt>id2</tt> sobre o assunto quando o usu&aacute;rio alterar esse valor:<br />
<br />
<tt>document.getElementById(&quot;id1&quot;).onclick = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;alert(&quot;A message&quot;);<br />
}<br />
document.getElementById(&quot;id2&quot;).onchange = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;document.getElementsByName(&quot;subject&quot;)[0].value = this.value;<br />
}</tt>';
$helptxt['cffp_stats'] = 'Se um grupo de tipo &quot;campos com v&aacute;rios valores por membro&quot; tem um &uacute;nico campo e &eacute; do tipo caixa de sele&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas (isto &eacute;, existe um n&uacute;mero finito de valores), pode gerar dados estat&iacute;sticos a partir dos valores inseridos no campo.<br />
Os dados estat&iacute;sticos a serem exibidos incluem:<br />
<ul class="normallist">
<li>Gr&aacute;fico com m&eacute;dia: &Eacute; constitu&iacute;da por uma barra horizontal, onde o valor m&eacute;dio, o valor mais baixo permitido e o valor mais elevado permitido est&atilde;o localizados.</li>
<li>Gr&aacute;fico com barras horizontais: Representa o uso de cada valor permitido por barras horizontais.</li>
<li>Gr&aacute;fico com barras verticais: Representa o uso de cada valor permitido por barra vertical.</li>
<li>Resumo: Um conjunto de dados obtidos a partir dos valores de entrada (m&eacute;dia, o valor mais alto e mais baixo permitido, maior e o menor valor usado, valor mais e menos frequente).</li>
</ul>
O usu&aacute;rio v&ecirc; estes dados apenas se tiver permiss&atilde;o. O &iacute;ndice de mensagem pode ser ordenado por os dados de resumo, se ele tem permiss&atilde;o para classificar pelo campo.<br />
Usando templates que podem ser inseridos os dados estat&iacute;sticos de qualquer grupo de campos em outro lugar.';
$helptxt['cffp_search_page'] = (!$smf_version_1 ? 'Sob a op&ccedil;&atilde;o &quot;Pesquisa&quot; a partir do f&oacute;rum menu p&aacute;ginas de pesquisa est&atilde;o localizados' : 'A op&ccedil;&atilde;o &quot;Pesquisa de posts e registros&quot; a partir do menu f&oacute;rum fornece acesso &agrave;s p&aacute;ginas de pesquisa') . ', mostrando os grupos e seus campos no qual o usu&aacute;rio tem permiss&atilde;o de busca.<br />
Grupos de tipo &quot;campos soltos&quot;, &quot;campos com cadaa valor por membro&quot; e &quot;filtro&quot; pode ser em cada p&aacute;gina de pesquisa, e cada p&aacute;gina cont&eacute;m v&aacute;rios grupo, com a &uacute;nica condi&ccedil;&atilde;o de que os grupos em uma p&aacute;gina deve ser permitida em um conjunto comum de mensagens. Como resultado de pesquisa uma lista de postos &eacute; obtido.<br />
Para cada grupo de tipo &quot;registro&quot; com a permiss&atilde;o de busca tem uma p&aacute;gina. Como resultado, uma lista de registos &eacute; obtido com as colunas indicadas na defini&ccedil;&atilde;o dos campos.';
$helptxt['cffp_profile_list'] = 'No perfil de membro, na se&ccedil;&atilde;o &quot;Informa&ccedil;&otilde;es do Perfil &gt; Ver Posts&quot;, pode mostrar uma lista para cada grupo de tipo &quot;gravar&quot;, com mensagens postadas pelo pr&oacute;prio usu&aacute;rio contendo este tipo de grupo.';
if (!$smf_version_1)
{
$helptxt['cffp_moderation_list'] = 'No Comando do moderador &eacute; poss&iacute;vel controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
Para cada grupo que escolheu para mostrar esta lista ser&aacute; exibido um acesso &agrave; lista na se&ccedil;&atilde;o &quot;Posts &gt; Grupos de campos em posts&quot; e, opcionalmente, um link abaixo da op&ccedil;&atilde;o &quot;Moderado&quot; a partir do menu de f&oacute;rum.';
}
else
{
$helptxt['cffp_moderation_list'] = 'Moderadores globais podem controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
A op&ccedil;&atilde;o &quot;Moderar os grupos de campos nas mensagens&quot; a partir do menu f&oacute;rum fornece acesso &agrave; lista com dados lan&ccedil;ados, um para cada grupo, que escolheu para mostrar esta lista.';
}
$helptxt['cffp_template_text'] = 'Texto usado para exibir o conte&uacute;do de campos em grupo.<br />
Você pode usar as seguintes vari&aacute;veis:<br />
<ul class="normallist">
<li><tt>{FIELD_</tt><i>n</i><tt>_NAME}</tt> - Nome de campo ID <i>n</i>.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_VALUE}</tt> - Valor de campo ID <i>n</i>.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_DATABASE}</tt> - O nome do campo no banco de dados do campo ID <i>n</i>. O campo pode ser de qualquer grupo.</li>
<li><tt>{ID_MSG}</tt> - ID da mensagem atual.</li>
<li><tt>{BOARDURL}</tt> - URL para pasta f&oacute;rum.</li>
<li><tt>{SCRIPTURL}</tt> - Endere&ccedil;o Web do f&oacute;rum.</li>
<li><tt>{IMAGES_URL}</tt> - URL para pasta de imagens no usu&aacute;rios tema atual.</li>
<li><tt>{DEFAULT_IMAGES_URL}</tt> - URL para pasta de imagens no tema padr&atilde;o.</li>
</ul>
No PHP, voc&ecirc; tamb&eacute;m pode usar as seguintes fun&ccedil;&otilde;es:<br />
<ul class="normallist">
<li><tt>{SHOW_GROUP_MSG}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>)</tt> - Exibe o grupo de uma mensagem como em uma mensagem.</li>
<li><tt>{SHOW_GROUP_MSGINDEX}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>)</tt> - Exibe o grupo de uma mensagem como no &iacute;ndice de mensagens.</li>
<li><tt>{SHOW_GROUP_MSG_STATS}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>, &apos;</tt><i>type</i><tt>&apos;, &apos;</tt><i>params</i><tt>&apos;)</tt> - Exibe as estat&iacute;sticas para o grupo de uma mensagem (se s&atilde;o ativados). O par&acirc;metro <i>tipo</i> pode ser:
<ul class="normallist">
<li><tt>chart_average</tt> - Exibe o gr&aacute;fico com a m&eacute;dia. o par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>m&eacute;dia</tt> (valor m&eacute;dio mostrado), <tt>minmax</tt> (valor mais baixo e mais alto permitido mostrado), <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
<li><tt>chart_hbars</tt> - Exibe o gr&aacute;fico com barras horizontais. o par&acirc;metro <i>params</i> n&atilde;o &eacute; utilizada.</li>
<li><tt>chart_vbars</tt> - Exibe o gr&aacute;fico com barras verticais. o par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
<li><tt>summary</tt> - Exibe o resumo. o par&acirc;metro<i>params</i> indica valores para mostrar, separados por v&iacute;rgulas. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>maior</tt> (maior valor usado), <tt>menor</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
<li><tt>value</tt> - Exibe um valor de resumo. o par&acirc;metro <i>params</i> indica o valor a ser exibido. Os valores permitidos: <tt>m&eacute;dia</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>maior</tt> (maior valor usado), <tt>menor</tt> (menor valor utilizado), <tt>most_frequent</tt> (valor mais frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
</ul></li>
</ul>
Esvazie o campo de texto para excluir o modelo. Se o modelo n&atilde;o est&aacute; campos definidos s&atilde;o exibidos com o seu nome e conte&uacute;do.';
$helptxt['cffp_template_message_index_text'] = $helptxt['cffp_template_text'];
$helptxt['cffp_template_quick_input'] = 'Texto usado para criar um registro.<br />
Permite que preencher todos os campos de uma s&oacute; vez, escrevendo todos os valores em um &uacute;nico campo, chamado <strong>Campo de entrada r&aacute;pida</strong>, de acordo com um modelo ou uma express&atilde;o regular.<br />
A express&atilde;o regular deve ser compat&iacute;vel com JavaScript. usado em <tt>String.match(regex)</tt> m&eacute;todo e deve ser obtida uma matriz de valores de campo come&ccedil;ando com a tecla 1.<br />
The par&acirc;metros de template consistem em linhas de texto:<br />
<ul class="normallist">
<li>Para cada elemento da matriz obtida a partir da express&atilde;o regular acrescenta uma linha com o campo ID.</li>
<li>Linhas que seguem a ordem da matriz.</li>
<li>Se um elemento de matriz n&atilde;o corresponde a qualquer campo, cont&eacute;m texto n&atilde;o utilizado e em que a linha &eacute; escrito 0.</li>
<li>Se &eacute; necess&aacute;rio formatar um valor antes de copi&aacute;-lo em seu campo, sob a linha que cont&eacute;m o ID campo outra linha &eacute; adicionado com o c&oacute;digo JavaScript que transforma o valor. <tt>valor</tt> vari&aacute;vel cont&eacute;m o valor original e deve conter o valor transformado. com <tt>field_obj</tt> array, indexado pelo campo ID, n&atilde;o h&aacute; acesso a todos os campos do formul&aacute;rio no registro.</li>
</ul>
Por exemplo, se o registro tem esses campos<br />
<br />
<table>
<thead>
<tr>
<th>Nome</th>
<th>ID</th>
</tr>
</thead>
<tbody>
<tr>
<td>ID DocBook</td>
<td>3</td>
</tr>
<tr>
<td>Autor Nome</td>
<td>1</td>
</tr>
<tr>
<td>Autor sobrenome</td>
<td>2</td>
</tr>
</tbody>
</table>
<br />
&eacute; definida<br />
<br />
Express&atilde;o regular: <tt>/^(.+)\s+(.+)\s+(.+)\s*/</tt><br />
Par&acirc;metros:<br />
<tt>3<br />
1<br />
var x = value.split(/\s+/g); for (var i = 0; i < x.length; i++) { var parts = x[i].match(/(\w)(\w*)/); x[i] = parts[1].toUpperCase() + parts[2].toLowerCase(); } value = x.join(&quot; &quot;);<br />
2<br />
var x = value.split(/\s+/g); for (var i = 0; i < x.length; i++) { var parts = x[i].match(/(\w)(\w*)/); x[i] = parts[1].toUpperCase() + parts[2].toLowerCase(); } value = x.join(&quot; &quot;);</tt><br />
<br />
e usu&aacute;rio escreve<br />
<br />
<tt>24<br />
LEWIS CARROLL</tt><br />
<br />
campos ser&atilde;o preenchidos, assim,:<br />
<br />
ID DocBook: 24<br />
Autor Nome: Lewis<br />
Autor sobrenome: Carroll';
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on January 19, 2015, 05:29:56 PM
Please, you create the custom counter  :laugh:
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: moyack on January 20, 2015, 09:54:24 AM
Hello:

First of all, great mod!!! this, in my humble opinion, should be a default feature in SMF, it would make it extremely powerful.

I have one question, is it possible set a upload image field, linking it into one attachment in the first post of a topic? I plan to make a "submit a resource" board where people can upload files and a screenshot.

Thanks in advance for your support. :)
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on January 21, 2015, 08:37:37 AM
Hello,
Is it possible that custom fields are required for all users?
Yes. Do this:
1. Check Not empty value,  on setting field.
2. Check permissions to all users for view, on setting field.
3. Check permissions to all users for view and modify, on setting group.



I do not know about php, but if I have something wrong, let me know.

I'll do a review
Thanks. On next update I will fix bugs and add your language (I will add as portuguese brazilian and portugal). ;)

Please, you create the custom counter  :laugh:
I have this in mind.



Hello:

First of all, great mod!!! this, in my humble opinion, should be a default feature in SMF, it would make it extremely powerful.

I have one question, is it possible set a upload image field, linking it into one attachment in the first post of a topic? I plan to make a "submit a resource" board where people can upload files and a screenshot.

Thanks in advance for your support. :)
Thanks for your words. :)

About your question... sorry but it is not possible, you can not upload images with this mod. :(

But... if you have an image on a server, you can view this image in a field:

Create a custom field
Quote
Name = Image
Field description = Write image URL
Show enclosed within text Type = HTML; Content =
Code: [Select]
<img src="{INPUT}">

When you see this post, image url will be replace by image.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: digger on January 23, 2015, 08:39:10 AM
davidhs,
Thank you for improvements in the latest mod version. But, there are a few new requests :)
Filter "First character of the subject" shows only the English alphabet. What to do with national letters?
And, can you add an option to display this filter not only as a drop-down list, but the line of letters < A B C ... > like alphabet от the forum members list page.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on January 23, 2015, 11:13:19 AM
Filter "First character of the subject" shows only the English alphabet. What to do with national letters?
This mod do this. Use your forum language. Now only works in English and Spanish because my mod is translated only in these languages. When I add Portuguese translation (by Americano), works also in Portuguese.

If you select English or Spanish language on your forum, this mod use letters of
- English alphabet (A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z) or
- Spanish alphabet (A,B,C,D,E,F,G,H,I,J,K,L,M,N,Ñ,O,P,Q,R,S,T,U,V,W,X,Y,Z).

If your forum use other language (for example Russian :) ) my mod have not Russian translation and use English alphabet. If you can/want to do the Russian translate of this mod I will add. ;)

And, can you add an option to display this filter not only as a drop-down list, but the line of letters < A B C ... > like alphabet от the forum members list page.
I will see but I am not sure about this.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on January 24, 2015, 03:14:58 PM
I corrected some errors.

Modifications.portuguese_brazilian.php

Code: [Select]
// Version: 2.0; Modifications

// BEGIN MOD CustomFieldFilterPost
$txt['cffp'] = 'Campos personalizados e filtros de mensagens';
$txt['cffp_desc'] = 'Painel de administra&ccedil;&atilde;o para o &quot; Os campos personalizados e filtros de mensagens &quot; MOD';
$txt['cffp_settings_display'] = 'Defini&ccedil;&otilde;es do campo';
$txt['cffp_settings_input'] = 'Configura&ccedil;&otilde;es de entrada';
$txt['cffp_settings_advanced'] = 'Ferramentas extras';
$txt['cffp_settings_grouptype'] = 'Configura&ccedil;&otilde;es para o tipo de &quot;%s&quot;'; // %s is a group type
$txt['cffp_field'] = 'Campo';
$txt['cffp_fields'] = 'Campos';
$txt['cffp_group'] = 'Grupo';
$txt['cffp_group_of_fields'] = 'Grupo de campos';
$txt['cffp_none_field'] = 'Voc&ecirc; n&atilde;o adicionou nenhum campo para o grupo!';
$txt['cffp_none_group'] = 'Voc&ecirc; n&atilde;o criou nenhum grupo de campos personalizados ainda!';
$txt['cffp_order'] = 'Ordem';
$txt['cffp_order_desc'] = 'Ordem do Display.';
$txt['cffp_text'] = 'Texto';
$txt['cffp_name'] = 'Nome';
$txt['cffp_field_description'] = 'Descri&ccedil;&atilde;o do campo';
$txt['cffp_field_description_desc'] = 'Exibido junto ao nome do.';
$txt['cffp_description'] = 'Descri&ccedil;&atilde;o';
$txt['cffp_text_previous'] = 'Texto anterior';
$txt['cffp_text_previous_desc'] = 'HTML para colocar antes do bot&atilde;o de entrada e sa&iacute;da do texto. Se o campo "Exibe fechado dentro do texto" &eacute; utilizada para o texto de sa&iacute;da deve ser escrito <tt>{TEXT_PREVIOUS}</tt> vari&aacute;vel nesse.';
$txt['cffp_text_next'] = 'Pr&oacute;ximo texto';
$txt['cffp_text_next_desc'] = 'HTML para colocar depois do bot&atilde;o de entrada e fim do texto. Se o campo "Exibe anexado dentro do texto" &eacute; utilizada para o texto de sa&iacute;da deve ser escrito <tt>{TEXT_NEXT}</tt> vari&aacute;vel nesse.';
$txt['cffp_enclose'] = 'Mostrar anexado dentro do texto';
$txt['cffp_enclose_desc'] = 'N&oacute;s <strong>fortemente</strong> recomendamos usar uma m&aacute;scara de entrada para validar a entrada fornecida pelo utilizador.';
$txt['cffp_text_input_before'] = 'Texto no display antes dos campos quando entrar com os dados';
$txt['cffp_text_input_before_desc'] = 'Admite BBC.';
$txt['cffp_text_input'] = 'Texto a ser exibido ao digitar os dados';
$txt['cffp_text_input_desc'] = 'Admite BBC.';
$txt['cffp_text_output'] = 'Texto a ser exibido durante a visualiza&ccedil;&atilde;o de dados';
$txt['cffp_text_output_desc'] = 'Admite BBC.';
$txt['cffp_type'] = 'Tipo';
$txt['cffp_type_filter'] = 'Tipo de campo';
$txt['cffp_type_filter_desc'] = 'Tipo de acionamento usado no filtro de indicador de mensagens e T&oacute;picos de pesquisa.';
$txt['cffp_fieldtype_text'] = 'Texto';
$txt['cffp_fieldtype_textarea'] = 'Grande texto';
$txt['cffp_fieldtype_select'] = 'Caixa de escolha';
$txt['cffp_fieldtype_combobox'] = 'Caixa de combina&ccedil;&atilde;o';
$txt['cffp_fieldtype_radio'] = 'Acionamento tipo Radio';
$txt['cffp_fieldtype_check'] = 'Caixas de sele&ccedil;&atilde;o';
$txt['cffp_fieldtype_boolean'] = 'Booleano';
$txt['cffp_grouptype_fields'] = 'Campos soltos';
$txt['cffp_grouptype_record'] = 'Campos personalizados';
$txt['cffp_grouptype_member'] = 'Os campos com v&aacute;rios valores por membro';
$txt['cffp_grouptype_filters'] = 'Filtros de busca';
$txt['cffp_length'] = 'O comprimento m&aacute;ximo de dados';
$txt['cffp_length_desc'] = '0 por nenhum limite.';
$txt['cffp_length_text_desc'] = 'A largura do campo proporcional a este valor. Se for 0 ou maior do que ou igual a 100, o campo ocupa a largura total.';
$txt['cffp_dimension'] = 'Medida da largura';
$txt['cffp_dimension_row'] = 'Fileiras';
$txt['cffp_dimension_col'] = 'Colunas';
$txt['cffp_dimension_col_desc'] = 'Se o &quot; Colunas&quot; se 0 ou maior do que ou igual a 100, o campo ocupa a largura total.';
$txt['cffp_mask'] = 'Disfarce de entrada';
$txt['cffp_mask_desc'] = 'Para campos de texto de um disfarce de entrada pode ser selecionado para validar os dados.';
$txt['cffp_mask_email'] = 'Email';
$txt['cffp_mask_number'] = 'N&uacute;mero';
$txt['cffp_mask_nohtml'] = 'Nunhum HTML';
$txt['cffp_mask_regex'] = 'Comando regular (Extra)';
$txt['cffp_select_multiple'] = 'Selecionar mais de um';
$txt['cffp_select_size'] = 'Quantidade de campos vistos';
$txt['cffp_allow_bbc'] = 'Permitir BBC';
$txt['cffp_options'] = 'Escolhas';
$txt['cffp_options_desc'] = 'Deixe a caixa de escolha em branco para remover. Tecla de escolha ou caixa de escolha seleciona as alternativas marcadas..';
$txt['cffp_options_more'] = 'Mais';
$txt['cffp_options_add_multi'] = 'Adicionar mais de uma escolha';
$txt['cffp_options_add_multi_desc'] = 'Escreva uma escolha em cada linha. Cada escolha tem valor e texto, separados por virgulas. Texto opcional.';
$txt['cffp_options_add_multi_combo_desc'] = 'Escreva um alternativa para cada linha';
$txt['cffp_default_value'] = 'Valor oficial';
$txt['cffp_boards'] = 'Sub-F&oacute;runs';
$txt['cffp_child_boards'] = 'Incluir Sub-F&oacute;runs descendentes';
$txt['cffp_child_boards_until'] = 'At&eacute; %d n&iacute;vel';
$txt['cffp_show_group_name_message_index'] = 'Ver nome do grupo no &iacute;ndice da mensagem';
$txt['cffp_show_group_name_message_index_desc'] = 'Se nenhum grupo for selecionado, nenhum grupo exibido no &iacute;ndice da mensagem.';
$txt['cffp_show_group_name_filter'] = 'Ver o nome do grupo nos filtros';
$txt['cffp_show_group_name_filter_desc'] = 'Se nenhum nome de grupo de filtros for selecionado, nenhum grupo exibido no &iacute;ndice da mensagem.';
$txt['cffp_show_group_name_search'] = 'Ver o nome do grupo na busca';
$txt['cffp_show_group_name_search_desc'] = 'Se nenhum nome de grupo for selecionado, nenhum gropo exibido na busca.';
$txt['cffp_show_fields_name'] = 'Ver nome dos campos';
$txt['cffp_show_fields_name_desc'] = 'Se nenhum nome for selecionado, nada exibido ao lado dos campos do grupo.';
$txt['cffp_show_fields_set'] = 'Ver campos como um conjunto';
$txt['cffp_show_fields_set_desc'] = 'Se selecionado os campos, agrupa-se sob o nome do grupo.';
$txt['cffp_show_empty_fields_post'] = 'Ver campos vazios na mensagem';
$txt['cffp_show_empty_fields_message_index'] = 'Ver campos vazios no &iacute;ndice da mensagem';
$txt['cffp_show_actions_as'] = 'Ver atos como';
$txt['cffp_show_actions_as_button'] = 'Teclas';
$txt['cffp_show_actions_as_icon_text'] = 'Elemento e texto';
$txt['cffp_show_actions_as_icon'] = 'Elementos';
$txt['cffp_show_actions_as_text'] = 'Texto';
$txt['cffp_show_member_expanded'] = 'Ver expandido';
$txt['cffp_show_member_expanded_data'] = 'Ver expandido os dados postados';
$txt['cffp_show_member_expanded_data_recent'] = 'Ver expandido o mais recente dados postados';
$txt['cffp_show_member_expanded_data_recent_desc'] = '0 para todos.';
$txt['cffp_show_member_expanded_new'] = 'Ver expandido o nova respota';
$txt['cffp_show_member_recent_at_top'] = 'Ver o mais recente dados da mensagens no topo';
$txt['cffp_member_max_height'] = 'Maior altura do campo dos dados postados';
$txt['cffp_member_max_height_px'] = 'px';
$txt['cffp_member_max_height_desc'] = '0 para ilimitado.';
$txt['cffp_show_sticky'] = 'Ver em t&oacute;picos fixos';
$txt['cffp_show_locked'] = 'Mostrar em t&oacute;picos bloqueados';
$txt['cffp_show_first_post_topic'] = 'Ativar na primeira mensagem do t&oacute;pico';
$txt['cffp_show_replies_topic'] = 'Ativar nas respostas do t&oacute;pico';
$txt['cffp_no_show_with_subject_prefix'] = 'Exibir nenhum campo para inserir junto ao assunto';
$txt['cffp_no_show_with_subject_prefix_desc'] = 'Prefixos separados por v&iacute;rgulas. Exemplo:;.';
$txt['cffp_show_in_topic'] = 'Exibir como grupo de campos do t&oacute;pico';
$txt['cffp_show_in_topic_desc'] = 'Se o grupo estive no campo em apenas no primeiro post desde o t&oacute;pico pode ser visto como pertencente ao t&oacute;pico ao inv&eacute;s do post, e exibido em outra &aacute;rea do tema, diferente para postar.';
$txt['cffp_show_in_topic_no'] = 'Nenhum (O grupo visto no campo da primeira mensagem)';
$txt['cffp_show_in_topic_begin_all'] = 'Sim, no come&ccedil;o de todos as p&aacute;ginas do t&oacute;picos';
$txt['cffp_show_in_topic_end_all'] = 'Sim, inserido no fim de todas as p&aacute;ginas do t&oacute;picos';
$txt['cffp_show_in_topic_begin_first'] = 'Sim, no come&ccedil;o da primeira p&aacute;gina do t&oacute;picos';
$txt['cffp_show_in_topic_end_first'] = 'Sim, no final do primeira p&aacute;gina do t&oacute;picos';
$txt['cffp_show_filters'] = 'Filtros';
$txt['cffp_show_filters_desc'] = 'Selecionar o filtro a ser utilizado.';
$txt['cffp_show_filters_boards'] = 'Sub-F&oacute;runs';
$txt['cffp_show_filters_subject_start'] = 'Comece do assunto';
$txt['cffp_show_filters_subject_first_char'] = 'Primeiro caractere do sujeito';
$txt['cffp_show_filters_date_topic'] = 'Dados do t&oacute;picos';
$txt['cffp_show_filters_date_replies'] = 'Dados da &uacute;ltima resposta';
$txt['cffp_show_filters_date_lastdays'] = 'Último %s dias';
$txt['cffp_show_filters_topic_new_posts'] = 'T&oacute;picos com novos post';
$txt['cffp_show_filters_sticky'] = 'Fixos';
$txt['cffp_show_filters_sticky_disabled'] = 'T&oacute;picos fixos desativados. O Filtro n&atilde;o ser&aacute; exibido.';
$txt['cffp_show_filters_locked'] = 'Trancado';
$txt['cffp_show_filters_sticky_locked'] = 'Fixos e trancados';
$txt['cffp_javascript'] = 'C&oacute;digo JavaScript';
$txt['cffp_javascript_desc'] = 'C&oacute;digo executado quando um grupo de campos for criado ou modificado.';
$txt['cffp_search_page'] = 'Procurar t&oacute;picos';
$txt['cffp_search_page_post_desc'] = 'Escrever o nome dos t&oacute;picos e seleccione a ordem dos resultados de cada. Para remover um tema simplesmente esvaziar a caixa de texto para esse tema. Para adicionar um tema j&aacute; existente, selecione-o na lista.';
$txt['cffp_search_page_post_default'] = 'T&oacute;picos predefinidos';
$txt['cffp_search_page_post_more'] = 'Mais';
$txt['cffp_search_page_post_add'] = 'Adicionar um t&oacute;picos existente';
$txt['cffp_search_page_record_desc'] = 'Predefinido: &quot;Procurar por...&quot;.';
$txt['cffp_search_page_order_by'] = 'Ordenar resultados da pesquisa por';
$txt['cffp_search_page_order_by2'] = 'Ordenar por';
$txt['cffp_search_page_order_by_desc'] = 'Para que um campo seja mostrado aqui, deve ser exibido em uma coluna com apenas esse campo ou seja o primeiro campo na coluna.';
$txt['cffp_profile_list'] = 'Lista no perfil de membro';
$txt['cffp_profile_list_desc'] = 'Nome predefinido: Nome do grupo.';
$txt['cffp_profile_list_show'] = 'Exibir lista';
$txt['cffp_profile_list_name'] = 'Nome';
$txt['cffp_moderation_list'] = 'Lista no centro de Moderar';
$txt['cffp_moderation_list_desc'] = 'Nome predefinido: Nome do grupo. Para que um campo seja mostrado aqui, deve ser exibido em uma coluna com apenas esse campo ou seja o primeiro campo na coluna.';
$txt['cffp_moderation_list_show'] = 'Exibir lista';
$txt['cffp_moderation_list_menu'] = 'Exibir link no menu do F&oacute;rum';
$txt['cffp_moderation_list_name'] = 'Nome';
$txt['cffp_moderation_list_order_by'] = 'Ordenar por';
$txt['cffp_show_message_index'] = 'Exibir no &iacute;ndice de mensagens';
$txt['cffp_show_message_index_desc'] = 'Aplica-se, se for no primeiro post do t&oacute;picos.';
$txt['cffp_filter_message_index'] = 'Filtrar o &iacute;ndice de mensagens';
$txt['cffp_filter_message_index_desc'] = 'Mostra um tecla no &iacute;ndice de mensagens para filtrar t&oacute;picos por este campo.';
$txt['cffp_show_record_list_type'] = 'Mostrar em listas de registros';
$txt['cffp_show_record_list_type_desc'] = 'Mostra este campo em uma coluna das listas de registros (por exemplo, na busca de registos).';
$txt['cffp_show_moderation_list_type'] = 'Show on lists of Moderation Center';
$txt['cffp_show_moderation_list_type_desc'] = 'Mostra este campo em uma coluna das listas de Centro de Moderar.';
$txt['cffp_show_list_type_no'] = 'Nenhum';
$txt['cffp_show_list_type_one'] = 'Sim, em uma coluna com apenas este campo';
$txt['cffp_show_list_type_multi'] = 'Sim, em uma coluna juntamente com outros campos';
$txt['cffp_show_list_width'] = 'A largura da coluna';
$txt['cffp_show_list_width_desc'] = '0 para automatizado.';
$txt['cffp_show_list_width_unit_auto'] = 'Automatizado';
$txt['cffp_show_list_width_unit_%'] = 'Incostante';
$txt['cffp_show_list_width_unit_px'] = 'Fixo';
$txt['cffp_show_list_column'] = 'Coluna com variados campos';
$txt['cffp_show_list_column_other'] = 'Outro...';
$txt['cffp_show_list_name'] = 'Nome da coluna';
$txt['cffp_show_list_name_desc'] = 'Se n&atilde;o for especificado a coluna conter&aacute; somente neste campo.';
$txt['cffp_not_empty_value'] = 'N&atilde;o tem valor vazio';
$txt['cffp_not_empty_value_desc'] = 'Se selecionado este campo n&atilde;o pode ser deixado em branco.';
$txt['cffp_unique_value'] = 'Valor &uacute;nico';
$txt['cffp_unique_value_desc'] = 'Se selecionado n&atilde;o pode ter dois valores iguais neste campo.';
$txt['cffp_subset'] = 'Subconjunto';
$txt['cffp_subset_desc'] = 'O campo &eacute; exibido dentro de um subconjunto. Os campos de um subconjunto devem ser adjacentes.';
$txt['cffp_permissions'] = 'Permiss&otilde;es';
$txt['cffp_permissions_field_desc'] = 'As a&ccedil;&otilde;es que um membro pode executar ao longo deste campo, sujeitos &agrave;s permiss&otilde;es do f&oacute;rum.';
$txt['cffp_permissions_group_desc'] = 'As a&ccedil;&otilde;es que um membro pode executar ao longo deste grupo, sujeitos &agrave;s permiss&otilde;es do f&oacute;rum.';
$txt['cffp_owner_post'] = 'Dono da mensagem';
$txt['cffp_owner_group'] = 'Dono do grupo';
$txt['cffp_local_moderator'] = 'Moderador local';
$txt['cffp_global_moderator'] = 'Moderador global';
$txt['cffp_administrator'] = 'Administrador';
$txt['cffp_view_message_index'] = 'Veja no &iacute;ndice de mensagens';
$txt['cffp_add'] = 'adicionar';
$txt['cffp_move'] = 'Mover';
$txt['cffp_active'] = 'Ativo';
$txt['cffp_active_field_desc'] = 'Se n&atilde;o for selecionado este campo n&atilde;o ser&aacute; mostrado a ningu&eacute;m.';
$txt['cffp_active_group_desc'] = 'Se n&atilde;o for selecionado este grupo n&atilde;o ser&aacute; mostrado a ningu&eacute;m.';
$txt['cffp_more_info'] = 'Mais informa&ccedil;&otilde;es';
$txt['cffp_id'] = 'ID';
$txt['cffp_make_new_field'] = 'Novo campo';
$txt['cffp_make_new_group'] = 'Novo grupo';
$txt['cffp_add_field_title'] = 'Adicionar campo';
$txt['cffp_add_group_title'] = 'Adicionar grupo de campos';
$txt['cffp_edit_field_title'] = 'Editar campo';
$txt['cffp_edit_group_title'] = 'Editar grupo de campos';
$txt['cffp_edit_delete_field_sure'] = 'Tem certeza de que deseja apagar este campo? Todos os dados da mensagens relacionados ser&atilde;o perdidos!';
$txt['cffp_edit_delete_group_sure'] = 'Tem certeza de que deseja excluir este grupo? Todos os dados da mensagens relacionados ser&atilde;o perdidos!';
$txt['cffp_template'] = 'Template para mensagens';
$txt['cffp_template_message_index'] = 'Template para &iacute;ndice de mensagem';
$txt['cffp_template_quick_input'] = 'Template para entrada r&aacute;pida';
$txt['cffp_template_quick_input_regex'] = 'Express&atilde;o regular';
$txt['cffp_template_quick_input_regex_desc'] = 'Compat&iacute;vel com JavaScript. Usado em <tt>String.match(regex)</tt> m&eacute;todo e deve ser obtida uma matriz de valores de campo come&ccedil;ando com a tecla 1.';
$txt['cffp_template_quick_input_params'] = 'Par&acirc;metros';
$txt['cffp_template_quick_input_params_desc'] = 'Para cada elemento da matriz obtida a partir da express&atilde;o regular acrescenta uma linha com o campo ID, ou 0 se ele n&atilde;o corresponder a qualquer campo. Para a formata&ccedil;&atilde;o de um valor antes de copi&aacute;-lo em seu campo, abaixo do campo de ID para adicionar outra linha com o c&oacute;digo JavaScript.<tt>valor</tt>vari&aacute;vel cont&eacute;m o valor original e deve conter o valor transformado. Com <tt>field_obj [</tt>FIELD_ID<tt>]</tt> pode acessar um campo de formul&aacute;rio.';
$txt['cffp_template_quick_input_help'] = 'Ajuda';
$txt['cffp_template_quick_input_help_desc'] = 'Texto que o utilizador ver&aacute; em vez da express&atilde;o regular. permitir BBC.';
$txt['cffp_template_type_html'] = 'HTML';
$txt['cffp_template_type_bbc'] = 'BBC';
$txt['cffp_template_type_php'] = 'PHP';
$txt['cffp_add_templates'] = 'Adicionar templates';
$txt['cffp_edit_templates'] = 'Editar templates';
$txt['cffp_warning_cannot_see_group_fields'] = 'Voc&ecirc; n&atilde;o pode ver os campos deste grupo.';
$txt['cffp_warning_group_subject'] = 'Esses campos ser&atilde;o removidos se o post sujeito come&ccedil;a com: %s.';
$txt['cffp_quick_input_field'] = 'Campo de entrada r&aacute;pida';
$txt['cffp_quick_input_field_desc'] = 'Escrever valores para entrar em campos diferentes de acordo com esta express&atilde;o regular:';
$txt['cffp_quick_input_match'] = 'Os campos s&atilde;o preenchidos.';
$txt['cffp_quick_input_no_match'] = 'Conteúdo do "campo de entrada r&aacute;pida" n&atilde;o est&aacute; formatado corretamente. Campos n&atilde;o pode ser preenchido.';
$txt['cffp_quick_input_apply'] = 'Preencha os campos';
$txt['cffp_created'] = 'Criado';
$txt['cffp_edit_group'] = 'Editar %s';
$txt['cffp_show'] = 'Exibir';
$txt['cffp_show_previous'] = 'Mostrar anterior';
$txt['cffp_move_to_first_post'] = 'Mover-se para o primeiro post neste t&oacute;picos';
$txt['cffp_move_to_other_post'] = 'Mover-se para um outro post';
$txt['cffp_move_to_other_topic'] = 'Mover-se para um outro t&oacute;picos';
$txt['cffp_move_group_to_other_post'] = 'Mover-se %s para outro post';
$txt['cffp_move_group_to_other_topic'] = 'Mover-se %s para outro t&oacute;picos';
$txt['cffp_move_to_post'] = 'Mover-se para o post';
$txt['cffp_move_to_post_desc'] = 'Publicar ID. exemplo:index.php?topic=4043.msg23892, use 23892.';
$txt['cffp_move_to_topic'] = 'Mover-se para o t&oacute;picos';
$txt['cffp_move_to_topic_desc'] = 'T&oacute;picos ID. Exemplo: index.php?topic=4043.0, use 4043.';
$txt['cffp_filter'] ='Filtro';
$txt['cffp_search_posts'] = 'Procurar posts';
$txt['cffp_search_posts_desc'] = 'Escreva o texto e / ou selecione as op&ccedil;&ccedil;&otilde;s nos campos em que deseja pesquisar. Você vai ter uma lista de posts que contenham esses valores em seus campos.';
$txt['cffp_search_records_type'] = 'Pesquisar registros do tipo %s';
$txt['cffp_search_records_desc'] = 'Escreva o texto e / ou selecione as op&ccedil;&ccedil;&otilde;s nos campos em que deseja pesquisar. Você vai ter uma lista de registros que contêm esses valores em seus campos.';
$txt['cffp_show_fields'] = 'Mostrar campos';
$txt['cffp_hide_fields'] = 'Ocultar campos';
$txt['cffp_record_type'] = 'Registros do tipo %s';
$txt['cffp_moderation_area'] = 'Grupos de campos em postes';
$txt['cffp_moderation_area_desc'] = 'Aqui voc&ecirc; pode rever todos os dados postados por membros em grupos de campos personalizados.';
$txt['cffp_moderation_area_delete_sure'] = 'Tem certeza de que deseja apagar estes dados?';
$txt['cffp_moderation_area_none'] = 'N&atilde;o existem dados publicados';
$txt['cffp_poster_time'] = 'Dados postados';
$txt['cffp_topic_without_replies'] = 'T&oacute;picos sem respostas';
$txt['cffp_symbol'] = 'S&iacute;mbolo';
$txt['cffp_number'] = 'Número';
$txt['cffp_alphabet_letters'] = 'A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z'; //Alfabeto Inglês (letras maiúsculas separados por vírgula)
$txt['cffp_field_empty_value'] = 'Nenhum dados';
$txt['cffp_field_non_empty_value'] = 'H&aacute; dados';
$txt['cffp_filtertype_empty_non_empty'] = $txt['cffp_field_empty_value'] . ' / ' . $txt['cffp_field_non_empty_value'];
$txt['cffp_order_by_asc'] = 'Ordem ascendente';
$txt['cffp_order_by_desc'] = 'Ordem decrescente';
$txt['cffp_wireless_end_group'] = 'Fim %s';
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on January 24, 2015, 03:17:05 PM
Help.portuguese_brazilian.php

Code: [Select]
// BEGIN MOD CustomFieldFilterPost
global $forum_version;
$smf_version_1 = 0 === strpos($forum_version, 'SMF 1');
$helptxt['cffp'] = '<b>Campos personalizados e filtros de mensagens</b><br />
Permite adicionar diferentes grupos de campos personalizados para posts no f&oacute;rum e filtros para os campos de mensagens.<br />
Um grupo de campos podem ser do tipo:<br />
<ul class="normallist">
<li>Campos soltos: Seus campos são adicionados a um post para fornecer informa&ccedil;&otilde;es extra. Na busca de dados em campos soltos de um post &eacute; obt&eacute;m uma lista de posts.</li>
<li>Registros: &Eacute; um conjunto de campos que representa uma entidade independente do post. Na busca de dados em campos de um registro é obt&eacute;m-se uma lista de registros. O corpo do post n&atilde;o pode ser deixado em branco, mas um post com registro n&atilde;o precisa de corpo. Se o usu&aacute;rio ir&aacute; adicionar um registro e o corpo do post estiver vazio, o sistema grava um per&iacute;odo(&quot;.&quot;) sobre ele e o usu&aacute;rio n&atilde;o precisa escrever nada.</li>
<li>Os campos com v&aacute;rios valores por membro: &Eacute; um conjunto de campos onde v&aacute;rios usu&aacute;rios podem inserir valores diferentes. Isso pode ser usado para os membros para fazer coment&aacute;rios ou avalia&ccedil;&otilde;es sobre o post. Se esses campos est&atilde;o localizados em apenas na primeira mensagem de um t&oacute;pico pode ser apresentado como pertencente ao t&oacute;pico.</li>
<li>Filters: Este &eacute; um tipo especial de grupo sem campos. Usado para habilitar um conjunto de filtros pr&eacute;-definidos que podem ser usados em t&oacute;picos e mensagens.</li>
</ul>
Os filtros predefinidos dispon&iacute;veis s&atilde;o:<br />
<ul class="normallist">
<li>Sub-F&oacute;rum.</li>
<li>Assunto.</li>
<li>Come&ccedil;o do assunto.</li>
<li>Primeiro caractere do assunto.</li>
<li>Dados do t&oacute;pico / Dado publicado.</li>
<li>Dados da &uacute;ltima resposta / Dado publicado.</li>
<li>Postado por.</li>
<li>T&oacute;pico com novos posts / Novo.</li>
<li>Fixos.</li>
<li>Trancado.</li>
<li>Respostas.</li>
<li>Enquete.</li>
</ul>
As a&ccedil;&otilde;es a serem realizadas em um grupo de campos personalizados s&acirc;o: vis&acirc;o, adicionar, modificar, apagar e mover.<br />
Furthermore other actions are possible using custom fields:<br />
<ul class="normallist">
<li>Filtrar o &iacute;ndice de mensagens.</li>
<li>Organizar o &iacute;ndice de mensagens.</li>
<li>Mostrar estat&iacute;sticas.</li>
<li>Pesquisar nas &aacute;reas de mensagens, obter uma lista de posts.</li>
<li>Pesquisar nas &aacute;reas de registros, obtendo uma lista de registros.</li>
</ul>
<br />
<b>Painel de administra&ccedil;&atilde;o</b><br />
O painel de administra&ccedil;&atilde;o tem a lista dos grupos de campos personalizados, o que permite adicionar novos grupos, modificar ou excluir grupos existentes, adicionar, modificar ou excluir campos de um grupo e definir modelos para exibir esses campos em um post e no &iacute;ndice de mensagens.<br />
<br />
<b>Visualizando posts com campos personalizados</b><br />
Ao visualizar um post completo (em um t&oacute;pico, em posts ou perfil recentes) s&atilde;o apresentados seus grupos (que s&atilde;o ativados quando o post &eacute; criado ou modificado). Grupo do tipo &quot;solto campos&quot; e &quot;registros&quot; s&atilde;o mostrados acima do corpo do post, Considerando que os grupos de tipo &quot;campos com v&aacute;rios valores por membro&quot; s&atilde;o apresentados a seguir, a menos o que foi selecionado &quot;Mostrar como grupo de campos do t&oacute;pico&quot; e, em seguida, &eacute; apresentado no in&iacute;cio e/ou e do t&oacute;pico. Se um grupo tem o template por mensagens os campos s&atilde;o exibidos de acordo com o template, se n&atilde;o s&atilde;o exibidos com o seu nome e conte&uacute;do.<br />
Em listas de posts (&iacute;ndice de mensagens, mensagem n&atilde;o lida e respostas) s&atilde;o grupos exibida com campos vis&iacute;veis no &iacute;ndice de mensagem (de acordo com as permiss&otilde;es). Se um grupo tem o template para o &iacute;ndice de mensagem os campos s&atilde;o exibidos de acordo com o template, se n&atilde;o s&atilde;o exibidos com o seu nome e conte&uacute;do.<br />
<br />
<b>Modificando valores em campos personalizados</b><br />
Em um tópico, posts com grupos de tipo &quot;campos com v&aacute;rios valores por membro&quot;t&ecirc;m bot&ocirc;es para o usu&aacute;rio postar novos valores, e modificar ou remover os existentes.<br />
Para todos os outros grupos (&quot;campos solto&quot; e &quot;registro&quot;), a criar ou modificar o post s&atilde;o exibidos grupos permitidos. Os grupos de tipo &quot;solto campos&quot; sempre t&ecirc;m seus campos vis&iacute;veis, enquanto que os grupos de tipo &quot;registro&quot; tem uma caixa de sele&ccedil;&atilde;o para mostrar ou ocultar os seus campos. Se tem sido modelo criado para a entrada r&aacute;pida em um registro, <strong>Campo de entrada r&aacute;pida</strong> &eacute; exibido ap&oacute;s os campos de registro.<br />
<br />
<b>Movendo um grupo de campos personalizados para outro post</b><br />
Um grupo de campos pode ter de ser atribu&iacute;do a um outro post, por exemplo, antes de remover o post onde &eacute; o grupo.<br />
Se o utilizador tem permiss&atilde;o para mover um grupo, ao visualizar um tema que grupo ter&aacute; bot&otilde;es para ir para o primeiro post do t&oacute;pico ou outro post (ou outro t&oacute;pico se o grupo &eacute; do tipo &quot;campos com v&aacute;rios valores por membro&quot; e selecionou &quot; Mostrar como grupo de campos do t&oacute;pico&quot;).<br />
<br />
<b>Filtrar o &iacute;ndice de mensagens</b><br />
Se o utilizador tem permiss&atilde;o para filtrar por um campo, um bot&atilde;o &eacute; exibido no &iacute;ndice de mensagens para filtrar t&oacute;picos por esse campo.<br />
Tipo de bot&atilde;o de filtro depende do tipo de campo:<br />
<ul class="normallist">
<li>O filtro para o texto ou campos de texto grandes &eacute; um bot&atilde;o de texto em que entrar na cadeia de pesquisa, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
<li>Campos tipo caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de ter pelo filtro de um bot&atilde;o de texto, uma caixa de sele&ccedil;&atilde;o ou uma caixa de combina&ccedil;&atilde;o em que digitar ou selecionar o texto a procurar, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
<li>Para campos do tipo Booleano o filtro &eacute; uma caixa de sele&ccedil;&atilde;o com os valores &quot;Sim&quot; e &quot;Nenhum&quot;.</li>
</ul>
Se o usu&aacute;rio pode modificar um campo, que o campo pode estar vazio e seu filtro &eacute; uma caixa de sele&ccedil;&atilde;o ou caixa de combina&ccedil;&atilde;o, ele verá uma op&ccedil;&atilde;o na lista para obter dados com esse campo vazio.<br />
Al&eacute;m disso, com um grupo de tipo &quot;filtros&quot; podem ser adicionados filtros predefinidos.<br />
O filtro com o bot&atilde;o texto permite pesquisar palavras soltas (separados por espa&ccedil;os) e/ou fases literais (entre aspas duplas).<br />
Se o filtro &eacute; do tipo de texto ou caixa de combina&ccedil;&atilde;o, por padr&atilde;o, ele &eacute; procurado que o texto est&aacute; contido no valor do campo, enquanto que se o filtro &eacute; o tipo de lista de sele&ccedil;&atilde;o de caixa &eacute; pedido que o texto corresponde ao valor do campo.<br />
Os filtros podem ser do mesmo grupo ou grupos diferentes de campos.<br />
Ao lado de filtros h&aacute; um bot&atilde;o para ativar os filtros que foram dadas algum valor. Como resultado obt&eacute;m-se o &iacute;ndice de mensagens com t&oacute;picos cujo cargo primeira corresponde a todos os filtros ativos.<br />
<br />
<b>Organizar o &iacute;ndice de mensagens</b><br />
Se o usu&aacute;rio tem permiss&atilde;o para classificar por um ou mais campos, uma caixa de sele&ccedil;&atilde;o &eacute; exibido no &iacute;ndice de mensagens para classificar t&oacute;picos por um desses campos.<br />
<br />
<b>Mostrar estat&iacute;sticas</b><br />
Se um grupo de tipo &quot;campos com v&aacute;rios valores por membro&quot; tem um &uacute;nico campo e &eacute; de tyoe caixa de sele&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas (isto &eacute;, existe um n&uacute;mero finito de valores), pode ser gerar dados estat&iacute;sticos a partir dos valores inseridos no campo.<br />
Os dados estat&iacute;sticos a serem exibidos incluem:<br />
<ul class="normallist">
<li>Gr&aacute;fico com m&eacute;dia: &Eacute; constitu&iacute;da por uma barra horizontal onde o valor m&eacute;dio, o valor mais baixo permitido e o maior valor permitido est&atilde;o localizados.</li>
<li>Gr&aacute;fico com barras horizontais: Representa a utilização de cada valor permitido atrav&eacute;s de barras horizontais.</li>
<li>Gr&aacute;fico com barras verticais: Representa a utilização de cada valor permitido por meio de barra vertical.</li>
<li>Summary: Um conjunto de dados obtidos a partir dos valores de entrada (m&eacute;dia, o valor mais alto e mais baixo permitido, maior eo menor valor usado, valor mais e menos frequente).</li>
</ul>
O usu&aacute;rio v&ecirc; estes dados apenas se tiver permiss&atilde;o. O &iacute;ndice de mensagem pode ser ordenado por os dados de resumo, se ele tem permiss&atilde;o para classificar pelo campo.<br />
Usando templates podem ser inseridos os dados estat&iacute;sticos de qualquer grupo de campos em outro lugar.<br />
<br />
<b>Pesquisa em campos</b><br />
' . (!$smf_version_1 ? 'Sob a op&ccedil;&atilde;o &quot;Pesquisa&quot; a partir do f&oacute;rum menu p&aacute;ginas de pesquisa est&atilde;o localizados' : 'A op&ccedil;&atilde;o &quot;Mensagens de pesquisa e registros&quot; a partir do menu f&oacute;rum fornece acesso &agrave;s p&aacute;ginas de pesquisa') . ', mostrando os grupos e seus campos no qual o usu&aacute;rio tem permiss&atilde;o de busca.<br />
Grupos de tipo &quot;solto campos&quot;, &quot;campos com v&aacute;rios valores por membro&quot; e &quot;filtros&quot; pode estar em v&aacute;rias p&aacute;ginas de busca, e cada p&aacute;gina cont&eacute;m v&aacute;rios grupos, com a &uacute;nica condi&ccedil;&atilde;o de que os grupos em uma p&aacute;gina deve ser permitida em um conjunto comum de mensagens. Como resultado de pesquisa uma lista de postos &eacute; obtido.<br />
Para cada grupo de tipo &quot;registro&quot; com a permiss&atilde;o de busca tem uma p&aacute;gina. Como resultado, uma lista de registos &eacute; obtido com as colunas indicadas na defini&ccedil;&atilde;o dos campos.<br />
Em ambos os casos, os bot&otilde;es usados em cada campo de busca seguir a mesma regra que nos filtros.<br />' . (!$smf_version_1 ? '
<br />
<b>Lista no perfil de membro</b><br />
No perfil de membro, na se&ccedil;&atilde;o &quot;Informa&ccedil;&otilde;es do perfil &gt; Exibi Posts&quot;, pode ser mostrar uma lista para cada grupo de tipo &quot;registro&quot;, com mensagens postadas pelo pr&oacute;prio usu&aacute;rio contendo este tipo de grupo.<br />
<br />
<b>Lista em Centro Modera&ccedil;&atilde;o</b><br />
No Centro de modera&ccedil; &atilde;o &eacute; poss&iacute;vel controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
Para cada grupo que escolheu para mostrar esta lista ser&aacute; exibido um acesso &agrave; lista na se&ccedil;&atilde;o &quot;Posts &gt; Grupo de campos no posts&quot; e, opcionalmente, um link abaixo da op&ccedil;&atilde;o&quot;Moderado&quot; a partir do menu de f&oacute;rum.' : '
<br />
<b>Lista de modera&ccedil;&atilde;o</b><br />
Moderadores globais podem controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
A op&ccedil;&atilde;o &quot;Moderar os grupos de campos em mensagens&quot; a partir do menu f&oacute;rum fornece acesso &agrave; lista com dados lan&ccedil;ados, um para cada grupo, que escolheu para mostrar esta lista.');
$helptxt['cffp_enclose'] = 'Envolve a entrada do usu&aacute;rio entre algum texto(criado com HTML, BBC or PHP). Isso permitir&aacute; que voc&ecirc; adicione mais provedores de mensagens instant&acirc;neas, imagens ou uma incorpora&ccedil;&atilde;o etc. Por exemplo:<br />
<br />
&lt;a href="http://website.com/{INPUT}"&gt;&lt;img src="{DEFAULT_IMAGES_URL}/icon.gif" alt="{INPUT}" /&gt;&lt;/a&gt;<br />
<br />
Note que voc&ecirc; pode usar as seguintes vari&aacute;veis:<br />
<ul class="normallist">
<li><tt>{INPUT}</tt> - A entrada especificada pelo utilizador.</li>
<li><tt>{TEXT_PREVIOUS}</tt> - HTML para colocar antes do texto de sa&iacute;da.</li>
<li><tt>{TEXT_NEXT}</tt> - HTML para colocar a seguir o texto de sa&iacute;da.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_DATABASE}</tt> - O nome do campo no banco de dados do campo ID <i>n</i>. O campo pode ser de qualquer grupo.</li>
<li><tt>{ID_MSG}</tt> - ID da mensagem atual.</li>
<li><tt>{BOARDURL}</tt> - URL a pasta f&oacute;rum.</li>
<li><tt>{SCRIPTURL}</tt> - Endere&ccedil;o da Web do f&oacute;rum.</li>
<li><tt>{IMAGES_URL}</tt> - URL a pasta de imagens no usu&aacute;rios tema atual.</li>
<li><tt>{DEFAULT_IMAGES_URL}</tt> - URL para a pasta de imagens no tema padr&atilde;o.</li>
</ul>
No PHP, voc&ecirc; tamb&eacute;m pode usar as seguintes fun&ccedil;&otilde;es:<br />
<ul class="normallist">
<li><tt>{SHOW_GROUP_MSG}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>)</tt> - Exibe o grupo de uma mensagem como em uma mensagem.</li>
<li><tt>{SHOW_GROUP_MSGINDEX}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>)</tt> - Exibe o grupo de uma mensagem como no &iacute;ndice de mensagens.</li>
<li><tt>{SHOW_GROUP_MSG_STATS}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>, &apos;</tt><i>type</i><tt>&apos;, &apos;</tt><i>params</i><tt>&apos;)</tt> - Exibe as estat&iacute;sticas para o grupo de uma mensagem (se s&atilde;o ativados). o par&acirc;metro <i>type</i> pode ser:
<ul class="normallist">
<li><tt>chart_average</tt> - Exibe o gr&aacute;fico com a m&eacute;dia. o par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio mostrado), <tt>minmax</tt> (valor mais baixo e mais alto permitido mostrado), <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
<li><tt>chart_hbars</tt> - Apresenta o gr&aacute;fico com barras horizontais. o par&acirc;metro <i>params</i> n&atilde;o &eacute; utilizada.</li>
<li><tt>chart_vbars</tt> - Exibe o gr&aacute;fico com barras verticais. o par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
<li><tt>summary</tt> - Exibe o resumo. o par&acirc;metro <i>params</i> indica valores para mostrar, separados por v&iacute;rgulas. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
<li><tt>value</tt> - Exibe um valor de resumo. o par&acirc;metro <i>params</i> indica o valor a ser exibido. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
</ul></li>
</ul>';
$helptxt['cffp_mask'] = 'A m&aacute;scara de entrada &eacute; importante para o seu forum\'s seguran&ccedil;a. Validando a entrada de um usu&aacute;rio pode ajudar a garantir que os dados não &eacute; utilizado de uma forma que você n&atilde;o espera. N&oacute;s fornecemos algumas express&otilde;es regulares simples como sugest&otilde;es.<br /><br />
<div class="smalltext" style="margin: 0 2em">
&quot;[A-Za-z]+&quot; - Combinar todos os casos de caracteres do alfabeto superiores e inferiores.<br />
&quot;[0-9]+&quot; - Combinar todos os caracteres num&eacute;ricos.<br />
&quot;[A-Za-z0-9]{7}&quot; - Combinar todos os caracteres mai&uacute;sculas e min&uacute;sculas do alfabeto e num&eacute;ricos sete vezes.<br />
&quot;[^0-9]?&quot; - Proibir qualquer n&uacute;mero de ser correspondido.<br />
&quot;^([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6})$&quot; - Permitir somente 3 ou 6 hexcodes caracteres.<br />
</div><br /><br />
Adicionalmente, metacharacters especiais ?+*^$ e {xx} pode ser definida.
<div class="smalltext" style="margin: 0 2em">
? - Nenhum ou uma partida de express&atilde;o anterior.<br />
+ - Um ou mais de express&atilde;o anterior.<br />
* - Nenhum ou mais de express&atilde;o anterior.<br />
{xx} - Um n&uacute;mero exato de express&atilde;o anterior.<br />
{xx,} - Um n&uacute;mero exato ou mais a partir da express&atilde;o anterior.<br />
{,xx} - Um n&uacute;mero exato ou menos a partir da express&atilde;o anterior.<br />
{xx,yy} - Uma correspond&ecirc;ncia exata entre os dois n&uacute;meros a partir da express&atilde;o anterior.<br />
^ - In&iacute;cio da string.<br />
$ - Fim da string.<br />
\\ - Sair do pr&oacute;ximo caractere.<br />
</div><br /><br />
Mais informa&ccedil;&otilde;es e t&eacute;cnicas avan&ccedil;adas pode ser encontrado na internet.';
$helptxt['cffp_fieldtype'] = 'Tipos de campos que podem ser criados s&atilde;o:<br />
<ul class="normallist">
<li>Texto: O campo no qual pode digitar o texto de uma linha.</li>
<li>Grande texto: O campo que permite que tipo multi-linha de texto.</li>
<li>Caixa de escolha: O campo que exibe um menu de op&ccedil;&otilde;es para selecionar. O campo pode ser &uacute;nica sele&ccedil;&atilde;o (permite selecionar apenas uma op&ccedil;&atilde;o) ou m&uacute;ltiplo (permite selecionar v&aacute;rias op&ccedil;&otilde;es de uma s&oacute; vez).</li>
<li>Caixa de combina&ccedil;&atilde;o: Combina&ccedil;&atilde;o de caixa de sele&ccedil;&atilde;o (sele&ccedil;&atilde;o &uacute;nica ou m&uacute;ltipla) e caixa de texto, permitindo digitar um valor (ou valores separados por vírgulas) ou escolher a partir de uma lista de op&ccedil;&otilde;es.</li>
<li>Acionamento tipo Radio: Conjunto de op&ccedil;&otilde;es a partir do qual s&oacute; pode escolher um.</li>
<li>Caixas de sele&ccedil;&atilde;o: Conjunto de op&ccedil;&otilde;es a partir do qual voc&ecirc; pode escolher v&aacute;rios de uma vez.</li>
<li>Booleano: Apenas uma op&ccedil;&atilde;o que pode ser seleccionado (valor &quot;verdadeiro&quot;) ou n&atilde;o (valor &quot;falso&quot;).</li>
</ul>';
$helptxt['cffp_grouptype'] = 'Um grupo de campos podem ser do tipo:<br />
<ul class="normallist">
<li>Campos soltos: Seus campos são adicionados a um post para fornecer informa&ccedil;&otilde;es extra. Na busca de dados em campos soltos de um post obtendo uma lista de posts.</li>
<li>Registro: &Eacute; um conjunto de campos que representa uma entidade independente do post. Na busca de dados em campos de um registro &eacute; obt&eacute;m uma lista de registros. O corpo do post n&atilde;o pode ser deixado em branco, mas um post com registro n&atilde;o precisa de corpo. Se o usu&aacute;rio ir&aacute; adicionar um registro e o corpo do post estiver vazio, o sistema grava um per&iacute;odo (&quot;.&quot;) sobre ele e o usu&aacute;rio n&atilde;o precisa escrever nada.</li>
<li>Os campos com v&aacute;rios valores por membro: Ele &eacute; definido de campos onde v&aacute;rios usu&aacute;rios podem inserir valores diferentes. Isso pode ser usado para os membros para fazer coment&aacute;rios ou avalia&ccedil;&otilde;es sobre o post.</li>
<li>Filtros: Este &eacute; um tipo especial de grupo sem campos. Usado para habilitar um conjunto de filtros pr&eacute;-definidos que podem ser usados em t&oacute;picos e mensagens.</li>
</ul>';
$helptxt['cffp_type_filter'] = 'Tipo de bot&atilde;o de filtro depende do tipo de campo:<br />
<ul class="normallist">
<li>O filtro para o texto ou campos de texto grandes &eacute; um bot&atilde;o de texto para entrar na cadeia de pesquisa, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
<li>Campos tipo caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de ter pelo filtro de um bot&atilde;o de texto, uma caixa de sele&ccedil;&atilde;o ou uma caixa de combina&ccedil;&atilde;o em que digitar ou selecionar o texto a procurar, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
<li>Para campos do tipo Booleano o filtro &eacute; uma caixa de sele&ccedil; &atilde;o com os valores &quot;Sim&quot; e &quot;N&atilde;o&quot;.</li>
</ul>
Se o usu&aacute;rio pode modificar um campo, que o campo pode estar vazio e seu filtro &eacute; uma caixa de sele&ccedil;&atilde;o ou caixa de combina&ccedil;&atilde;o, ele ver&aacute; uma op&ccedil;&atilde;o na lista para obter dados com esse campo vazio.<br />
O filtro com o bot&atilde;o texto permite pesquisar palavras soltas (separados por um espa&ccedil;o) e/ou fases literais (entre aspas duplas).<br />
Se o filtro &eacute; do tipo de texto ou caixa de combina&ccedil;&atilde;o, por padr&atilde;o, ele &eacute; procurado que o texto est&aacute; contido no valor do campo, enquanto que se o filtro &eacute; o tipo de lista de sele&ccedil;&atilde;o de caixa &eacute; pedido que o texto corresponde ao valor do campo.';
$helptxt['cffp_options'] = 'Esta se&ccedil;&atilde;o define as op&ccedil;&otilde;es que o usu&aacute;rio pode escolher a partir de uma caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de sele&ccedil;&atilde;o. Existem alguns pontos-chave a serem observados nesta se&ccedil;&atilde;o:<br />
<ul class="normallist">
<li>As op&ccedil;&otilde;es padr&atilde;o: Qualquer que seja a caixa de opop&ccedil;&otilde;eses tem a &quot;bot&atilde;o de r&aacute;dio&quot; (pode haver apenas um) ou &quot;Caixas de sele&ccedil;&atilde;o&quot; (pode ser v&aacute;rias) ao lado desse selecionado ser&aacute; as sele&ccedil;&otilde;es padr&atilde;o para o utilizador quando entram dados.</li>
<li>Remo&ccedil;&atilde;o de opcionais: Para remover uma op&ccedil;&atilde;o simplesmente vazia na caixa de texto para essa op&ccedil;&atilde;o - todas as mensagens com o seleccionado ter&aacute; sua op&ccedil;&atilde;o desmarcada.</li>
<li>Reordenar op&ccedil;&otilde;es: Voc&ecirc; pode reordenar as op&ccedil;&otilde;es movendo texto em torno entre as caixas. Contudo - uma nota importante - voc&ecirc; deve se certificar do que voc&ecirc; faz <strong>n&atilde;o</strong> mudar o texto quando reordena&ccedil;&atilde;o op&ccedil;&otilde;es em contr&aacute;rio dados postados ser&atilde;o perdidos.</li>
<li>Texto (dispon&iacute;vel se o bot&atilde;o n&atilde;o &eacute; uma caixa de combina&ccedil;&atilde;o): Uma op&ccedil;&atilde;o pode ser exibido com valor real ou com um texto mais significativo para o usu&aacute;rio.</li>
<li>Adicione v&aacute;rias op&ccedil;&otilde;es: Permite adicionar v&aacute;rias op&ccedil;&otilde;es de uma s&oacute; vez, escrevendo cada op&ccedil;&atilde;o em uma linha do campo de texto grande. Cada op&ccedil;&atilde;o tem valor e, se o bot&atilde;o n&atilde;o &ecirc; uma caixa de combinaç&atilde;o, texto, separados por v&iacute;rgulas. Texto &ecirc; opcional.</li>
</ul>';
$helptxt['cffp_javascript'] = 'C&oacute;digo JavaScript executado quando um grupo de campos &eacute; criado ou modificado.<br />
Permite a execu&ccedil;&atilde;o de c&oacute;digo quando um evento ocorre ao longo de um bot&atilde;o de formul&aacute;rio ou outro elemento HTML.<br />
Isto pode ser escrito como:<br />
<br />
<tt>document.getElementsByName(</tt><i>html_element_name</i><tt>)[0].</tt><i>event_name</i><tt> = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;// ...<br />
}<br />
document.getElementById(</tt><i>html_element_id</i><tt>).</tt><i>event_name</i><tt> = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;// ...<br />
}</tt><br />
<br />
Por exemplo, este c&oacute;digo mostra uma mensagem quando o usu&aacute;rio clica no bot&atilde;o <tt>id1</tt> e copiar o valor do bot&atilde;o <tt>id2</tt> sobre o assunto quando o usu&aacute;rio alterar esse valor:<br />
<br />
<tt>document.getElementById(&quot;id1&quot;).onclick = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;alert(&quot;A message&quot;);<br />
}<br />
document.getElementById(&quot;id2&quot;).onchange = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;document.getElementsByName(&quot;subject&quot;)[0].value = this.value;<br />
}</tt>';
$helptxt['cffp_stats'] = 'Se um grupo de tipo &quot;campos com v&aacute;rios valores por membro&quot; tem um &uacute;nico campo e &eacute; do tipo caixa de sele&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas (isto &eacute;, existe um n&uacute;mero finito de valores), pode gerar dados estat&iacute;sticos a partir dos valores inseridos no campo.<br />
Os dados estat&iacute;sticos a serem exibidos incluem:<br />
<ul class="normallist">
<li>Gr&aacute;fico com m&eacute;dia: &Eacute; constitu&iacute;da por uma barra horizontal, onde o valor m&eacute;dio, o valor mais baixo permitido e o valor mais elevado permitido est&atilde;o localizados.</li>
<li>Gr&aacute;fico com barras horizontais: Representa o uso de cada valor permitido por barras horizontais.</li>
<li>Gr&aacute;fico com barras verticais: Representa o uso de cada valor permitido por barra vertical.</li>
<li>Resumo: Um conjunto de dados obtidos a partir dos valores de entrada (m&eacute;dia, o valor mais alto e mais baixo permitido, maior e o menor valor usado, valor mais e menos frequente).</li>
</ul>
O usu&aacute;rio v&ecirc; estes dados apenas se tiver permiss&atilde;o. O &iacute;ndice de mensagem pode ser ordenado por os dados de resumo, se ele tem permiss&atilde;o para classificar pelo campo.<br />
Usando templates que podem ser inseridos os dados estat&iacute;sticos de qualquer grupo de campos em outro lugar.';
$helptxt['cffp_search_page'] = (!$smf_version_1 ? 'Sob a op&ccedil;&atilde;o &quot;Pesquisa&quot; a partir do menu f&oacute;rum, p&aacute;ginas de pesquisa s&atilde;o localizados' : 'A op&ccedil;&atilde;o &quot;Pesquisa de posts e registros&quot; a partir do menu f&oacute;rum fornece acesso &agrave;s p&aacute;ginas de pesquisa') . ', mostrando os grupos e seus campos no qual o usu&aacute;rio tem permiss&atilde;o de busca.<br />
Grupos de tipo &quot;campos soltos&quot;, &quot;campos com cada valor por membro&quot; e &quot;filtro&quot; pode ser em cada p&aacute;gina de pesquisa, e cada p&aacute;gina cont&eacute;m v&aacute;rios grupo, com a &uacute;nica condi&ccedil;&atilde;o de que os grupos em uma p&aacute;gina deve ser permitida em um conjunto comum de mensagens. Como resultado de pesquisa uma lista de postos &eacute; obtido.<br />
Para cada grupo de tipo &quot;registro&quot; com a permiss&atilde;o de busca tem uma p&aacute;gina. Como resultado, uma lista de registos &eacute; obtido com as colunas indicadas na defini&ccedil;&atilde;o dos campos.';
$helptxt['cffp_profile_list'] = 'No perfil de membro, na se&ccedil;&atilde;o &quot;Informa&ccedil;&otilde;es do Perfil &gt; Ver Posts&quot;, pode mostrar uma lista para cada grupo de tipo &quot;gravar&quot;, com mensagens postadas pelo pr&oacute;prio usu&aacute;rio contendo este tipo de grupo.';
if (!$smf_version_1)
{
$helptxt['cffp_moderation_list'] = 'No Comando do moderador &eacute; poss&iacute;vel controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
Para cada grupo que escolheu para mostrar esta lista ser&aacute; exibido um acesso &agrave; lista na se&ccedil;&atilde;o &quot;Posts &gt; Grupos de campos em posts&quot; e, opcionalmente, um link abaixo da op&ccedil;&atilde;o &quot;Moderado&quot; a partir do menu de f&oacute;rum.';
}
else
{
$helptxt['cffp_moderation_list'] = 'Moderadores globais podem controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
A op&ccedil;&atilde;o &quot;Moderar os grupos de campos nas mensagens&quot; a partir do menu f&oacute;rum fornece acesso &agrave; lista com dados lan&ccedil;ados, um para cada grupo, que escolheu para mostrar esta lista.';
}
$helptxt['cffp_template_text'] = 'Texto usado para exibir o conte&uacute;do de campos em grupo.<br />
Você pode usar as seguintes vari&aacute;veis:<br />
<ul class="normallist">
<li><tt>{FIELD_</tt><i>n</i><tt>_NAME}</tt> - Nome de campo ID <i>n</i>.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_VALUE}</tt> - Valor de campo ID <i>n</i>.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_DATABASE}</tt> - O nome do campo no banco de dados do campo ID <i>n</i>. O campo pode ser de qualquer grupo.</li>
<li><tt>{ID_MSG}</tt> - ID da mensagem atual.</li>
<li><tt>{BOARDURL}</tt> - URL para pasta f&oacute;rum.</li>
<li><tt>{SCRIPTURL}</tt> - Endere&ccedil;o Web do f&oacute;rum.</li>
<li><tt>{IMAGES_URL}</tt> - URL para pasta de imagens no usu&aacute;rios tema atual.</li>
<li><tt>{DEFAULT_IMAGES_URL}</tt> - URL para pasta de imagens no tema padr&atilde;o.</li>
</ul>
No PHP, voc&ecirc; tamb&eacute;m pode usar as seguintes fun&ccedil;&otilde;es:<br />
<ul class="normallist">
<li><tt>{SHOW_GROUP_MSG}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>)</tt> - Exibe o grupo de uma mensagem como em uma mensagem.</li>
<li><tt>{SHOW_GROUP_MSGINDEX}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>)</tt> - Exibe o grupo de uma mensagem como no &iacute;ndice de mensagens.</li>
<li><tt>{SHOW_GROUP_MSG_STATS}(</tt><i>message_ID</i><tt>, </tt><i>group_ID</i><tt>, &apos;</tt><i>type</i><tt>&apos;, &apos;</tt><i>params</i><tt>&apos;)</tt> - Exibe as estat&iacute;sticas para o grupo de uma mensagem (se s&atilde;o ativados). O par&acirc;metro <i>tipo</i> pode ser:
<ul class="normallist">
<li><tt>chart_average</tt> - Exibe o gr&aacute;fico com a m&eacute;dia. o par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>m&eacute;dia</tt> (valor m&eacute;dio mostrado), <tt>minmax</tt> (valor mais baixo e mais alto permitido mostrado), <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
<li><tt>chart_hbars</tt> - Exibe o gr&aacute;fico com barras horizontais. o par&acirc;metro <i>params</i> n&atilde;o &eacute; utilizada.</li>
<li><tt>chart_vbars</tt> - Exibe o gr&aacute;fico com barras verticais. o par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
<li><tt>summary</tt> - Exibe o resumo. o par&acirc;metro<i>params</i> indica valores para mostrar, separados por v&iacute;rgulas. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>maior</tt> (maior valor usado), <tt>menor</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
<li><tt>value</tt> - Exibe um valor de resumo. O par&acirc;metro <i>params</i> indica o valor a ser exibido. Os valores permitidos: <tt>m&eacute;dia</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>maior</tt> (maior valor usado), <tt>menor</tt> (menor valor utilizado), <tt>most_frequent</tt> (valor mais frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
</ul></li>
</ul>
Esvazie o campo de texto para excluir o modelo. Se o modelo n&atilde;o est&aacute; campos definidos s&atilde;o exibidos com o seu nome e conte&uacute;do.';
$helptxt['cffp_template_message_index_text'] = $helptxt['cffp_template_text'];
$helptxt['cffp_template_quick_input'] = 'Texto usado para criar um registro.<br />
Permite que preencher todos os campos de uma s&oacute; vez, escrevendo todos os valores em um &uacute;nico campo, chamado <strong>Campo de entrada r&aacute;pida</strong>, de acordo com um modelo ou uma express&atilde;o regular.<br />
A express&atilde;o regular deve ser compat&iacute;vel com JavaScript. usado em <tt>String.match(regex)</tt> m&eacute;todo e deve ser obtida uma matriz de valores de campo come&ccedil;ando com a chave 1.<br />
O par&acirc;metros de template consistem em linhas de texto:<br />
<ul class="normallist">
<li>Para cada elemento da matriz obtida a partir da express&atilde;o regular acrescenta uma linha com o campo ID.</li>
<li>Linhas que seguem a ordem da matriz.</li>
<li>Se um elemento de matriz n&atilde;o corresponde a qualquer campo, cont&eacute;m texto n&atilde;o utilizado e em que a linha &eacute; escrito 0.</li>
<li>Se &eacute; necess&aacute;rio formatar um valor antes de copi&aacute;-lo em seu campo, sob a linha que cont&eacute;m o ID campo outra linha &eacute; adicionado com o c&oacute;digo JavaScript que transforma o valor. <tt>valor</tt> vari&aacute;vel cont&eacute;m o valor original e deve conter o valor transformado. com <tt>field_obj</tt> array, indexado pelo campo ID, n&atilde;o h&aacute; acesso a todos os campos do formul&aacute;rio no registro.</li>
</ul>
Por exemplo, se o registro tem esses campos<br />
<br />
<table>
<thead>
<tr>
<th>Nome</th>
<th>ID</th>
</tr>
</thead>
<tbody>
<tr>
<td>ID DocBook</td>
<td>3</td>
</tr>
<tr>
<td>Autor Nome</td>
<td>1</td>
</tr>
<tr>
<td>Autor sobrenome</td>
<td>2</td>
</tr>
</tbody>
</table>
<br />
&eacute; definida<br />
<br />
Express&atilde;o regular: <tt>/^(.+)\s+(.+)\s+(.+)\s*/</tt><br />
Par&acirc;metros:<br />
<tt>3<br />
1<br />
var x = value.split(/\s+/g); for (var i = 0; i < x.length; i++) { var parts = x[i].match(/(\w)(\w*)/); x[i] = parts[1].toUpperCase() + parts[2].toLowerCase(); } value = x.join(&quot; &quot;);<br />
2<br />
var x = value.split(/\s+/g); for (var i = 0; i < x.length; i++) { var parts = x[i].match(/(\w)(\w*)/); x[i] = parts[1].toUpperCase() + parts[2].toLowerCase(); } value = x.join(&quot; &quot;);</tt><br />
<br />
e usu&aacute;rio escreve<br />
<br />
<tt>24<br />
LEWIS CARROLL</tt><br />
<br />
campos ser&atilde;o preenchidos, assim,:<br />
<br />
ID DocBook: 24<br />
Autor Nome: Lewis<br />
Autor sobrenome: Carroll';
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on January 24, 2015, 06:50:00 PM
I corrected some errors.
Thanks.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: sneakers on February 06, 2015, 07:04:04 AM
Quote
Hello,
Is it possible that custom fields are required for all users?
Yes. Do this:
1. Check Not empty value,  on setting field.
2. Check permissions to all users for view, on setting field.
3. Check permissions to all users for view and modify, on setting group.
Thanks!
Another question. How can I remove it?
(http://i.imgur.com/QclL8Kh.png)
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on February 06, 2015, 07:27:53 AM
Another question. How can I remove it?
(http://i.imgur.com/QclL8Kh.png)
In settings field, go to below and uncheck all permissions for Filter and Sort 8)
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: sneakers on February 06, 2015, 07:43:08 AM
Here?
(http://i.imgur.com/a27RI54.png)

I can't uncheck the "Search page".
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: sneakers on February 06, 2015, 07:49:59 AM
(http://i.imgur.com/nq8n7Rx.png)

It doesn't solve the problem.
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: sneakers on February 06, 2015, 09:32:48 AM
Thanks!

I have antoher problem. On my forum is installed AjaxChat Integration 3.2.1. Chat isn't working and there were errors:
(http://i.imgur.com/gk6PoiB.png)

Load.php
(http://i.imgur.com/0KS0cMy.png)
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on February 06, 2015, 10:49:36 AM
Thanks!

I have antoher problem. On my forum is installed AjaxChat Integration 3.2.1. Chat isn't working and there were errors:
(http://i.imgur.com/gk6PoiB.png)

Load.php
(http://i.imgur.com/0KS0cMy.png)
Perhaps it is because this bug
http://www.simplemachines.org/community/index.php?topic=518886.msg3777065#msg3777065
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: sneakers on March 15, 2015, 02:44:20 PM
@davidhs,
I tried, but it still does not work..

Code: [Select]
Notice: Undefined variable: smf_version_1 in /home/user/domains/domain.com/public_html/forum/Sources/Load.php(2155) : eval()'d code on line 428

Notice: Undefined variable: smf_version_1 in /home/user/domains/domain.com/public_html/forum/Sources/Load.php(2155) : eval()'d code on line 449
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on March 16, 2015, 08:04:57 AM
@davidhs,
I tried, but it still does not work..

Code: [Select]
Notice: Undefined variable: smf_version_1 in /home/user/domains/domain.com/public_html/forum/Sources/Load.php(2155) : eval()'d code on line 428

Notice: Undefined variable: smf_version_1 in /home/user/domains/domain.com/public_html/forum/Sources/Load.php(2155) : eval()'d code on line 449
Sorry, I do not found cause :(

Perhaps next update solve this bug. If I have time to do it!
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on May 22, 2015, 04:02:46 PM
hi Davidhs! How are you? and the new version 1.3 are you doing? it's all OK?
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on May 23, 2015, 06:55:02 AM
hi Davidhs! How are you? and the new version 1.3 are you doing? it's all OK?
It is comming...

I have "some" text without translate to Portuguese. Can you translate?:

Quote
As ações a serem realizadas em um grupo de campos personalizados sâo: visâo, adicionar, modificar, apagar e mover.
Furthermore other actions are possible using custom fields:
  • Filtrar o índice de mensagens.
  • Organizar o índice de mensagens.
  • Mostrar estatísticas.
  • Pesquisar nas áreas de mensagens, obter uma lista de posts.
  • Pesquisar nas áreas de registros, obtendo uma lista de registros.
...
Filters and search settings
...
Long description of field
It is shown above the button. Admits BBC.
...
Field description on search page
Exibido junto ao nome do.
...
Long description of field on search page
It is shown above the button. Admits BBC.
...
Show creation date on posted data
...
Show last modification date on modified data
...
Only one value per member
Each member can post data only once.
...
Show statistics
The group must have only one field, type select box, radio buttons or checkboxes.
...
Show statistics in post
...
Show statistics on message index
...
Text to be displayed before
Admite BBC.
...
Show chart with average
...
Show chart with horizontal bars
...
Show chart with vertical bars
...
Show summary
...
Only if the data are numeric
...
Show average value
...
Show lowest and highest allowed value
...
Show the text of options
...
Use statistics to order the message index
...
List of moderation
...
Show filter with operator
If selected allows selecting the operator with which apply the filter. Default operator is "equal to" or "like", according to the type of filter.
   Contains
   Not contains
...
Hide the filter under a tag
The filter is hidden and is shown by clicking on the tag. The same tag can hide multiple filters.';
...
Show only used options
Show in filter only those items that used in the current board.
...
Show on lists of Moderation Center
Mostra este campo em uma coluna das listas de Centro de Moderar.
...
Show on lists of moderation
Shows this field in a column of the lists of moderation.
...
View statistics
Filtro
Sort
Adicionar
Mover
...
Show when data are modified
If not selected will be shown only when data are created.
...
Search posts and records
...
Moderate grupos de campos em mensagens
Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: Americano on May 24, 2015, 11:48:27 AM
Green is html


Quote
As ações a serem realizadas em um grupo de campos personalizados são: visão, adicionar, modificar, apagar e mover.
Furthermore other actions are possible using custom fields:
Além disso são possíveis outras ações usando campos personalizados
Al&eacute;m disso s&atilde;o poss&iacute;veis outras a&ccedil;&otilde;es usando campos personalizados

  • Filtrar o índice de mensagens.
  • Organizar o índice de mensagens.
  • Mostrar estatísticas.
  • Pesquisar nas áreas de mensagens, obter uma lista de posts.
  • Pesquisar nas áreas de registros, obtendo uma lista de registros.
...
Filters and search settings
Filtros e configurações de pesquisa
Filtros e configura&ccedil;&otilde;es de pesquisa

...
Long description of field
It is shown above the button. Admits BBC.
Descrição longa de campo
Isso é exibido acima do botão. Admite BBC

Descri&ccedil;&atilde;o longa de campo
Isso &eacute; exibido acima do botão. Admite BBC.



...
Field description on search page
Descrição do campo na página de busca
Descri&ccedil;&atilde;o do campo na p&aacute;gina de busca

Exibido junto ao nome do.
...
Long description of field on search page
It is shown above the button. Admits BBC.
Descri&ccedil;&atilde;o longa de campo na p&aacute;gina de busca
Isso &eacute; exibido acima do bot&atilde;o. Admite BBC.

...
Show creation date on posted data
Exibir data de cria&ccedil;&atilde;o em dados postados

...
Show last modification date on modified data
Exibir data de cria&ccedil;&atilde;o em dados postados
...
Only one value per member
Each member can post data only once.
Apenas um valor por membro
Cada membro pode publicar os dados apenas uma vez.
...
Show statistics
The group must have only one field, type select box, radio buttons or checkboxes.
Exibir estat&iacute;sticas
O grupo deve ter apenas um campo, tipo caixa de sele&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de sele&ccedil;&atilde;o
...
Show statistics in post
Exibir estat&iacute;sticas no post
...
Show statistics on message index
Exibir estat&iacute;sticas sobre &iacute;ndice de mensagens
...
Text to be displayed before
Texto a ser exibido antes
Admite BBC.
...
Show chart with average
Exibir gr&aacute;fico com média
...
Show chart with horizontal bars
Visualizar gr&aacute;fico com barras horizontais
...
Show chart with vertical bars
Visualizar gr&aacute;fico com barras verticais
...
Show summary
Exibir resumo
...
Only if the data are numeric
Apenas se os dados sã&atilde;o numéricos
...
Show average value
Exibir valor m&eacute;dio
...
Show lowest and highest allowed value
Exibir valor mais baixo e mais alto permitido
...
Show the text of options
Ver o texto de op&ccedil;&otilde;es
...
Use statistics to order the message index
Use estat&iacute;sticas para ordenar o &iacute;ndice de mensagens
...
List of moderation
Lista de modera&ccedil;&atilde;o
...
Show filter with operator
If selected allows selecting the operator with which apply the filter. Default operator is "equal to" or "like", according to the type of filter.
   Contains
   Not contains

Exibir filtro com operador
Se selecionado permite selecionar o operador com o qual aplicar o filtro. Operador padrão &eacute; "igual a" ou "semelhante", de acordo com o tipo de filtro.
Incluir
Não Incluir

...
Hide the filter under a tag
The filter is hidden and is shown by clicking on the tag. The same tag can hide multiple filters.';

Esconder o filtro sob uma tag
O filtro fica escondido e &eacute; exibido clicando na tag. A mesma tag pode esconder v&aacute;rios filtros.';

...
Show only used options
Show in filter only those items that used in the current board.

Exibir apenas op&ccedil;&otilde;es usadas
Exibir no filtro apenas os itens que utilizados pela atual diretoria.

...
Show on lists of Moderation Center
Exibir em listas de Centro Modera&ccedil;&atilde;o
Mostra este campo em uma coluna das listas de Centro de Moderar.
...
Show on lists of moderation
Shows this field in a column of the lists of moderation.

Exibir em listas de Modera&ccedil;&atilde;o
Exibir este campo em uma coluna das listas de modera&ccedil;&atilde;o.

...
View statistics
Exibir estat&iacute;sticas
Filtro

Filtro
Sort
Tipo
Adicionar
Mover
...
Show when data are modified
If not selected will be shown only when data are created.


Exibir quando os dados s&atilde;o modificados
Se n&atilde;o for selecionado só ser&aacute; exibido quando os dados s&atilde;o criados.

...
Search posts and records

Pesquisa de post e registros
...
Moderate Moderado grupos de campos em mensagens

Title: Re: Custom fields and filters of post, 1.2 (SMF 1.1-1.1.20, 2.0-2.0.9)
Post by: davidhs on May 26, 2015, 10:57:36 AM
Green is html


Quote
As ações a serem realizadas em um grupo de campos personalizados são: visão, adicionar, modificar, apagar e mover.
Furthermore other actions are possible using custom fields:
Além disso são possíveis outras ações usando campos personalizados
Al&eacute;m disso s&atilde;o poss&iacute;veis outras a&ccedil;&otilde;es usando campos personalizados
[...]
Thanks!
Title: Re: Custom fields and filters of post
Post by: davidhs on June 07, 2015, 11:47:59 AM
I have next errors:
Code: [Select]
/index.php?pretty;board=a.40&amp;sort=replies;desc
8: Undefined index: cffp
File:/Themes/havvo/MessageIndex.template.php
Line: 272 and 273

Line 272 & 273:
Code: [Select]
270:// BEGIN MOD CustomFieldFilterPost
271:// Show custom post fields.
272:$context['cffp']['message_index'] = $topic['first_post']['cffp']['message_index'];
==>273:$context['cffp']['message_index_member'] = $topic['first_post']['cffp']['message_index_member'];
274:template_cffp_show('message_index');
275:template_cffp_show('message_index_member');
276:// END MOD CustomFieldFilterPost
I do not see this error. Perhaps was fixed in update.

I want to put a custom counter for the user always  that use the form.
Done.

I do the translation in Portuguese, if you want.
Added.

[...] can you add an option to display this filter not only as a drop-down list, but the line of letters < A B C ... > like alphabet от the forum members list page.
Sorry, this is complex. :( I do not this.
In fact, what you order is like to put radio buttons (click on each option instead of a radio button per option) and I put select boxes in filters instead of radio buttons.

@davidhs,
I tried, but it still does not work..

Code: [Select]
Notice: Undefined variable: smf_version_1 in /home/user/domains/domain.com/public_html/forum/Sources/Load.php(2155) : eval()'d code on line 428

Notice: Undefined variable: smf_version_1 in /home/user/domains/domain.com/public_html/forum/Sources/Load.php(2155) : eval()'d code on line 449
Fixed.



New version:
Code: [Select]
1.3     2015-06-07
------------------
! Error in PHP code.
! Navigation in the message index when a predefined filter is used.
! Delete statistics when topics or messages are deleted.
! When moving a group of type "fields loose" or "record" to another message, the poster of the message is assigned to group.
! SMF 2.0.x: When assigning a message to another member, the groups of type "fields loose" or "record" of that message are assigned to member.
+ Field in administration panel to show, on the information about the member, the number of each type of record created by the member.
+ "Administration Center > Forum Maintenance > Routine > Recount all forum totals and statistics" also recounts the number of each type of record created by members.
+ SMF compatibility: 1.1.21 and 2.0.10.
+ Languages: portuguese_brazilian, portuguese_brazilian-utf8, brazilian, brazilian-utf8, portuguese_pt, portuguese_pt-utf8, thanks to Americano.
Title: Re: Custom fields and filters of post
Post by: Americano on June 07, 2015, 04:09:03 PM
Quote from: davidhs

I want to put a custom counter for the user always  that use the form.
Done.

I do the translation in Portuguese, if you want.
Added.

Thanks very much! I'll do the tests  :)
Title: Re: Custom fields and filters of post
Post by: Americano on June 07, 2015, 07:47:15 PM
hi Davidhs! The mod is excellent! Congratulations!

I understand that Mod 1.3 is best to build form than before. Build by "Select box" is very good.  :)

-----

But I was wrong in translation in custom filter

Modifications.portuguese_brazilian.php

Find:
Code: [Select]
$txt['cffp_search_posts_desc'] = 'Escreva o texto e / ou selecione as op&ccedil;&ccedil;s nos campos em que deseja pesquisar. Você vai ter uma lista de posts que contenham esses valores em seus campos.';
Replace With:

Code: [Select]
$txt['cffp_search_posts_desc'] = 'Escreva o texto e / ou selecione as op&ccedil;&otilde;es nos campos em que deseja pesquisar. Voc&ecirc; vai ter uma lista de posts que contenham esses valores em seus campos.';
Find:

Code: [Select]
$txt['cffp_search_records_desc'] = 'Escreva o texto e / ou selecione as op&ccedil;&ccedil;&otilde;s nos campos em que deseja pesquisar. Você vai ter uma lista de registros que contêm esses valores em seus campos.';
Replace With:

Code: [Select]
$txt['cffp_search_records_desc'] = 'Escreva o texto e / ou selecione as op&ccedil;&otilde;es nos campos em que deseja pesquisar. Voc&ecirc; vai ter uma lista de registros que cont&ecirc;m esses valores em seus campos.';
----

In the administrator panel has new sentences without translating.

I did the translation, but it was not added.

But, as is only to the administrator does not need to add.

Thank very much!

Title: Re: Custom fields and filters of post
Post by: Sakae on June 07, 2015, 08:52:08 PM
That's probably a MVM (most valuable mod) for 2015.

If I get how to understand how to configure it first. I think I'll take some weekend to learn...

Want to use it as a game prediction, with options as W/D/L, the score and the players whom scored. You think it's possible?
Title: Re: Custom fields and filters of post
Post by: davidhs on June 08, 2015, 06:14:02 AM
hi Davidhs! The mod is excellent! Congratulations!

I understand that Mod 1.3 is best to build form than before. Build by "Select box" is very good.  :)
Thanks! :D

But I was wrong in translation in custom filter

Modifications.portuguese_brazilian.php

[...]
Ok. In next update I will replace opççs -> opções. The others (Você, contêm) was my mistake (in ISO-8859-1, like portuguese_brazilian.php, I write HTML entities, Voc&ecirc; ; and in UTF-8, like portuguese_brazilian-utf8.php, I write characters, Você).

In the administrator panel has new sentences without translating.

I did the translation, but it was not added.

But, as is only to the administrator does not need to add.
I search but do not find... in description of mod I do not translate the "official name" of mod to any language:
Code: [Select]
<?php

$txt
['cffp_desc'] = 'Painel de administração para o "Custom fields and filters of post" MOD';

?>
What else?



That's probably a MVM (most valuable mod) for 2015.
Thanks. :D

If I get how to understand how to configure it first. I think I'll take some weekend to learn...
I know this is a complicate mod. ;)

Want to use it as a game prediction, with options as W/D/L, the score and the players whom scored. You think it's possible?
Yes, you can use this mod. For example, you can create:
- A record named "Game" with fields: name, image, descripcion, requirements, year, company,...
- A group of field type "Fields with several values per member" named "Players scores" with field: Score (the player/member and date of creation are fields which already exist).

And you can show statistics with scores.
Title: Re: Custom fields and filters of post
Post by: Sakae on June 08, 2015, 11:54:30 AM
Want to use it as a game prediction, with options as W/D/L, the score and the players whom scored. You think it's possible?
Yes, you can use this mod. For example, you can create:
- A record named "Game" with fields: name, image, descripcion, requirements, year, company,...
- A group of field type "Fields with several values per member" named "Players scores" with field: Score (the player/member and date of creation are fields which already exist).

And you can show statistics with scores.

Alright! Will give a shot until the end of this week already. Thank you very much for your attention. :D

Ok. In next update I will replace opççs -> opções. The others (Você, contêm) was my mistake (in ISO-8859-1, like portuguese_brazilian.php, I write HTML entities, Voc&ecirc; ; and in UTF-8, like portuguese_brazilian-utf8.php, I write characters, Você).

I was about to tell this. "Voc&ecirc;" it's on "portuguese_brazilian-utf8.php" (which I use), and "Você" on ISO..
Title: Re: Custom fields and filters of post
Post by: davidhs on June 08, 2015, 12:42:24 PM
Ok. In next update I will replace opççs -> opções. The others (Você, contêm) was my mistake (in ISO-8859-1, like portuguese_brazilian.php, I write HTML entities, Voc&ecirc; ; and in UTF-8, like portuguese_brazilian-utf8.php, I write characters, Você).

I was about to tell this. "Voc&ecirc;" it's on "portuguese_brazilian-utf8.php" (which I use), and "Você" on ISO..
:o  :-[ Sorry. In next update I will review all Portuguese strings (utf8 and iso).
Title: Re: Custom fields and filters of post
Post by: Sakae on June 10, 2015, 10:33:45 AM
Not neccessary ;)

Edit the correct language file ("portuguese_brazilian"). Have not reviewed Americano translation, so here it goes for portuguese_brazilian-utf8:

./Themes/default/languages/Errors.portuguese_brazilian-utf8.php
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
$txt['error_cffp_field_need_name'] = 'O campo deve ter um nome!';
$txt['error_cffp_group_need_name'] = 'O grupo de campos deve ter um nome!';
$txt['error_cffp_field_need_options'] = 'O campo deve ter op&ccedil;&otilde;es!';
$txt['error_cffp_search_page_in_use'] = 'A p&aacute;gina de pesquisa j&aacute; est&aacute; em uso!';
$txt['error_cffp_search_page_in_use_record'] = 'A p&aacute;gina de pesquisa j&aacute; est&aacute; em uso por um registro!';
$txt['error_cffp_group_no_name'] = 'Nenhum nome foi fornecido em grupo &quot;%s&quot;.';
$txt['error_cffp_group_long_name'] = 'O nome que voc&ecirc; tentou usar em grupo &quot;%s&quot; era muito longo.';
$txt['error_cffp_group_bad_name'] = 'O nome que voc&ecirc; apresentou, em grupo &quot;%s&quot; n&atilde;o pode ser utilizado, uma vez que &eacute; ou cont&eacute;m um nome reservado.';
$txt['error_cffp_group_no_email'] = 'Nenhum endere&ccedil;o de e-mail fornecido no grupo &quot;%s&quot;.';
$txt['error_cffp_group_bad_email'] = 'Um endere&ccedil;o de e-mail inv&aacute;lido foi dada em grupo &quot;%s&quot;.';
$txt['error_cffp_group_invalid_email'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; deve ser um endere&ccedil;o de email v&aacute;lido.';
$txt['error_cffp_group_not_number'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; deve ser num&eacute;rico.';
$txt['error_cffp_group_inproper_format'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; &eacute; um formato inv&aacute;lido.';
$txt['error_cffp_group_empty'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; n&atilde;o pode ser deixado em branco.';
$txt['error_cffp_group_value_not_unique'] = 'O valor do campo &quot;%s&quot; no grupo &quot;%s&quot; j&aacute; existe.';
$txt['error_cffp_params'] = 'Par&acirc;metros incorretos';
$txt['error_cffp_move_missing_post'] = 'A mensagem alvo &eacute; inexistente.';
$txt['error_cffp_move_missing_topic'] = 'O t&oacute;pico alvo &eacute; inexistente.';
$txt['error_cffp_move_board_post_not_allowed'] = 'Os dados n&atilde;o podem estar na categoria de mensagem de destino.';
$txt['error_cffp_move_board_topic_not_allowed'] = 'Os dados n&atilde;o podem estar na categoria de t&oacute;pico de destino.';
$txt['error_cffp_move_post_not_allowed'] = 'Os dados n&atilde;o podem ser na mensagem alvo.';
$txt['error_cffp_move_topic_not_allowed'] = 'Os dados n&atilde;o podem ser no t&oacute;pico alvo.';
$txt['error_cffp_move_already_has_data'] = 'A mensagem de destino j&aacute; tem este tipo de dados.';
$txt['error_cffp_move_post_already_has_data'] = 'O membro j&aacute; tem este tipo de dados na mensagem de destino.';
$txt['error_cffp_move_topic_already_has_data'] = 'O membro j&aacute; tem este tipo de dados no t&oacute;pico alvo.';
$txt['error_cffp_search_not_allowed'] = 'N&atilde;o definiu campos pesquis&aacute;veis ou voc&ecirc; n&atilde;o tem permiss&atilde;o para pesquisar.';
// END MOD CustomFieldFilterPost

./Themes/default/languages/Help.portuguese_brazilian-utf8.php
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
global $forum_version;
$smf_version_1 = 0 === strpos($forum_version, 'SMF 1');
$helptxt['cffp'] = '<b>Campos personalizados e filtros de mensagens</b><br />
   Permite adicionar diferentes grupos de campos personalizados para posts no f&oacute;rum e filtros para os campos de mensagens.<br />
   Um grupo de campos podem ser do tipo:<br />
   <ul class="normallist">
      <li>Campos soltos: Seus campos são adicionados a um post para fornecer informa&ccedil;&otilde;es extra. Na busca de dados em campos soltos de um post &eacute; obt&eacute;m uma lista de posts.</li>
      <li>Registro: &Eacute; um conjunto de campos que representa uma entidade independente do post. Na busca de dados em campos de um registro é obt&eacute;m-se uma lista de registros. O corpo do post n&atilde;o pode ser deixado em branco, mas um post com registro n&atilde;o precisa de corpo. Se o usu&aacute;rio ir&aacute; adicionar um registro e o corpo do post estiver vazio, o sistema grava um per&iacute;odo(&quot;.&quot;) sobre ele e o usu&aacute;rio n&atilde;o precisa escrever nada.</li>
      <li>Os campos com v&aacute;rios valores por membro: &Eacute; um conjunto de campos onde v&aacute;rios usu&aacute;rios podem inserir valores diferentes. Isso pode ser usado para os membros para fazer coment&aacute;rios ou avalia&ccedil;&otilde;es sobre o post. Se esses campos est&atilde;o localizados em apenas na primeira mensagem de um t&oacute;pico pode ser apresentado como pertencente ao t&oacute;pico.</li>
      <li>Filtros: Este &eacute; um tipo especial de grupo sem campos. Usado para habilitar um conjunto de filtros pr&eacute;-definidos que podem ser usados em t&oacute;picos e mensagens.</li>
   </ul>
   Os filtros predefinidos dispon&iacute;veis s&atilde;o:<br />
   <ul class="normallist">
      <li>Sub-F&oacute;rum.</li>
      <li>Assunto.</li>
      <li>Come&ccedil;o do assunto.</li>
      <li>Primeiro caractere do assunto.</li>
      <li>Dados do t&oacute;pico / Dado publicado.</li>
      <li>Dados da &uacute;ltima resposta / Dado publicado.</li>
      <li>Postado por.</li>
      <li>T&oacute;pico com novos posts / Novo.</li>
      <li>Fixos.</li>
      <li>Trancado.</li>
      <li>Respostas.</li>
      <li>Enquete.</li>
   </ul>
   As a&ccedil;&otilde;es a serem realizadas em um grupo de campos personalizados s&acirc;o: vis&acirc;o, adicionar, modificar, apagar e mover.<br />
   Al&eacute;m disso s&atilde;o poss&iacute;veis outras a&ccedil;&otilde;es usando campos personalizados:<br />
   <ul class="normallist">
      <li>Filtrar o &iacute;ndice de mensagens.</li>
      <li>Organizar o &iacute;ndice de mensagens.</li>
      <li>Mostrar estat&iacute;sticas.</li>
      <li>Pesquisar nas &aacute;reas de mensagens, obter uma lista de posts.</li>
      <li>Pesquisar nas &aacute;reas de registros, obtendo uma lista de registros.</li>
   </ul>
   <br />
   <b>Painel de administra&ccedil;&atilde;o</b><br />
   O painel de administra&ccedil;&atilde;o tem a lista dos grupos de campos personalizados, o que permite adicionar novos grupos, modificar ou excluir grupos existentes, adicionar, modificar ou excluir campos de um grupo e definir modelos para exibir esses campos em um post e no &iacute;ndice de mensagens.<br />
   <br />
   <b>Visualizando posts com campos personalizados</b><br />
   Ao visualizar um post completo (em um t&oacute;pico, em posts ou perfil recentes) s&atilde;o apresentados seus grupos (que s&atilde;o ativados quando o post &eacute; criado ou modificado). Grupo do tipo &quot;solto campos&quot; e &quot;registros&quot; s&atilde;o mostrados acima do corpo do post, Considerando que os grupos de tipo &quot;campos com v&aacute;rios valores por membro&quot; s&atilde;o apresentados a seguir, a menos o que foi selecionado &quot;Mostrar como grupo de campos do t&oacute;pico&quot; e, em seguida, &eacute; apresentado no in&iacute;cio e/ou e do t&oacute;pico. Se um grupo tem o template por mensagens os campos s&atilde;o exibidos de acordo com o template, se n&atilde;o s&atilde;o exibidos com o seu nome e conte&uacute;do.<br />
   Em listas de posts (&iacute;ndice de mensagens, mensagem n&atilde;o lida e respostas) s&atilde;o grupos exibida com campos vis&iacute;veis no &iacute;ndice de mensagens (de acordo com as permiss&otilde;es). Se um grupo tem o template para o &iacute;ndice de mensagens os campos s&atilde;o exibidos de acordo com o template, se n&atilde;o s&atilde;o exibidos com o seu nome e conte&uacute;do.<br />
   <br />
   <b>Modificando valores em campos personalizados</b><br />
   Em um tópico, posts com grupos de tipo &quot;campos com v&aacute;rios valores por membro&quot; t&ecirc;m bot&ocirc;es para o usu&aacute;rio postar novos valores, e modificar ou remover os existentes.<br />
   Para todos os outros grupos (&quot;campos solto&quot; e &quot;registro&quot;), a criar ou modificar o post s&atilde;o exibidos grupos permitidos. Os grupos de tipo &quot;solto campos&quot; sempre t&ecirc;m seus campos vis&iacute;veis, enquanto que os grupos de tipo &quot;registro&quot; tem uma caixa de sele&ccedil;&atilde;o para mostrar ou ocultar os seus campos. Se tem sido modelo criado para a entrada r&aacute;pida em um registro, <strong>Campo de entrada r&aacute;pida</strong> &eacute; exibido ap&oacute;s os campos de registro.<br />
   <br />
   <b>Movendo um grupo de campos personalizados para outro post</b><br />
   Um grupo de campos pode ter de ser atribu&iacute;do a um outro post, por exemplo, antes de remover o post onde &eacute; o grupo.<br />
   Se o utilizador tem permiss&atilde;o para mover um grupo, ao visualizar um tema que grupo ter&aacute; bot&otilde;es para ir para o primeiro post do t&oacute;pico ou outro post (ou outro t&oacute;pico se o grupo &eacute; do tipo &quot;campos com v&aacute;rios valores por membro&quot; e selecionou &quot; Mostrar como grupo de campos do t&oacute;pico&quot;).<br />
   <br />
   <b>Filtrar o &iacute;ndice de mensagens</b><br />
   Se o utilizador tem permiss&atilde;o para filtrar por um campo, um bot&atilde;o &eacute; exibido no &iacute;ndice de mensagens para filtrar t&oacute;picos por esse campo.<br />
   Tipo de bot&atilde;o de filtro depende do tipo de campo:<br />
   <ul class="normallist">
      <li>O filtro para o texto ou campos de texto grandes &eacute; um bot&atilde;o de texto em que entrar na cadeia de pesquisa, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
      <li>Campos tipo caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de ter pelo filtro de um bot&atilde;o de texto, uma caixa de sele&ccedil;&atilde;o ou uma caixa de combina&ccedil;&atilde;o em que digitar ou selecionar o texto a procurar, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
      <li>Para campos do tipo booleano o filtro &eacute; uma caixa de sele&ccedil;&atilde;o com os valores &quot;Sim&quot; e &quot;Nenhum&quot;.</li>
   </ul>
   Se o usu&aacute;rio pode modificar um campo, que o campo pode estar vazio e seu filtro &eacute; uma caixa de sele&ccedil;&atilde;o ou caixa de combina&ccedil;&atilde;o, ele verá uma op&ccedil;&atilde;o na lista para obter dados com esse campo vazio.<br />
   Al&eacute;m disso, com um grupo de tipo &quot;filtros&quot; podem ser adicionados filtros predefinidos.<br />
   O filtro com o bot&atilde;o texto permite pesquisar palavras soltas (separados por espa&ccedil;os) e/ou fases literais (entre aspas duplas).<br />
   Se o filtro &eacute; do tipo de texto ou caixa de combina&ccedil;&atilde;o, por padr&atilde;o, ele &eacute; procurado que o texto est&aacute; contido no valor do campo, enquanto que se o filtro &eacute; o tipo de lista de sele&ccedil;&atilde;o de caixa &eacute; pedido que o texto corresponde ao valor do campo.<br />
   Os filtros podem ser do mesmo grupo ou grupos diferentes de campos.<br />
   Ao lado de filtros h&aacute; um bot&atilde;o para ativar os filtros que foram dadas algum valor. Como resultado obt&eacute;m-se o &iacute;ndice de mensagens com t&oacute;picos cujo cargo primeira corresponde a todos os filtros ativos.<br />
   <br />
   <b>Ordenar o &iacute;ndice de mensagens</b><br />
   Se o usu&aacute;rio tem permiss&atilde;o para classificar por um ou mais campos, uma caixa de sele&ccedil;&atilde;o &eacute; exibido no &iacute;ndice de mensagens para classificar t&oacute;picos por um desses campos.<br />
   <br />
   <b>Mostrar estat&iacute;sticas</b><br />
   Se um grupo de tipo &quot;campos com v&aacute;rios valores por membro&quot; tem um &uacute;nico campo e &eacute; de tyoe caixa de sele&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas (isto &eacute;, existe um n&uacute;mero finito de valores), pode ser gerar dados estat&iacute;sticos a partir dos valores inseridos no campo.<br />
   Os dados estat&iacute;sticos a serem exibidos incluem:<br />
   <ul class="normallist">
      <li>Gr&aacute;fico com m&eacute;dia: &Eacute; constitu&iacute;da por uma barra horizontal onde o valor m&eacute;dio, o valor mais baixo permitido e o maior valor permitido est&atilde;o localizados.</li>
      <li>Gr&aacute;fico com barras horizontais: Representa a utilização de cada valor permitido atrav&eacute;s de barras horizontais.</li>
      <li>Gr&aacute;fico com barras verticais: Representa a utilização de cada valor permitido por meio de barra vertical.</li>
      <li>Resumo: Um conjunto de dados obtidos a partir dos valores de entrada (m&eacute;dia, o valor mais alto e mais baixo permitido, maior eo menor valor usado, valor mais e menos frequente).</li>
   </ul>
   O usu&aacute;rio v&ecirc; estes dados apenas se tiver permiss&atilde;o. O &iacute;ndice de mensagens pode ser ordenado por os dados de resumo, se ele tem permiss&atilde;o para classificar pelo campo.<br />
   Usando templates podem ser inseridos os dados estat&iacute;sticos de qualquer grupo de campos em outro lugar.<br />
   <br />
   <b>Pesquisa em campos</b><br />
   ' . (!$smf_version_1 ? 'Sob a op&ccedil;&atilde;o &quot;Pesquisa&quot; a partir do f&oacute;rum menu p&aacute;ginas de pesquisa est&atilde;o localizados' : 'A op&ccedil;&atilde;o &quot;Mensagens de pesquisa e registros&quot; a partir do menu f&oacute;rum fornece acesso &agrave;s p&aacute;ginas de pesquisa') . ', mostrando os grupos e seus campos no qual o usu&aacute;rio tem permiss&atilde;o de busca.<br />
   Grupos de tipo &quot;solto campos&quot;, &quot;campos com v&aacute;rios valores por membro&quot; e &quot;filtros&quot; pode estar em v&aacute;rias p&aacute;ginas de busca, e cada p&aacute;gina cont&eacute;m v&aacute;rios grupos, com a &uacute;nica condi&ccedil;&atilde;o de que os grupos em uma p&aacute;gina deve ser permitida em um conjunto comum de mensagens. Como resultado de pesquisa uma lista de postos &eacute; obtido.<br />
   Para cada grupo de tipo &quot;registro&quot; com a permiss&atilde;o de busca tem uma p&aacute;gina. Como resultado, uma lista de registos &eacute; obtido com as colunas indicadas na defini&ccedil;&atilde;o dos campos.<br />
   Em ambos os casos, os bot&otilde;es usados em cada campo de busca seguir a mesma regra que nos filtros.<br />
   <br />
   <b>Contador na informa&ccedil;&atilde;o sobre o usu&aacute;rio</b><br />
   O n&uacute;mero de cada tipo de registro criado pelo membro pode ser exibido nas informa&ccedil;&otilde;es desse membro.<br />
   Isto pode ser visto em diversas &aacute;reas, tais como o perfil do usu&aacute;rio e informa&ccedil;&atilde;o do membro sobre a postagem de cada mensagem.<br />
   &quot;Centro de Administra&ccedil;&atilde;o &gt; Manuten&ccedil;&atilde;o do F&oacute;rum &gt; ' . (!$smf_version_1 ? 'Rotina' : 'Manuten&ccedil;&atilde;o Geral') . ' &gt; Recontar todos os totais e estat&iacute;sticas do f&oacute;rum&quot; tamb&eacute;m relata o n&uacute;mero de cada tipo de registro criado por membros.<br />' . (!$smf_version_1 ? '
   <br />
   <b>Lista no perfil de membro</b><br />
   No perfil de membro, na se&ccedil;&atilde;o &quot;Informa&ccedil;&otilde;es do perfil &gt; Exibi Posts&quot;, pode ser mostrar uma lista para cada grupo de tipo &quot;registro&quot;, com mensagens postadas pelo pr&oacute;prio usu&aacute;rio contendo este tipo de grupo.<br />
   <br />
   <b>Lista em Centro de Moderar</b><br />
   No Centro de modera&ccedil;&atilde;o &eacute; poss&iacute;vel controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
   Para cada grupo que escolheu para mostrar esta lista ser&aacute; exibido um acesso &agrave; lista na se&ccedil;&atilde;o &quot;Posts &gt; Grupo de campos no posts&quot; e, opcionalmente, um link abaixo da op&ccedil;&atilde;o &quot;Moderado&quot; a partir do menu de f&oacute;rum.' : '
   <br />
   <b>Lista de modera&ccedil;&atilde;o</b><br />
   Moderadores globais podem controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
   A op&ccedil;&atilde;o &quot;Moderar os grupos de campos em mensagens&quot; a partir do menu f&oacute;rum fornece acesso &agrave; lista com dados lan&ccedil;ados, um para cada grupo, que escolheu para mostrar esta lista.');
$helptxt['cffp_enclose'] = 'Envolve a entrada do usu&aacute;rio entre algum texto (criado com HTML, BBC or PHP). Isso permitir&aacute; que voc&ecirc; adicione mais provedores de mensagens instant&acirc;neas, imagens ou uma incorpora&ccedil;&atilde;o etc. Por exemplo:<br />
   <br />
   &lt;a href="http://website.com/{INPUT}"&gt;&lt;img src="{DEFAULT_IMAGES_URL}/icon.gif" alt="{INPUT}" /&gt;&lt;/a&gt;<br />
   <br />
   Pode utilizar as seguintes vari&aacute;veis<br />
   <ul class="normallist">
      <li><tt>{INPUT}</tt> - A entrada especificada pelo utilizador.</li>
      <li><tt>{TEXT_PREVIOUS}</tt> - HTML para colocar antes do texto de sa&iacute;da.</li>
      <li><tt>{TEXT_NEXT}</tt> - HTML para colocar a seguir o texto de sa&iacute;da.</li>
      <li><tt>{FIELD_</tt><i>n</i><tt>_DATABASE}</tt> - O nome do campo no banco de dados do campo ID <i>n</i>. O campo pode ser de qualquer grupo.</li>
      <li><tt>{ID_MSG}</tt> - ID da mensagem atual.</li>
      <li><tt>{BOARDURL}</tt> - URL a pasta f&oacute;rum.</li>
      <li><tt>{SCRIPTURL}</tt> - Endere&ccedil;o da Web do f&oacute;rum.</li>
      <li><tt>{IMAGES_URL}</tt> - URL a pasta de imagens no usu&aacute;rios tema atual.</li>
      <li><tt>{DEFAULT_IMAGES_URL}</tt> - URL para a pasta de imagens no tema padr&atilde;o.</li>
   </ul>
   No PHP, voc&ecirc; tamb&eacute;m pode usar as seguintes fun&ccedil;&otilde;es:<br />
   <ul class="normallist">
      <li><tt>{SHOW_GROUP_MSG}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>)</tt> - Exibe o grupo de uma mensagem como em uma mensagem.</li>
      <li><tt>{SHOW_GROUP_MSGINDEX}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>)</tt> - Exibe o grupo de uma mensagem como no &iacute;ndice de mensagens.</li>
      <li><tt>{SHOW_GROUP_MSG_STATS}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>, &apos;</tt><i>tipo</i><tt>&apos;, &apos;</tt><i>params</i><tt>&apos;)</tt> - Exibe as estat&iacute;sticas para o grupo de uma mensagem (se s&atilde;o ativados). O par&acirc;metro <i>tipo</i> pode ser:
         <ul class="normallist">
            <li><tt>chart_average</tt> - Exibe o gr&aacute;fico com a m&eacute;dia. O par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio mostrado), <tt>minmax</tt> (valor mais baixo e mais alto permitido mostrado), <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
            <li><tt>chart_hbars</tt> - Apresenta o gr&aacute;fico com barras horizontais. O par&acirc;metro <i>params</i> n&atilde;o &eacute; utilizada.</li>
            <li><tt>chart_vbars</tt> - Exibe o gr&aacute;fico com barras verticais. O par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
            <li><tt>summary</tt> - Exibe o resumo. O par&acirc;metro <i>params</i> indica valores para mostrar, separados por v&iacute;rgulas. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
            <li><tt>value</tt> - Exibe um valor de resumo. O par&acirc;metro <i>params</i> indica o valor a ser exibido. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
         </ul></li>
   </ul>';
$helptxt['cffp_mask'] = 'A m&aacute;scara de introdu&ccedil;&atilde;o &eacute; importante para a seguran&ccedil;a do seu f&oacute;rum. Validar a introdu&ccedil;&atilde;o do utilizador ajuda a assegurar que os dados n&atilde;o s&atilde;o utilizados de outra forma que n&atilde;o a esperada. Algumas express&otilde;es regulares simples s&atilde;o fornecidas a t&iacute;tulo de exemplo.<br /><br />
   <div class="smalltext" style="margin: 0 2em">
      &quot;[A-Za-z]+&quot; - Corresponder todas as mai&uacute;sculas e min&uacute;sculas do alfabeto.<br />
      &quot;[0-9]+&quot; - Corresponder todos os caracteres num&eacute;ricos.<br />
      &quot;[A-Za-z0-9]{7}&quot; - Corresponder todas as mai&uacute;sculas e min&uacute;sculas do alfabeto e caracteres num&eacute;ricos sete vezes.<br />
      &quot;[^0-9]?&quot; - Proibir a correspond&ecirc;ncia de qualquer n&uacute;mero.<br />
      &quot;^([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6})$&quot; - Permitir apenas 3 ou 6 caracteres hexadecimais.<br />
   </span><br /><br />
   Adicionalmente, podem ser definidos os meta-caracteres especiais ?+*^$ e {xx} .
   <div class="smalltext" style="margin: 0 2em">
      ? - Nenhuma ou uma correspond&ecirc;ncia da express&atilde;o anterior.<br />
      + - Uma ou mais correspond&ecirc;ncias da express&atilde;o anterior.<br />
      * - Nenhuma ou mais da express&atilde;o anterior.<br />
      {xx} - Um n&uacute;mero exacto da express&atilde;o anterior.<br />
      {xx,} - Um n&uacute;mero exacto ou mais da express&atilde;o anterior.<br />
      {,xx} - Um n&uacute;mero exacto ou menos da express&atilde;o anterior.<br />
      {xx,yy} - Um n&uacute;mero de correspond&ecirc;ncias dentro da gama dos argumentos xx e yy, da express&atilde;o anterior.<br />
      $ - Início de string.<br />
      ^ - Fim de string.<br />
      \\ - Escape do pr&oacute;ximo caracter.<br />
   </div><br /><br />
   Mais informa&ccedil;&otilde;es e t&eacute;cnicas avan&ccedil;adas podem ser encontradas na internet.';
$helptxt['cffp_fieldtype'] = 'Tipos de campos que podem ser criados s&atilde;o:<br />
   <ul class="normallist">
      <li>Texto: O campo no qual pode digitar o texto de uma linha.</li>
      <li>Grande texto: O campo que permite que tipo multi-linha de texto.</li>
      <li>Caixa de escolha: O campo que exibe um menu de op&ccedil;&otilde;es para selecionar. O campo pode ser &uacute;nica sele&ccedil;&atilde;o (permite selecionar apenas uma op&ccedil;&atilde;o) ou m&uacute;ltiplo (permite selecionar v&aacute;rias op&ccedil;&otilde;es de uma s&oacute; vez).</li>
      <li>Caixa de combina&ccedil;&atilde;o: Combina&ccedil;&atilde;o de caixa de sele&ccedil;&atilde;o (sele&ccedil;&atilde;o &uacute;nica ou m&uacute;ltipla) e caixa de texto, permitindo digitar um valor (ou valores separados por vírgulas) ou escolher a partir de uma lista de op&ccedil;&otilde;es.</li>
      <li>Acionamento tipo Radio: Conjunto de op&ccedil;&otilde;es a partir do qual s&oacute; pode escolher um.</li>
      <li>Caixas de sele&ccedil;&atilde;o: Conjunto de op&ccedil;&otilde;es a partir do qual voc&ecirc; pode escolher v&aacute;rios de uma vez.</li>
      <li>Booleano: Apenas uma op&ccedil;&atilde;o que pode ser seleccionado (valor &quot;verdadeiro&quot;) ou n&atilde;o (valor &quot;falso&quot;).</li>
   </ul>';
$helptxt['cffp_grouptype'] = 'Um grupo de campos podem ser do tipo:<br />
   <ul class="normallist">
      <li>Campos soltos: Seus campos são adicionados a um post para fornecer informa&ccedil;&otilde;es extra. Na busca de dados em campos soltos de um post obtendo uma lista de posts.</li>
      <li>Registro: &Eacute; um conjunto de campos que representa uma entidade independente do post. Na busca de dados em campos de um registro &eacute; obt&eacute;m uma lista de registros. O corpo do post n&atilde;o pode ser deixado em branco, mas um post com registro n&atilde;o precisa de corpo. Se o usu&aacute;rio ir&aacute; adicionar um registro e o corpo do post estiver vazio, o sistema grava um per&iacute;odo (&quot;.&quot;) sobre ele e o usu&aacute;rio n&atilde;o precisa escrever nada.</li>
      <li>Os campos com v&aacute;rios valores por membro: Ele &eacute; definido de campos onde v&aacute;rios usu&aacute;rios podem inserir valores diferentes. Isso pode ser usado para os membros para fazer coment&aacute;rios ou avalia&ccedil;&otilde;es sobre o post.</li>
      <li>Filtros: Este &eacute; um tipo especial de grupo sem campos. Usado para habilitar um conjunto de filtros pr&eacute;-definidos que podem ser usados em t&oacute;picos e mensagens.</li>
   </ul>';
$helptxt['cffp_type_filter'] = 'Tipo de bot&atilde;o de filtro depende do tipo de campo:<br />
   <ul class="normallist">
      <li>O filtro para o texto ou campos de texto grandes &eacute; um bot&atilde;o de texto para entrar na cadeia de pesquisa, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
      <li>Campos tipo caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de ter pelo filtro de um bot&atilde;o de texto, uma caixa de sele&ccedil;&atilde;o ou uma caixa de combina&ccedil;&atilde;o em que digitar ou selecionar o texto a procurar, ou uma caixa de sele&ccedil;&atilde;o para obter dados com esse campo vazio ou n&atilde;o vazio.</li>
      <li>Para campos do tipo booleano o filtro &eacute; uma caixa de sele&ccedil;   &atilde;o com os valores &quot;Sim&quot; e &quot;N&atilde;o&quot;.</li>
   </ul>
   Se o usu&aacute;rio pode modificar um campo, que o campo pode estar vazio e seu filtro &eacute; uma caixa de sele&ccedil;&atilde;o ou caixa de combina&ccedil;&atilde;o, ele ver&aacute; uma op&ccedil;&atilde;o na lista para obter dados com esse campo vazio.<br />
   O filtro com o bot&atilde;o texto permite pesquisar palavras soltas (separados por um espa&ccedil;o) e/ou fases literais (entre aspas duplas).<br />
   Se o filtro &eacute; do tipo de texto ou caixa de combina&ccedil;&atilde;o, por padr&atilde;o, ele &eacute; procurado que o texto est&aacute; contido no valor do campo, enquanto que se o filtro &eacute; o tipo de lista de sele&ccedil;&atilde;o de caixa &eacute; pedido que o texto corresponde ao valor do campo.';
$helptxt['cffp_options'] = 'Esta se&ccedil;&atilde;o define as op&ccedil;&otilde;es que o usu&aacute;rio pode escolher a partir de uma caixa de sele&ccedil;&atilde;o, caixa de combina&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de sele&ccedil;&atilde;o. Existem alguns pontos-chave a serem observados nesta se&ccedil;&atilde;o:<br />
   <ul class="normallist">
      <li>As op&ccedil;&otilde;es padr&atilde;o: Qualquer que seja a caixa de opop&ccedil;&otilde;eses tem a &quot;bot&atilde;o de r&aacute;dio&quot; (pode haver apenas um) ou &quot;Caixas de sele&ccedil;&atilde;o&quot; (pode ser v&aacute;rias) ao lado desse selecionado ser&aacute; as sele&ccedil;&otilde;es padr&atilde;o para o utilizador quando entram dados.</li>
      <li>Remo&ccedil;&atilde;o de opcionais: Para remover uma op&ccedil;&atilde;o simplesmente vazia na caixa de texto para essa op&ccedil;&atilde;o - todas as mensagens com o seleccionado ter&aacute; sua op&ccedil;&atilde;o desmarcada.</li>
      <li>Reordenar op&ccedil;&otilde;es: Voc&ecirc; pode reordenar as op&ccedil;&otilde;es movendo texto em torno entre as caixas. Contudo - uma nota importante - voc&ecirc; deve se certificar do que voc&ecirc; faz <strong>n&atilde;o</strong> mudar o texto quando reordena&ccedil;&atilde;o op&ccedil;&otilde;es em contr&aacute;rio dados postados ser&atilde;o perdidos.</li>
      <li>Texto (dispon&iacute;vel se o bot&atilde;o n&atilde;o &eacute; uma caixa de combina&ccedil;&atilde;o): Uma op&ccedil;&atilde;o pode ser exibido com valor real ou com um texto mais significativo para o usu&aacute;rio.</li>
      <li>Adicione v&aacute;rias op&ccedil;&otilde;es: Permite adicionar v&aacute;rias op&ccedil;&otilde;es de uma s&oacute; vez, escrevendo cada op&ccedil;&atilde;o em uma linha do campo de texto grande. Cada op&ccedil;&atilde;o tem valor e, se o bot&atilde;o n&atilde;o &ecirc; uma caixa de combinaç&atilde;o, texto, separados por v&iacute;rgulas. Texto &ecirc; opcional.</li>
   </ul>';
$helptxt['cffp_javascript'] = 'C&oacute;digo JavaScript executado quando um grupo de campos &eacute; criado ou modificado.<br />
   Permite a execu&ccedil;&atilde;o de c&oacute;digo quando um evento ocorre ao longo de um bot&atilde;o de formul&aacute;rio ou outro elemento HTML.<br />
   Isto pode ser escrito como:<br />
   <br />
   <tt>document.getElementsByName(</tt><i>html_nome_elemento</i><tt>)[0].</tt><i>nome_evento</i><tt> = function (event)<br />
   {<br />
   &nbsp;&nbsp;&nbsp;&nbsp;// ...<br />
   }<br />
   document.getElementById(</tt><i>html_id_elemento</i><tt>).</tt><i>nome_evento</i><tt> = function (event)<br />
   {<br />
   &nbsp;&nbsp;&nbsp;&nbsp;// ...<br />
   }</tt><br />
   <br />
   Por exemplo, este c&oacute;digo mostra uma mensagem quando o usu&aacute;rio clica no bot&atilde;o <tt>id1</tt> e copiar o valor do bot&atilde;o <tt>id2</tt> sobre o assunto quando o usu&aacute;rio alterar esse valor:<br />
   <br />
   <tt>document.getElementById(&quot;id1&quot;).onclick = function (event)<br />
   {<br />
   &nbsp;&nbsp;&nbsp;&nbsp;alert(&quot;Uma mensagem&quot;);<br />
   }<br />
   document.getElementById(&quot;id2&quot;).onchange = function (event)<br />
   {<br />
   &nbsp;&nbsp;&nbsp;&nbsp;document.getElementsByName(&quot;subject&quot;)[0].value = this.value;<br />
   }</tt>';
$helptxt['cffp_stats'] = 'Se um grupo de tipo &quot;campos com v&aacute;rios valores por membro&quot; tem um &uacute;nico campo e &eacute; do tipo caixa de sele&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas (isto &eacute;, existe um n&uacute;mero finito de valores), pode gerar dados estat&iacute;sticos a partir dos valores inseridos no campo.<br />
   Os dados estat&iacute;sticos a serem exibidos incluem:<br />
   <ul class="normallist">
      <li>Gr&aacute;fico com m&eacute;dia: &Eacute; constitu&iacute;da por uma barra horizontal, onde o valor m&eacute;dio, o valor mais baixo permitido e o valor mais elevado permitido est&atilde;o localizados.</li>
      <li>Gr&aacute;fico com barras horizontais: Representa o uso de cada valor permitido por barras horizontais.</li>
      <li>Gr&aacute;fico com barras verticais: Representa o uso de cada valor permitido por barra vertical.</li>
      <li>Resumo: Um conjunto de dados obtidos a partir dos valores de entrada (m&eacute;dia, o valor mais alto e mais baixo permitido, maior e o menor valor usado, valor mais e menos frequente).</li>
   </ul>
   O usu&aacute;rio v&ecirc; estes dados apenas se tiver permiss&atilde;o. O &iacute;ndice de mensagens pode ser ordenado por os dados de resumo, se ele tem permiss&atilde;o para classificar pelo campo.<br />
   Usando templates que podem ser inseridos os dados estat&iacute;sticos de qualquer grupo de campos em outro lugar.';
$helptxt['cffp_search_page'] = (!$smf_version_1 ? 'Sob a op&ccedil;&atilde;o &quot;Pesquisa&quot; a partir do menu f&oacute;rum, p&aacute;ginas de pesquisa s&atilde;o localizados' : 'A op&ccedil;&atilde;o &quot;Pesquisa de posts e registros&quot; a partir do menu f&oacute;rum fornece acesso &agrave;s p&aacute;ginas de pesquisa') . ', mostrando os grupos e seus campos no qual o usu&aacute;rio tem permiss&atilde;o de busca.<br />
   Grupos de tipo &quot;campos soltos&quot;, &quot;campos com cada valor por membro&quot; e &quot;filtro&quot; pode ser em cada p&aacute;gina de pesquisa, e cada p&aacute;gina cont&eacute;m v&aacute;rios grupo, com a &uacute;nica condi&ccedil;&atilde;o de que os grupos em uma p&aacute;gina deve ser permitida em um conjunto comum de mensagens. Como resultado de pesquisa uma lista de postos &eacute; obtido.<br />
   Para cada grupo de tipo &quot;registro&quot; com a permiss&atilde;o de busca tem uma p&aacute;gina. Como resultado, uma lista de registos &eacute; obtido com as colunas indicadas na defini&ccedil;&atilde;o dos campos.';
$helptxt['cffp_counter'] = 'O n&uacute;mero de cada tipo de registro criado pelo membro pode ser exibido nas informa&ccedil;&otilde;es desse membro.<br />
   Isto pode ser visto em diversas &aacute;reas, tais como o perfil do usu&aacute;rio e informa&ccedil;&atilde;o do membro sobre a postagem de cada mensagem.<br />
   &quot;Centro de Administra&ccedil;&atilde;o &gt; Manuten&ccedil;&atilde;o do F&oacute;rum &gt; ' . (!$smf_version_1 ? 'Rotina' : 'Manuten&ccedil;&atilde;o Geral') . ' &gt; Recontar todos os totais e estat&iacute;sticas do f&oacute;rum&quot; tamb&eacute;m relata o n&uacute;mero de cada tipo de registro criado por membros.';
$helptxt['cffp_profile_list'] = 'No perfil de membro, na se&ccedil;&atilde;o &quot;Informa&ccedil;&otilde;es do Perfil &gt; Ver Posts&quot;, pode mostrar uma lista para cada grupo de tipo &quot;registro&quot;, com mensagens postadas pelo pr&oacute;prio usu&aacute;rio contendo este tipo de grupo.';
if (!$smf_version_1)
{
   $helptxt['cffp_moderation_list'] = 'No Comando do moderador &eacute; poss&iacute;vel controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
   Para cada grupo que escolheu para mostrar esta lista ser&aacute; exibido um acesso &agrave; lista na se&ccedil;&atilde;o &quot;Posts &gt; Grupos de campos em posts&quot; e, opcionalmente, um link abaixo da op&ccedil;&atilde;o &quot;Moderado&quot; a partir do menu de f&oacute;rum.';
}
else
{
   $helptxt['cffp_moderation_list'] = 'Moderadores globais podem controlar o conte&uacute;do postado pelos usu&aacute;rios nos grupos do tipo &quot;campos com v&aacute;rios valores por membro&quot;.<br />
   A op&ccedil;&atilde;o &quot;Moderar os grupos de campos nas mensagens&quot; a partir do menu f&oacute;rum fornece acesso &agrave; lista com dados lan&ccedil;ados, um para cada grupo, que escolheu para mostrar esta lista.';
}
$helptxt['cffp_template_text'] = 'Texto usado para exibir o conte&uacute;do de campos em grupo.<br />
   Você pode usar as seguintes vari&aacute;veis:<br />
   <ul class="normallist">
      <li><tt>{FIELD_</tt><i>n</i><tt>_NAME}</tt> - Nome de campo ID <i>n</i>.</li>
      <li><tt>{FIELD_</tt><i>n</i><tt>_VALUE}</tt> - Valor de campo ID <i>n</i>.</li>
      <li><tt>{FIELD_</tt><i>n</i><tt>_DATABASE}</tt> - O nome do campo no banco de dados do campo ID <i>n</i>. O campo pode ser de qualquer grupo.</li>
      <li><tt>{ID_MSG}</tt> - ID da mensagem atual.</li>
      <li><tt>{BOARDURL}</tt> - URL para pasta f&oacute;rum.</li>
      <li><tt>{SCRIPTURL}</tt> - Endere&ccedil;o Web do f&oacute;rum.</li>
      <li><tt>{IMAGES_URL}</tt> - URL para pasta de imagens no usu&aacute;rios tema atual.</li>
      <li><tt>{DEFAULT_IMAGES_URL}</tt> - URL para pasta de imagens no tema padr&atilde;o.</li>
   </ul>
   No PHP, voc&ecirc; tamb&eacute;m pode usar as seguintes fun&ccedil;&otilde;es:<br />
   <ul class="normallist">
      <li><tt>{SHOW_GROUP_MSG}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>)</tt> - Exibe o grupo de uma mensagem como em uma mensagem.</li>
      <li><tt>{SHOW_GROUP_MSGINDEX}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>)</tt> - Exibe o grupo de uma mensagem como no &iacute;ndice de mensagens.</li>
      <li><tt>{SHOW_GROUP_MSG_STATS}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>, &apos;</tt><i>tipo</i><tt>&apos;, &apos;</tt><i>params</i><tt>&apos;)</tt> - Exibe as estat&iacute;sticas para o grupo de uma mensagem (se s&atilde;o ativados). O par&acirc;metro <i>tipo</i> pode ser:
         <ul class="normallist">
            <li><tt>chart_average</tt> - Exibe o gr&aacute;fico com a m&eacute;dia. O par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio mostrado), <tt>minmax</tt> (valor mais baixo e mais alto permitido mostrado), <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
            <li><tt>chart_hbars</tt> - Exibe o gr&aacute;fico com barras horizontais. O par&acirc;metro <i>params</i> n&atilde;o &eacute; utilizada.</li>
            <li><tt>chart_vbars</tt> - Exibe o gr&aacute;fico com barras verticais.O par&acirc;metro <i>params</i> indica as caracter&iacute;sticas do gr&aacute;fico. Os valores permitidos: <tt>options_text</tt> (mostrado o texto de op&ccedil;&otilde;es).</li>
            <li><tt>summary</tt> - Exibe o resumo. O par&acirc;metro <i>params</i> indica valores para mostrar, separados por v&iacute;rgulas. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
            <li><tt>value</tt> - Exibe um valor de resumo. O par&acirc;metro <i>params</i> indica o valor a ser exibido. Os valores permitidos: <tt>average</tt> (valor m&eacute;dio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (valor mais frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
         </ul></li>
   </ul>
   Esvazie o campo de texto para excluir o modelo. Se o modelo n&atilde;o est&aacute; campos definidos s&atilde;o exibidos com o seu nome e conte&uacute;do.';
$helptxt['cffp_template_message_index_text'] = $helptxt['cffp_template_text'];
$helptxt['cffp_template_quick_input'] = 'Texto usado para criar um registro.<br />
   Permite que preencher todos os campos de uma s&oacute; vez, escrevendo todos os valores em um &uacute;nico campo, chamado <strong>Campo de entrada r&aacute;pida</strong>, de acordo com um modelo ou uma express&atilde;o regular.<br />
   A express&atilde;o regular deve ser compat&iacute;vel com JavaScript. usado em <tt>String.match(regex)</tt> m&eacute;todo e deve ser obtida uma matriz de valores de campo come&ccedil;ando com a chave 1.<br />
   O par&acirc;metros de template consistem em linhas de texto:<br />
   <ul class="normallist">
      <li>Para cada elemento da matriz obtida a partir da express&atilde;o regular acrescenta uma linha com o campo ID.</li>
      <li>Linhas que seguem a ordem da matriz.</li>
      <li>Se um elemento de matriz n&atilde;o corresponde a qualquer campo, cont&eacute;m texto n&atilde;o utilizado e em que a linha &eacute; escrito 0.</li>
      <li>Se &eacute; necess&aacute;rio formatar um valor antes de copi&aacute;-lo em seu campo, sob a linha que cont&eacute;m o ID campo outra linha &eacute; adicionado com o c&oacute;digo JavaScript que transforma o valor. <tt>value</tt> vari&aacute;vel cont&eacute;m o valor original e deve conter o valor transformado. com <tt>field_obj</tt> array, indexado pelo campo ID, n&atilde;o h&aacute; acesso a todos os campos do formul&aacute;rio no registro.</li>
   </ul>
   Por exemplo, se o registro tem esses campos<br />
   <br />
   <table>
      <thead>
         <tr>
            <th>Nome</th>
            <th>ID</th>
         </tr>
      </thead>
      <tbody>
         <tr>
            <td>ID DocBook</td>
            <td>3</td>
         </tr>
         <tr>
            <td>Autor nome</td>
            <td>1</td>
         </tr>
         <tr>
            <td>Autor sobrenome</td>
            <td>2</td>
         </tr>
      </tbody>
   </table>
   <br />
   &eacute; definida<br />
   <br />
   Express&atilde;o regular: <tt>/^(.+)\s+(.+)\s+(.+)\s*/</tt><br />
   Par&acirc;metros:<br />
   <tt>3<br />
   1<br />
   var x = value.split(/\s+/g); for (var i = 0; i < x.length; i++) { var parts = x[i].match(/(\w)(\w*)/); x[i] = parts[1].toUpperCase() + parts[2].toLowerCase(); } value = x.join(&quot; &quot;);<br />
   2<br />
   var x = value.split(/\s+/g); for (var i = 0; i < x.length; i++) { var parts = x[i].match(/(\w)(\w*)/); x[i] = parts[1].toUpperCase() + parts[2].toLowerCase(); } value = x.join(&quot; &quot;);</tt><br />
   <br />
   e usu&aacute;rio escreve<br />
   <br />
   <tt>24<br />
   LEWIS CARROLL</tt><br />
   <br />
   campos ser&atilde;o preenchidos, assim:<br />
   <br />
   ID DocBook: 24<br />
   Autor nome: Lewis<br />
   Autor sobrenome: Carroll';
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post
Post by: Sakae on June 10, 2015, 10:34:35 AM
./Themes/default/languages/Modifications.portuguese_brazilian-utf8.php
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
global $forum_version;
$smf_version_1 = 0 === strpos($forum_version, 'SMF 1');
$txt['cffp'] = 'Campos personalizados e filtros de mensagens';
$txt['cffp_desc'] = 'Painel de administra&ccedil;&atilde;o para o &quot;Custom fields and filters of post&quot; MOD';
$txt['cffp_settings_display'] = 'Defini&ccedil;&otilde;es do campo';
$txt['cffp_settings_input'] = 'Configura&ccedil;&otilde;es de entrada';
$txt['cffp_settings_search'] = 'Filtros e configura&ccedil;&otilde;es de pesquisa';
$txt['cffp_settings_advanced'] = 'Ferramentas extras';
$txt['cffp_settings_grouptype'] = 'Configura&ccedil;&otilde;es para o tipo de &quot;%s&quot;'; // %s is a group type
$txt['cffp_field'] = 'Campo';
$txt['cffp_fields'] = 'Campos';
$txt['cffp_group'] = 'Grupo';
$txt['cffp_group_of_fields'] = 'Grupo de campos';
$txt['cffp_none_field'] = 'Voc&ecirc; n&atilde;o adicionou nenhum campo para o grupo!';
$txt['cffp_none_group'] = 'Voc&ecirc; n&atilde;o criou nenhum grupo de campos personalizados ainda!';
$txt['cffp_order'] = 'Ordem';
$txt['cffp_order_desc'] = 'Ordem do Display.';
$txt['cffp_text'] = 'Texto';
$txt['cffp_name'] = 'Nome';
$txt['cffp_field_description'] = 'Descri&ccedil;&atilde;o do campo';
$txt['cffp_field_description_desc'] = 'Exibido junto ao nome do.';
$txt['cffp_field_long_description'] = 'Descri&ccedil;&atilde;o longa de campo';
$txt['cffp_field_long_description_desc'] = 'Isso &eacute; exibido acima do bot&atilde;o. Admite BBC.';
$txt['cffp_field_search_description'] = 'Descri&ccedil;&atilde;o do campo na p&aacute;gina de busca';
$txt['cffp_field_search_description_desc'] = 'Exibido junto ao nome do.';
$txt['cffp_field_search_long_description'] = 'Descri&ccedil;&atilde;o longa de campo na p&aacute;gina de busca';
$txt['cffp_field_search_long_description_desc'] = 'Isso &eacute; exibido acima do bot&atilde;o. Admite BBC.';
$txt['cffp_description'] = 'Descri&ccedil;&atilde;o';
$txt['cffp_text_previous'] = 'Texto anterior';
$txt['cffp_text_previous_desc'] = 'HTML para colocar antes do bot&atilde;o de entrada e sa&iacute;da do texto. Se o campo &quot;Exibe fechado dentro do texto&quot; &eacute; utilizada para o texto de sa&iacute;da deve ser escrito <tt>{TEXT_PREVIOUS}</tt> vari&aacute;vel nesse.';
$txt['cffp_text_next'] = 'Pr&oacute;ximo texto';
$txt['cffp_text_next_desc'] = 'HTML para colocar depois do bot&atilde;o de entrada e fim do texto. Se o campo &quot;Exibe anexado dentro do texto&quot; &eacute; utilizada para o texto de sa&iacute;da deve ser escrito <tt>{TEXT_NEXT}</tt> vari&aacute;vel nesse.';
$txt['cffp_enclose'] = 'Mostrar dentro do texto';
$txt['cffp_enclose_desc'] = 'Recomendamos <strong>fortemente</strong> a utiliza&ccedil;&atilde;o de uma m&aacute;scara para validar a introdu&ccedil;&atilde;o de dados por parte do utilizador.';
$txt['cffp_text_input_before'] = 'Texto no display antes dos campos quando entrar com os dados';
$txt['cffp_text_input_before_desc'] = 'Admite BBC.';
$txt['cffp_text_input'] = 'Texto a ser exibido ao digitar os dados';
$txt['cffp_text_input_desc'] = 'Admite BBC.';
$txt['cffp_text_output'] = 'Texto a ser exibido durante a visualiza&ccedil;&atilde;o de dados';
$txt['cffp_text_output_desc'] = 'Admite BBC.';
$txt['cffp_type'] = 'Tipo';
$txt['cffp_type_filter'] = 'Tipo de filtro';
$txt['cffp_type_filter_desc'] = 'Tipo de acionamento usado no filtro de indicador de mensagens e t&oacute;picos de pesquisa.';
$txt['cffp_fieldtype_text'] = 'Texto';
$txt['cffp_fieldtype_textarea'] = 'Grande texto';
$txt['cffp_fieldtype_select'] = 'Caixa de escolha';
$txt['cffp_fieldtype_combobox'] = 'Caixa de combina&ccedil;&atilde;o';
$txt['cffp_fieldtype_radio'] = 'Acionamento tipo Radio';
$txt['cffp_fieldtype_check'] = 'Caixas de sele&ccedil;&atilde;o';
$txt['cffp_fieldtype_boolean'] = 'Booleano';
$txt['cffp_grouptype_fields'] = 'Campos soltos';
$txt['cffp_grouptype_record'] = 'Registro';
$txt['cffp_grouptype_member'] = 'Os campos com v&aacute;rios valores por membro';
$txt['cffp_grouptype_filters'] = 'Filtros';
$txt['cffp_length'] = 'O comprimento m&aacute;ximo de dados';
$txt['cffp_length_desc'] = '0 por nenhum limite.';
$txt['cffp_length_text_desc'] = 'A largura do campo proporcional a este valor. Se for 0 ou maior do que ou igual a 100, o campo ocupa a largura total.';
$txt['cffp_dimension'] = 'Medida da largura';
$txt['cffp_dimension_row'] = 'Fileiras';
$txt['cffp_dimension_col'] = 'Colunas';
$txt['cffp_dimension_col_desc'] = 'Se o &quot;Colunas&quot; se 0 ou maior do que ou igual a 100, o campo ocupa a largura total.';
$txt['cffp_mask'] = 'M&aacute;scara de entrada';
$txt['cffp_mask_desc'] = 'Para os campos de texto, pode ser seleccionada uma m&aacute;scara de entrada para validar os dados introduzidos.';
$txt['cffp_mask_email'] = 'Email';
$txt['cffp_mask_number'] = 'Num&eacute;rica';
$txt['cffp_mask_nohtml'] = 'Sem HTML';
$txt['cffp_mask_regex'] = 'Express&atilde;o regular (Avan&ccedil;ada)';
$txt['cffp_select_multiple'] = 'Selecionar mais de um';
$txt['cffp_select_size'] = 'Quantidade de campos vistos';
$txt['cffp_allow_bbc'] = 'Permitir BBC';
$txt['cffp_options'] = 'Escolhas';
$txt['cffp_options_desc'] = 'Deixe a caixa de escolha em branco para remover. Tecla de escolha ou caixa de escolha seleciona as alternativas marcadas.';
$txt['cffp_options_more'] = 'Mais';
$txt['cffp_options_add_multi'] = 'Adicionar mais de uma escolha';
$txt['cffp_options_add_multi_desc'] = 'Escreva uma escolha em cada linha. Cada escolha tem valor e texto, separados por virgulas. Texto opcional.';
$txt['cffp_options_add_multi_combo_desc'] = 'Escreva um alternativa para cada linha';
$txt['cffp_default_value'] = 'Valor oficial';
$txt['cffp_boards'] = 'Sub-F&oacute;runs';
$txt['cffp_child_boards'] = 'Incluir Sub-F&oacute;runs descendentes';
$txt['cffp_child_boards_until'] = 'At&eacute; %d n&iacute;vel';
$txt['cffp_show_group_name_message_index'] = 'Ver nome do grupo no &iacute;ndice da mensagens';
$txt['cffp_show_group_name_message_index_desc'] = 'Se nenhum grupo for selecionado, nenhum grupo exibido no &iacute;ndice da mensagens.';
$txt['cffp_show_group_name_filter'] = 'Ver o nome do grupo nos filtros';
$txt['cffp_show_group_name_filter_desc'] = 'Se nenhum nome de grupo de filtros for selecionado, nenhum grupo exibido no &iacute;ndice da mensagens.';
$txt['cffp_show_group_name_search'] = 'Ver o nome do grupo na busca';
$txt['cffp_show_group_name_search_desc'] = 'Se nenhum nome de grupo for selecionado, nenhum gropo exibido na busca.';
$txt['cffp_show_fields_name'] = 'Ver nome dos campos';
$txt['cffp_show_fields_name_desc'] = 'Se nenhum nome for selecionado, nada exibido ao lado dos campos do grupo.';
$txt['cffp_show_fields_set'] = 'Ver campos como um conjunto';
$txt['cffp_show_fields_set_desc'] = 'Se selecionado os campos, agrupa-se sob o nome do grupo.';
$txt['cffp_show_empty_fields_post'] = 'Ver campos vazios na mensagem';
$txt['cffp_show_empty_fields_message_index'] = 'Ver campos vazios no &iacute;ndice da mensagens';
$txt['cffp_show_poster_data'] = 'Exibir data de cria&ccedil;&atilde;o em dados postados';
$txt['cffp_show_modified_data'] = 'Exibir data da &uacute;ltima modifica&ccedil;&atilde;o em dados modificados';
$txt['cffp_show_actions_as'] = 'Ver atos como';
$txt['cffp_show_actions_as_button'] = 'Teclas';
$txt['cffp_show_actions_as_icon_text'] = 'Elemento e texto';
$txt['cffp_show_actions_as_icon'] = 'Elementos';
$txt['cffp_show_actions_as_text'] = 'Texto';
$txt['cffp_show_member_expanded'] = 'Ver expandido';
$txt['cffp_show_member_expanded_data'] = 'Ver expandido os dados postados';
$txt['cffp_show_member_expanded_data_recent'] = 'Ver expandido o mais recente dados postados';
$txt['cffp_show_member_expanded_data_recent_desc'] = '0 para todos.';
$txt['cffp_show_member_expanded_new'] = 'Ver expandido o nova respota';
$txt['cffp_show_member_recent_at_top'] = 'Ver o mais recente dados da mensagens no topo';
$txt['cffp_member_max_height'] = 'Maior altura do campo dos dados postados';
$txt['cffp_member_max_height_px'] = 'px';
$txt['cffp_member_max_height_desc'] = '0 para ilimitado.';
$txt['cffp_member_one_value'] = 'Apenas um valor por membro';
$txt['cffp_member_one_value_desc'] = 'Cada membro pode publicar os dados apenas uma vez.';
$txt['cffp_show_stats'] = 'Exibir estat&iacute;sticas';
$txt['cffp_show_stats_desc'] = 'O grupo deve ter apenas um campo, tipo caixa de sele&ccedil;&atilde;o, bot&otilde;es de r&aacute;dio ou caixas de sele&ccedil;&atilde;o.';
$txt['cffp_show_stats_post'] = 'Exibir estat&iacute;sticas no post';
$txt['cffp_show_stats_message_index'] = 'Exibir estat&iacute;sticas sobre &iacute;ndice de mensagens';
$txt['cffp_show_stats_text'] = 'Texto a ser exibido antes';
$txt['cffp_show_stats_text_desc'] = 'Admite BBC.';
$txt['cffp_show_stats_chart_average'] = 'Exibir gr&aacute;fico com média';
$txt['cffp_show_stats_chart_hbars'] = 'Exibir gr&aacute;fico com barras horizontais';
$txt['cffp_show_stats_chart_vbars'] = 'Exibir gr&aacute;fico com barras verticais';
$txt['cffp_show_stats_summary'] = 'Exibir resumo';
$txt['cffp_show_stats_summary_average'] = 'Valor m&eacute;dio';
$txt['cffp_show_stats_summary_max'] = 'Maior valor permitido';
$txt['cffp_show_stats_summary_min'] = 'Menor valor permitido';
$txt['cffp_show_stats_summary_highest'] = 'Maior valor usado';
$txt['cffp_show_stats_summary_lowest'] = 'Menor valor utilizado';
$txt['cffp_show_stats_summary_most_frequent'] = 'Mais valor frequente';
$txt['cffp_show_stats_summary_least_frequent'] = 'Valor menos frequente';
$txt['cffp_show_stats_only_numeric'] = 'Apenas se os dados sã&atilde;o numéricos';
$txt['cffp_show_stats_average'] = 'Exibir valor m&eacute;dio';
$txt['cffp_show_stats_minmax'] = 'Exibir valor mais baixo e mais alto permitido';
$txt['cffp_show_stats_options_text'] = 'Exibir o texto de op&ccedil;&otilde;es';
$txt['cffp_show_stats_order_by'] = 'Use estat&iacute;sticas para ordenar o &iacute;ndice de mensagens';
$txt['cffp_show_sticky'] = 'Ver em t&oacute;picos fixos';
$txt['cffp_show_locked'] = 'Mostrar em t&oacute;picos bloqueados';
$txt['cffp_show_first_post_topic'] = 'Ativar na primeira mensagem do t&oacute;pico';
$txt['cffp_show_replies_topic'] = 'Ativar nas respostas do t&oacute;pico';
$txt['cffp_no_show_with_subject_prefix'] = 'Exibir nenhum campo para inserir junto ao assunto';
$txt['cffp_no_show_with_subject_prefix_desc'] = 'Prefixos separados por v&iacute;rgulas. Exemplo:;.';
$txt['cffp_show_in_topic'] = 'Exibir como grupo de campos do t&oacute;pico';
$txt['cffp_show_in_topic_desc'] = 'Se o grupo estive no campo em apenas no primeiro post desde o t&oacute;pico pode ser visto como pertencente ao t&oacute;pico ao inv&eacute;s do post, e exibido em outra &aacute;rea do tema, diferente para postar.';
$txt['cffp_show_in_topic_no'] = 'Nenhum (O grupo visto no campo da primeira mensagem)';
$txt['cffp_show_in_topic_begin_all'] = 'Sim, no come&ccedil;o de todos as p&aacute;ginas do t&oacute;picos';
$txt['cffp_show_in_topic_end_all'] = 'Sim, inserido no fim de todas as p&aacute;ginas do t&oacute;picos';
$txt['cffp_show_in_topic_begin_first'] = 'Sim, no come&ccedil;o da primeira p&aacute;gina do t&oacute;picos';
$txt['cffp_show_in_topic_end_first'] = 'Sim, no final do primeira p&aacute;gina do t&oacute;picos';
$txt['cffp_show_filters'] = 'Filtros';
$txt['cffp_show_filters_desc'] = 'Selecionar o filtro a ser utilizado.';
$txt['cffp_show_filters_boards'] = 'Sub-F&oacute;runs';
$txt['cffp_show_filters_subject_start'] = 'Comece do assunto';
$txt['cffp_show_filters_subject_first_char'] = 'Primeiro caractere do sujeito';
$txt['cffp_show_filters_date_topic'] = 'Dados do t&oacute;picos';
$txt['cffp_show_filters_date_replies'] = 'Dados da &uacute;ltima resposta';
$txt['cffp_show_filters_date_lastdays'] = 'Último %s dias';
$txt['cffp_show_filters_topic_new_posts'] = 'T&oacute;picos com novos post';
$txt['cffp_show_filters_sticky'] = 'Fixos';
$txt['cffp_show_filters_sticky_disabled'] = 'T&oacute;picos fixos desativados. O Filtro n&atilde;o ser&aacute; exibido.';
$txt['cffp_show_filters_locked'] = 'Trancado';
$txt['cffp_show_filters_sticky_locked'] = 'Fixos e trancados';
$txt['cffp_javascript'] = 'C&oacute;digo JavaScript';
$txt['cffp_javascript_desc'] = 'C&oacute;digo executado quando um grupo de campos for criado ou modificado.';
$txt['cffp_search_page'] = 'Procurar t&oacute;picos';
$txt['cffp_search_page_post_desc'] = 'Escrever o nome dos t&oacute;picos e seleccione a ordem dos resultados de cada. Para remover um tema simplesmente esvaziar a caixa de texto para esse tema. Para adicionar um tema j&aacute; existente, selecione-o na lista.';
$txt['cffp_search_page_post_default'] = 'T&oacute;picos predefinidos';
$txt['cffp_search_page_post_more'] = 'Mais';
$txt['cffp_search_page_post_add'] = 'Adicionar um t&oacute;picos existente';
$txt['cffp_search_page_record_desc'] = 'Predefinido: &quot;Pesquisar registros do tipo...&quot;.';
$txt['cffp_search_page_order_by'] = 'Ordenar resultados da pesquisa por';
$txt['cffp_search_page_order_by2'] = 'Ordenar por';
$txt['cffp_search_page_order_by_desc'] = 'Para que um campo seja mostrado aqui, deve ser exibido em uma coluna com apenas esse campo ou seja o primeiro campo na coluna.';
$txt['cffp_counter'] = 'Contador na informa&ccedil;&atilde;o sobre o usu&aacute;rio';
$txt['cffp_counter_desc'] = 'Nome predefinido: Nome do grupo.';
$txt['cffp_counter_show'] = 'Exibir contador';
$txt['cffp_counter_name'] = 'Nome';
$txt['cffp_profile_list'] = 'Lista no perfil de membro';
$txt['cffp_profile_list_desc'] = 'Nome predefinido: Nome do grupo.';
$txt['cffp_profile_list_show'] = 'Exibir lista';
$txt['cffp_profile_list_name'] = 'Nome';
if (!$smf_version_1)
   $txt['cffp_moderation_list'] = 'Lista no Centro de Moderar';
else
   $txt['cffp_moderation_list'] = 'Lista de modera&ccedil;&atilde;o';
$txt['cffp_moderation_list_desc'] = 'Nome predefinido: Nome do grupo. Para que um campo seja mostrado aqui, deve ser exibido em uma coluna com apenas esse campo ou seja o primeiro campo na coluna.';
$txt['cffp_moderation_list_show'] = 'Exibir lista';
$txt['cffp_moderation_list_menu'] = 'Exibir link no menu do F&oacute;rum';
$txt['cffp_moderation_list_name'] = 'Nome';
$txt['cffp_moderation_list_order_by'] = 'Ordenar por';
$txt['cffp_show_message_index'] = 'Exibir no &iacute;ndice de mensagens';
$txt['cffp_show_message_index_desc'] = 'Aplica-se, se for no primeiro post do t&oacute;picos.';
$txt['cffp_show_filter_operator'] = 'Exibir filtro com operador';
$txt['cffp_show_filter_operator_desc'] = 'Se selecionado permite selecionar o operador com o qual aplicar o filtro. Operador padr&atilde;o &eacute; &quot;igual a&quot; ou &quot;semelhante&quot;, de acordo com o tipo de filtro.';
$txt['cffp_show_filter_operator_like'] = 'Incluir';
$txt['cffp_show_filter_operator_not_like'] = 'N&atilde;o Incluir';
$txt['cffp_hide_filter'] = 'Esconder o filtro sob uma tag';
$txt['cffp_hide_filter_desc'] = 'O filtro fica escondido e &eacute; exibido clicando na tag. A mesma tag pode esconder v&aacute;rios filtros.';
$txt['cffp_show_filter_used_options'] = 'Exibir apenas op&ccedil;&otilde;es usadas';
$txt['cffp_show_filter_used_options_desc'] = 'Exibir no filtro apenas os itens que utilizados pela atual diretoria.';
$txt['cffp_show_record_list_type'] = 'Mostrar em listas de registros';
$txt['cffp_show_record_list_type_desc'] = 'Mostra este campo em uma coluna das listas de registros (por exemplo, na busca de registos).';
if (!$smf_version_1)
{
   $txt['cffp_show_moderation_list_type'] = 'Exibir em listas de Centro de Moderar';
   $txt['cffp_show_moderation_list_type_desc'] = 'Exibir este campo em uma coluna das listas de Centro de Moderar.';
}
else
{
   $txt['cffp_show_moderation_list_type'] = 'Exibir em listas de modera&ccedil;&atilde;o';
   $txt['cffp_show_moderation_list_type_desc'] = 'Exibir este campo em uma coluna das listas de modera&ccedil;&atilde;o.';
}
$txt['cffp_show_list_type_no'] = 'Nenhum';
$txt['cffp_show_list_type_one'] = 'Sim, em uma coluna com apenas este campo';
$txt['cffp_show_list_type_multi'] = 'Sim, em uma coluna juntamente com outros campos';
$txt['cffp_show_list_width'] = 'A largura da coluna';
$txt['cffp_show_list_width_desc'] = '0 para automatizado.';
$txt['cffp_show_list_width_unit_auto'] = 'Automatizado';
$txt['cffp_show_list_width_unit_%'] = 'Incostante';
$txt['cffp_show_list_width_unit_px'] = 'Fixo';
$txt['cffp_show_list_column'] = 'Coluna com variados campos';
$txt['cffp_show_list_column_other'] = 'Outro...';
$txt['cffp_show_list_name'] = 'Nome da coluna';
$txt['cffp_show_list_name_desc'] = 'Se n&atilde;o for especificado a coluna conter&aacute; somente neste campo.';
$txt['cffp_not_empty_value'] = 'N&atilde;o tem valor vazio';
$txt['cffp_not_empty_value_desc'] = 'Se selecionado este campo n&atilde;o pode ser deixado em branco.';
$txt['cffp_unique_value'] = 'Valor &uacute;nico';
$txt['cffp_unique_value_desc'] = 'Se selecionado n&atilde;o pode ter dois valores iguais neste campo.';
$txt['cffp_subset'] = 'Subconjunto';
$txt['cffp_subset_desc'] = 'O campo &eacute; exibido dentro de um subconjunto. Os campos de um subconjunto devem ser adjacentes.';
$txt['cffp_permissions'] = 'Permiss&otilde;es';
$txt['cffp_permissions_field_desc'] = 'As a&ccedil;&otilde;es que um membro pode executar ao longo deste campo, sujeitos &agrave;s permiss&otilde;es do f&oacute;rum.';
$txt['cffp_permissions_group_desc'] = 'As a&ccedil;&otilde;es que um membro pode executar ao longo deste grupo, sujeitos &agrave;s permiss&otilde;es do f&oacute;rum.';
$txt['cffp_owner_post'] = 'Dono da mensagem';
$txt['cffp_owner_group'] = 'Dono do grupo';
$txt['cffp_local_moderator'] = 'Moderador local';
$txt['cffp_global_moderator'] = 'Moderador global';
$txt['cffp_administrator'] = 'Administrador';
$txt['cffp_view_message_index'] = 'Veja no &iacute;ndice de mensagens';
$txt['cffp_view_stats'] = 'Exibir estat&iacute;sticas';
$txt['cffp_filter'] ='Filtro';
$txt['cffp_sort'] ='Ordenar';
$txt['cffp_add'] = 'Adicionar';
$txt['cffp_move'] = 'Mover';
$txt['cffp_active'] = 'Ativo';
$txt['cffp_active_field_desc'] = 'Se n&atilde;o for selecionado este campo n&atilde;o ser&aacute; mostrado a ningu&eacute;m.';
$txt['cffp_active_group_desc'] = 'Se n&atilde;o for selecionado este grupo n&atilde;o ser&aacute; mostrado a ningu&eacute;m.';
$txt['cffp_more_info'] = 'Mais informa&ccedil;&otilde;es';
$txt['cffp_id'] = 'ID';
$txt['cffp_make_new_field'] = 'Novo campo';
$txt['cffp_make_new_group'] = 'Novo grupo';
$txt['cffp_add_field_title'] = 'Adicionar campo';
$txt['cffp_add_group_title'] = 'Adicionar grupo de campos';
$txt['cffp_edit_field_title'] = 'Editar campo';
$txt['cffp_edit_group_title'] = 'Editar grupo de campos';
$txt['cffp_edit_delete_field_sure'] = 'Tem certeza de que deseja apagar este campo? Todos os dados da mensagens relacionados ser&atilde;o perdidos!';
$txt['cffp_edit_delete_group_sure'] = 'Tem certeza de que deseja excluir este grupo? Todos os dados da mensagens relacionados ser&atilde;o perdidos!';
$txt['cffp_template'] = 'Template para mensagens';
$txt['cffp_template_message_index'] = 'Template para &iacute;ndice de mensagens';
$txt['cffp_template_quick_input'] = 'Template para entrada r&aacute;pida';
$txt['cffp_template_quick_input_regex'] = 'Express&atilde;o regular';
$txt['cffp_template_quick_input_regex_desc'] = 'Compat&iacute;vel com JavaScript. Usado em <tt>String.match(regex)</tt> m&eacute;todo e deve ser obtida uma matriz de valores de campo come&ccedil;ando com a tecla 1.';
$txt['cffp_template_quick_input_params'] = 'Par&acirc;metros';
$txt['cffp_template_quick_input_params_desc'] = 'Para cada elemento da matriz obtida a partir da express&atilde;o regular acrescenta uma linha com o campo ID, ou 0 se ele n&atilde;o corresponder a qualquer campo. Para a formata&ccedil;&atilde;o de um valor antes de copi&aacute;-lo em seu campo, abaixo do campo de ID para adicionar outra linha com o c&oacute;digo JavaScript. <tt>value</tt> vari&aacute;vel cont&eacute;m o valor original e deve conter o valor transformado. Com <tt>field_obj[</tt>ID_campo<tt>]</tt> pode acessar um campo de formul&aacute;rio.';
$txt['cffp_template_quick_input_help'] = 'Ajuda';
$txt['cffp_template_quick_input_help_desc'] = 'Texto que o utilizador ver&aacute; em vez da express&atilde;o regular. Permitir BBC.';
$txt['cffp_template_quick_input_show_modify'] = 'Exibir quando os dados s&atilde;o modificados';
$txt['cffp_template_quick_input_show_modify_desc'] = 'Se n&atilde;o for selecionado s&oacute; ser&aacute; exibido quando os dados s&atilde;o criados.';
$txt['cffp_template_type_html'] = 'HTML';
$txt['cffp_template_type_bbc'] = 'BBC';
$txt['cffp_template_type_php'] = 'PHP';
$txt['cffp_add_templates'] = 'Adicionar templates';
$txt['cffp_edit_templates'] = 'Editar templates';
$txt['cffp_warning_cannot_see_group_fields'] = 'Voc&ecirc; n&atilde;o pode ver os campos deste grupo.';
$txt['cffp_warning_group_subject'] = 'Esses campos ser&atilde;o removidos se o post sujeito come&ccedil;a com: %s.';
$txt['cffp_quick_input_field'] = 'Campo de entrada r&aacute;pida';
$txt['cffp_quick_input_field_desc'] = 'Escrever valores para entrar em campos diferentes de acordo com esta express&atilde;o regular:';
$txt['cffp_quick_input_match'] = 'Os campos s&atilde;o preenchidos.';
$txt['cffp_quick_input_no_match'] = 'Conteúdo do &quot;campo de entrada r&aacute;pida&quot; n&atilde;o est&aacute; formatado corretamente. Campos n&atilde;o pode ser preenchido.';
$txt['cffp_quick_input_apply'] = 'Preencha os campos';
$txt['cffp_created'] = 'Criado';
$txt['cffp_edit_group'] = 'Editar %s';
$txt['cffp_show'] = 'Exibir';
$txt['cffp_show_previous'] = 'Mostrar anterior';
$txt['cffp_move_to_first_post'] = 'Mover-se para o primeiro mensagem neste t&oacute;picos';
$txt['cffp_move_to_other_post'] = 'Mover-se para um outro mensagem';
$txt['cffp_move_to_other_topic'] = 'Mover-se para um outro t&oacute;picos';
$txt['cffp_move_group_to_other_post'] = 'Mover-se %s para outro mensagem';
$txt['cffp_move_group_to_other_topic'] = 'Mover-se %s para outro t&oacute;picos';
$txt['cffp_move_to_post'] = 'Mover-se para o mensagem';
$txt['cffp_move_to_post_desc'] = 'Mensagem ID. Exemplo: index.php?topic=4043.msg23892, use 23892.';
$txt['cffp_move_to_topic'] = 'Mover-se para o t&oacute;picos';
$txt['cffp_move_to_topic_desc'] = 'T&oacute;picos ID. Exemplo: index.php?topic=4043.0, use 4043.';
$txt['cffp_search_posts_records'] = 'Pesquisa de post e registros';
$txt['cffp_search_posts'] = 'Procurar mensagens';
$txt['cffp_search_posts_desc'] = 'Escreva o texto e/ou selecione as op&ccedil;&ccedil;&otilde;s nos campos em que deseja pesquisar. Você vai ter uma lista de mensagens que contenham esses valores em seus campos.';
$txt['cffp_search_records_type'] = 'Pesquisar registros do tipo %s';
$txt['cffp_search_records_desc'] = 'Escreva o texto e/ou selecione as op&ccedil;&ccedil;&otilde;s nos campos em que deseja pesquisar. Você vai ter uma lista de registros que contêm esses valores em seus campos.';
$txt['cffp_show_fields'] = 'Mostrar campos';
$txt['cffp_hide_fields'] = 'Ocultar campos';
$txt['cffp_record_type'] = 'Registros do tipo %s';
$txt['cffp_records'] = 'Registros';
if (!$smf_version_1)
   $txt['cffp_moderation_area'] = 'Grupos de campos em mensagens';
else
   $txt['cffp_moderation_area'] = 'Moderado grupos de campos em mensagens';
$txt['cffp_moderation_area_desc'] = 'Aqui voc&ecirc; pode rever todos os dados postados por membros em grupos de campos personalizados.';
$txt['cffp_moderation_area_delete_sure'] = 'Tem certeza de que deseja apagar estes dados?';
$txt['cffp_moderation_area_none'] = 'N&atilde;o existem dados publicados';
$txt['cffp_poster_time'] = 'Dados postados';
$txt['cffp_topic_without_replies'] = 'T&oacute;picos sem respostas';
$txt['cffp_symbol'] = 'S&iacute;mbolo';
$txt['cffp_number'] = 'N&uacute;mero';
$txt['cffp_alphabet_letters'] = 'A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z'; // Portuguese alphabet (capital letters comma separated)
$txt['cffp_field_empty_value'] = 'Nenhum dados';
$txt['cffp_field_non_empty_value'] = 'H&aacute; dados';
$txt['cffp_filtertype_empty_non_empty'] = $txt['cffp_field_empty_value'] . ' / ' . $txt['cffp_field_non_empty_value'];
$txt['cffp_order_by_asc'] = 'Ordem ascendente';
$txt['cffp_order_by_desc'] = 'Ordem decrescente';
$txt['cffp_wireless_end_group'] = 'Fim %s';
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post
Post by: Sakae on June 10, 2015, 10:35:28 AM
This is for ISO-I-can't-remember-the-number:

./Themes/default/languages/Errors.portuguese_brazilian.php
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
$txt['error_cffp_field_need_name'] = 'O campo deve ter um nome!';
$txt['error_cffp_group_need_name'] = 'O grupo de campos deve ter um nome!';
$txt['error_cffp_field_need_options'] = 'O campo deve ter opções!';
$txt['error_cffp_search_page_in_use'] = 'A página de pesquisa já está em uso!';
$txt['error_cffp_search_page_in_use_record'] = 'A página de pesquisa já está em uso por um registro!';
$txt['error_cffp_group_no_name'] = 'Nenhum nome foi fornecido em grupo &quot;%s&quot;.';
$txt['error_cffp_group_long_name'] = 'O nome que você tentou usar em grupo &quot;%s&quot; era muito longo.';
$txt['error_cffp_group_bad_name'] = 'O nome que você apresentou, em grupo &quot;%s&quot; não pode ser utilizado, uma vez que é ou contém um nome reservado.';
$txt['error_cffp_group_no_email'] = 'Nenhum endereço de e-mail fornecido no grupo &quot;%s&quot;.';
$txt['error_cffp_group_bad_email'] = 'Um endereço de e-mail inválido foi dada em grupo &quot;%s&quot;.';
$txt['error_cffp_group_invalid_email'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; deve ser um endereço de email válido.';
$txt['error_cffp_group_not_number'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; deve ser numérico.';
$txt['error_cffp_group_inproper_format'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; é um formato inválido.';
$txt['error_cffp_group_empty'] = 'O campo &quot;%s&quot; no grupo &quot;%s&quot; não pode ser deixado em branco.';
$txt['error_cffp_group_value_not_unique'] = 'O valor do campo &quot;%s&quot; no grupo &quot;%s&quot; já existe.';
$txt['error_cffp_params'] = 'Parâmetros incorretos';
$txt['error_cffp_move_missing_post'] = 'A mensagem alvo é inexistente.';
$txt['error_cffp_move_missing_topic'] = 'O tópico alvo é inexistente.';
$txt['error_cffp_move_board_post_not_allowed'] = 'Os dados não podem estar na categoria de mensagem de destino.';
$txt['error_cffp_move_board_topic_not_allowed'] = 'Os dados não podem estar na categoria de tópico de destino.';
$txt['error_cffp_move_post_not_allowed'] = 'Os dados não podem ser na mensagem alvo.';
$txt['error_cffp_move_topic_not_allowed'] = 'Os dados não podem ser no tópico alvo.';
$txt['error_cffp_move_already_has_data'] = 'A mensagem de destino já tem este tipo de dados.';
$txt['error_cffp_move_post_already_has_data'] = 'O membro já tem este tipo de dados na mensagem de destino.';
$txt['error_cffp_move_topic_already_has_data'] = 'O membro já tem este tipo de dados no tópico alvo.';
$txt['error_cffp_search_not_allowed'] = 'Não definiu campos pesquisáveis ou você não tem permissão para pesquisar.';
// END MOD CustomFieldFilterPost

./Themes/default/languages/Help.portuguese_brazilian.php
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
global $forum_version;
$smf_version_1 = 0 === strpos($forum_version, 'SMF 1');
$helptxt['cffp'] = '<b>Campos personalizados e filtros de mensagens</b><br />
Permite adicionar diferentes grupos de campos personalizados para posts no fórum e filtros para os campos de mensagens.<br />
Um grupo de campos podem ser do tipo:<br />
<ul class="normallist">
<li>Campos soltos: Seus campos são adicionados a um post para fornecer informações extra. Na busca de dados em campos soltos de um post é obtém uma lista de posts.</li>
<li>Registro: é um conjunto de campos que representa uma entidade independente do post. Na busca de dados em campos de um registro é obtém-se uma lista de registros. O corpo do post não pode ser deixado em branco, mas um post com registro não precisa de corpo. Se o usuário irá adicionar um registro e o corpo do post estiver vazio, o sistema grava um período(&quot;.&quot;) sobre ele e o usuário não precisa escrever nada.</li>
<li>Os campos com vários valores por membro: é um conjunto de campos onde vários usuários podem inserir valores diferentes. Isso pode ser usado para os membros para fazer comentários ou avaliações sobre o post. Se esses campos estão localizados em apenas na primeira mensagem de um tópico pode ser apresentado como pertencente ao tópico.</li>
<li>Filtros: Este é um tipo especial de grupo sem campos. Usado para habilitar um conjunto de filtros pré-definidos que podem ser usados em tópicos e mensagens.</li>
</ul>
Os filtros predefinidos disponíveis são:<br />
<ul class="normallist">
<li>Sub-Fórum.</li>
<li>Assunto.</li>
<li>Começo do assunto.</li>
<li>Primeiro caractere do assunto.</li>
<li>Dados do tópico / Dado publicado.</li>
<li>Dados da última resposta / Dado publicado.</li>
<li>Postado por.</li>
<li>Tópico com novos posts / Novo.</li>
<li>Fixos.</li>
<li>Trancado.</li>
<li>Respostas.</li>
<li>Enquete.</li>
</ul>
As ações a serem realizadas em um grupo de campos personalizados sâo: visâo, adicionar, modificar, apagar e mover.<br />
Além disso são possíveis outras ações usando campos personalizados:<br />
<ul class="normallist">
<li>Filtrar o índice de mensagens.</li>
<li>Organizar o índice de mensagens.</li>
<li>Mostrar estatísticas.</li>
<li>Pesquisar nas áreas de mensagens, obter uma lista de posts.</li>
<li>Pesquisar nas áreas de registros, obtendo uma lista de registros.</li>
</ul>
<br />
<b>Painel de administração</b><br />
O painel de administração tem a lista dos grupos de campos personalizados, o que permite adicionar novos grupos, modificar ou excluir grupos existentes, adicionar, modificar ou excluir campos de um grupo e definir modelos para exibir esses campos em um post e no índice de mensagens.<br />
<br />
<b>Visualizando posts com campos personalizados</b><br />
Ao visualizar um post completo (em um tópico, em posts ou perfil recentes) são apresentados seus grupos (que são ativados quando o post é criado ou modificado). Grupo do tipo &quot;solto campos&quot; e &quot;registros&quot; são mostrados acima do corpo do post, Considerando que os grupos de tipo &quot;campos com vários valores por membro&quot; são apresentados a seguir, a menos o que foi selecionado &quot;Mostrar como grupo de campos do tópico&quot; e, em seguida, é apresentado no início e/ou e do tópico. Se um grupo tem o template por mensagens os campos são exibidos de acordo com o template, se não são exibidos com o seu nome e conteúdo.<br />
Em listas de posts (índice de mensagens, mensagem não lida e respostas) são grupos exibida com campos visíveis no índice de mensagens (de acordo com as permissões). Se um grupo tem o template para o índice de mensagens os campos são exibidos de acordo com o template, se não são exibidos com o seu nome e conteúdo.<br />
<br />
<b>Modificando valores em campos personalizados</b><br />
Em um tópico, posts com grupos de tipo &quot;campos com vários valores por membro&quot; têm botôes para o usuário postar novos valores, e modificar ou remover os existentes.<br />
Para todos os outros grupos (&quot;campos solto&quot; e &quot;registro&quot;), a criar ou modificar o post são exibidos grupos permitidos. Os grupos de tipo &quot;solto campos&quot; sempre têm seus campos visíveis, enquanto que os grupos de tipo &quot;registro&quot; tem uma caixa de seleção para mostrar ou ocultar os seus campos. Se tem sido modelo criado para a entrada rápida em um registro, <strong>Campo de entrada rápida</strong> é exibido após os campos de registro.<br />
<br />
<b>Movendo um grupo de campos personalizados para outro post</b><br />
Um grupo de campos pode ter de ser atribuído a um outro post, por exemplo, antes de remover o post onde é o grupo.<br />
Se o utilizador tem permissão para mover um grupo, ao visualizar um tema que grupo terá botões para ir para o primeiro post do tópico ou outro post (ou outro tópico se o grupo é do tipo &quot;campos com vários valores por membro&quot; e selecionou &quot; Mostrar como grupo de campos do tópico&quot;).<br />
<br />
<b>Filtrar o índice de mensagens</b><br />
Se o utilizador tem permissão para filtrar por um campo, um botão é exibido no índice de mensagens para filtrar tópicos por esse campo.<br />
Tipo de botão de filtro depende do tipo de campo:<br />
<ul class="normallist">
<li>O filtro para o texto ou campos de texto grandes é um botão de texto em que entrar na cadeia de pesquisa, ou uma caixa de seleção para obter dados com esse campo vazio ou não vazio.</li>
<li>Campos tipo caixa de seleção, caixa de combinação, botões de rádio ou caixas de ter pelo filtro de um botão de texto, uma caixa de seleção ou uma caixa de combinação em que digitar ou selecionar o texto a procurar, ou uma caixa de seleção para obter dados com esse campo vazio ou não vazio.</li>
<li>Para campos do tipo booleano o filtro é uma caixa de seleção com os valores &quot;Sim&quot; e &quot;Nenhum&quot;.</li>
</ul>
Se o usuário pode modificar um campo, que o campo pode estar vazio e seu filtro é uma caixa de seleção ou caixa de combinação, ele verá uma opção na lista para obter dados com esse campo vazio.<br />
Além disso, com um grupo de tipo &quot;filtros&quot; podem ser adicionados filtros predefinidos.<br />
O filtro com o botão texto permite pesquisar palavras soltas (separados por espaços) e/ou fases literais (entre aspas duplas).<br />
Se o filtro é do tipo de texto ou caixa de combinação, por padrão, ele é procurado que o texto está contido no valor do campo, enquanto que se o filtro é o tipo de lista de seleção de caixa é pedido que o texto corresponde ao valor do campo.<br />
Os filtros podem ser do mesmo grupo ou grupos diferentes de campos.<br />
Ao lado de filtros há um botão para ativar os filtros que foram dadas algum valor. Como resultado obtém-se o índice de mensagens com tópicos cujo cargo primeira corresponde a todos os filtros ativos.<br />
<br />
<b>Ordenar o índice de mensagens</b><br />
Se o usuário tem permissão para classificar por um ou mais campos, uma caixa de seleção é exibido no índice de mensagens para classificar tópicos por um desses campos.<br />
<br />
<b>Mostrar estatísticas</b><br />
Se um grupo de tipo &quot;campos com vários valores por membro&quot; tem um único campo e é de tyoe caixa de seleção, botões de rádio ou caixas (isto é, existe um número finito de valores), pode ser gerar dados estatísticos a partir dos valores inseridos no campo.<br />
Os dados estatísticos a serem exibidos incluem:<br />
<ul class="normallist">
<li>Gráfico com média: é constituída por uma barra horizontal onde o valor médio, o valor mais baixo permitido e o maior valor permitido estão localizados.</li>
<li>Gráfico com barras horizontais: Representa a utilização de cada valor permitido através de barras horizontais.</li>
<li>Gráfico com barras verticais: Representa a utilização de cada valor permitido por meio de barra vertical.</li>
<li>Resumo: Um conjunto de dados obtidos a partir dos valores de entrada (média, o valor mais alto e mais baixo permitido, maior eo menor valor usado, valor mais e menos frequente).</li>
</ul>
O usuário vê estes dados apenas se tiver permissão. O índice de mensagens pode ser ordenado por os dados de resumo, se ele tem permissão para classificar pelo campo.<br />
Usando templates podem ser inseridos os dados estatísticos de qualquer grupo de campos em outro lugar.<br />
<br />
<b>Pesquisa em campos</b><br />
' . (!$smf_version_1 ? 'Sob a opção &quot;Pesquisa&quot; a partir do fórum menu páginas de pesquisa estão localizados' : 'A opção &quot;Mensagens de pesquisa e registros&quot; a partir do menu fórum fornece acesso &agrave;s páginas de pesquisa') . ', mostrando os grupos e seus campos no qual o usuário tem permissão de busca.<br />
Grupos de tipo &quot;solto campos&quot;, &quot;campos com vários valores por membro&quot; e &quot;filtros&quot; pode estar em várias páginas de busca, e cada página contém vários grupos, com a única condição de que os grupos em uma página deve ser permitida em um conjunto comum de mensagens. Como resultado de pesquisa uma lista de postos é obtido.<br />
Para cada grupo de tipo &quot;registro&quot; com a permissão de busca tem uma página. Como resultado, uma lista de registos é obtido com as colunas indicadas na definição dos campos.<br />
Em ambos os casos, os botões usados em cada campo de busca seguir a mesma regra que nos filtros.<br />
<br />
<b>Contador na informação sobre o usuário</b><br />
O número de cada tipo de registro criado pelo membro pode ser exibido nas informações desse membro.<br />
Isto pode ser visto em diversas áreas, tais como o perfil do usuário e informação do membro sobre a postagem de cada mensagem.<br />
&quot;Centro de Administração &gt; Manutenção do Fórum &gt; ' . (!$smf_version_1 ? 'Rotina' : 'Manutenção Geral') . ' &gt; Recontar todos os totais e estatísticas do fórum&quot; também relata o número de cada tipo de registro criado por membros.<br />' . (!$smf_version_1 ? '
<br />
<b>Lista no perfil de membro</b><br />
No perfil de membro, na seção &quot;Informações do perfil &gt; Exibi Posts&quot;, pode ser mostrar uma lista para cada grupo de tipo &quot;registro&quot;, com mensagens postadas pelo próprio usuário contendo este tipo de grupo.<br />
<br />
<b>Lista em Centro de Moderar</b><br />
No Centro de moderação é possível controlar o conteúdo postado pelos usuários nos grupos do tipo &quot;campos com vários valores por membro&quot;.<br />
Para cada grupo que escolheu para mostrar esta lista será exibido um acesso &agrave; lista na seção &quot;Posts &gt; Grupo de campos no posts&quot; e, opcionalmente, um link abaixo da opção &quot;Moderado&quot; a partir do menu de fórum.' : '
<br />
<b>Lista de moderação</b><br />
Moderadores globais podem controlar o conteúdo postado pelos usuários nos grupos do tipo &quot;campos com vários valores por membro&quot;.<br />
A opção &quot;Moderar os grupos de campos em mensagens&quot; a partir do menu fórum fornece acesso &agrave; lista com dados lançados, um para cada grupo, que escolheu para mostrar esta lista.');
$helptxt['cffp_enclose'] = 'Envolve a entrada do usuário entre algum texto (criado com HTML, BBC or PHP). Isso permitirá que você adicione mais provedores de mensagens instantâneas, imagens ou uma incorporação etc. Por exemplo:<br />
<br />
&lt;a href="http://website.com/{INPUT}"&gt;&lt;img src="{DEFAULT_IMAGES_URL}/icon.gif" alt="{INPUT}" /&gt;&lt;/a&gt;<br />
<br />
Pode utilizar as seguintes variáveis<br />
<ul class="normallist">
<li><tt>{INPUT}</tt> - A entrada especificada pelo utilizador.</li>
<li><tt>{TEXT_PREVIOUS}</tt> - HTML para colocar antes do texto de saída.</li>
<li><tt>{TEXT_NEXT}</tt> - HTML para colocar a seguir o texto de saída.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_DATABASE}</tt> - O nome do campo no banco de dados do campo ID <i>n</i>. O campo pode ser de qualquer grupo.</li>
<li><tt>{ID_MSG}</tt> - ID da mensagem atual.</li>
<li><tt>{BOARDURL}</tt> - URL a pasta fórum.</li>
<li><tt>{SCRIPTURL}</tt> - Endereço da Web do fórum.</li>
<li><tt>{IMAGES_URL}</tt> - URL a pasta de imagens no usuários tema atual.</li>
<li><tt>{DEFAULT_IMAGES_URL}</tt> - URL para a pasta de imagens no tema padrão.</li>
</ul>
No PHP, você também pode usar as seguintes funções:<br />
<ul class="normallist">
<li><tt>{SHOW_GROUP_MSG}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>)</tt> - Exibe o grupo de uma mensagem como em uma mensagem.</li>
<li><tt>{SHOW_GROUP_MSGINDEX}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>)</tt> - Exibe o grupo de uma mensagem como no índice de mensagens.</li>
<li><tt>{SHOW_GROUP_MSG_STATS}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>, &apos;</tt><i>tipo</i><tt>&apos;, &apos;</tt><i>params</i><tt>&apos;)</tt> - Exibe as estatísticas para o grupo de uma mensagem (se são ativados). O parâmetro <i>tipo</i> pode ser:
<ul class="normallist">
<li><tt>chart_average</tt> - Exibe o gráfico com a média. O parâmetro <i>params</i> indica as características do gráfico. Os valores permitidos: <tt>average</tt> (valor médio mostrado), <tt>minmax</tt> (valor mais baixo e mais alto permitido mostrado), <tt>options_text</tt> (mostrado o texto de opções).</li>
<li><tt>chart_hbars</tt> - Apresenta o gráfico com barras horizontais. O parâmetro <i>params</i> não é utilizada.</li>
<li><tt>chart_vbars</tt> - Exibe o gráfico com barras verticais. O parâmetro <i>params</i> indica as características do gráfico. Os valores permitidos: <tt>options_text</tt> (mostrado o texto de opções).</li>
<li><tt>summary</tt> - Exibe o resumo. O parâmetro <i>params</i> indica valores para mostrar, separados por vírgulas. Os valores permitidos: <tt>average</tt> (valor médio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
<li><tt>value</tt> - Exibe um valor de resumo. O parâmetro <i>params</i> indica o valor a ser exibido. Os valores permitidos: <tt>average</tt> (valor médio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
</ul></li>
</ul>';
$helptxt['cffp_mask'] = 'A máscara de introdução é importante para a segurança do seu fórum. Validar a introdução do utilizador ajuda a assegurar que os dados não são utilizados de outra forma que não a esperada. Algumas expressões regulares simples são fornecidas a título de exemplo.<br /><br />
<div class="smalltext" style="margin: 0 2em">
&quot;[A-Za-z]+&quot; - Corresponder todas as maiúsculas e minúsculas do alfabeto.<br />
&quot;[0-9]+&quot; - Corresponder todos os caracteres numéricos.<br />
&quot;[A-Za-z0-9]{7}&quot; - Corresponder todas as maiúsculas e minúsculas do alfabeto e caracteres numéricos sete vezes.<br />
&quot;[^0-9]?&quot; - Proibir a correspondência de qualquer número.<br />
&quot;^([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6})$&quot; - Permitir apenas 3 ou 6 caracteres hexadecimais.<br />
</span><br /><br />
Adicionalmente, podem ser definidos os meta-caracteres especiais ?+*^$ e {xx} .
<div class="smalltext" style="margin: 0 2em">
? - Nenhuma ou uma correspondência da expressão anterior.<br />
+ - Uma ou mais correspondências da expressão anterior.<br />
* - Nenhuma ou mais da expressão anterior.<br />
{xx} - Um número exacto da expressão anterior.<br />
{xx,} - Um número exacto ou mais da expressão anterior.<br />
{,xx} - Um número exacto ou menos da expressão anterior.<br />
{xx,yy} - Um número de correspondências dentro da gama dos argumentos xx e yy, da expressão anterior.<br />
$ - Início de string.<br />
^ - Fim de string.<br />
\\ - Escape do próximo caracter.<br />
</div><br /><br />
Mais informações e técnicas avançadas podem ser encontradas na internet.';
$helptxt['cffp_fieldtype'] = 'Tipos de campos que podem ser criados são:<br />
<ul class="normallist">
<li>Texto: O campo no qual pode digitar o texto de uma linha.</li>
<li>Grande texto: O campo que permite que tipo multi-linha de texto.</li>
<li>Caixa de escolha: O campo que exibe um menu de opções para selecionar. O campo pode ser única seleção (permite selecionar apenas uma opção) ou múltiplo (permite selecionar várias opções de uma só vez).</li>
<li>Caixa de combinação: Combinação de caixa de seleção (seleção única ou múltipla) e caixa de texto, permitindo digitar um valor (ou valores separados por vírgulas) ou escolher a partir de uma lista de opções.</li>
<li>Acionamento tipo Radio: Conjunto de opções a partir do qual só pode escolher um.</li>
<li>Caixas de seleção: Conjunto de opções a partir do qual você pode escolher vários de uma vez.</li>
<li>Booleano: Apenas uma opção que pode ser seleccionado (valor &quot;verdadeiro&quot;) ou não (valor &quot;falso&quot;).</li>
</ul>';
$helptxt['cffp_grouptype'] = 'Um grupo de campos podem ser do tipo:<br />
<ul class="normallist">
<li>Campos soltos: Seus campos são adicionados a um post para fornecer informações extra. Na busca de dados em campos soltos de um post obtendo uma lista de posts.</li>
<li>Registro: é um conjunto de campos que representa uma entidade independente do post. Na busca de dados em campos de um registro é obtém uma lista de registros. O corpo do post não pode ser deixado em branco, mas um post com registro não precisa de corpo. Se o usuário irá adicionar um registro e o corpo do post estiver vazio, o sistema grava um período (&quot;.&quot;) sobre ele e o usuário não precisa escrever nada.</li>
<li>Os campos com vários valores por membro: Ele é definido de campos onde vários usuários podem inserir valores diferentes. Isso pode ser usado para os membros para fazer comentários ou avaliações sobre o post.</li>
<li>Filtros: Este é um tipo especial de grupo sem campos. Usado para habilitar um conjunto de filtros pré-definidos que podem ser usados em tópicos e mensagens.</li>
</ul>';
$helptxt['cffp_type_filter'] = 'Tipo de botão de filtro depende do tipo de campo:<br />
<ul class="normallist">
<li>O filtro para o texto ou campos de texto grandes é um botão de texto para entrar na cadeia de pesquisa, ou uma caixa de seleção para obter dados com esse campo vazio ou não vazio.</li>
<li>Campos tipo caixa de seleção, caixa de combinação, botões de rádio ou caixas de ter pelo filtro de um botão de texto, uma caixa de seleção ou uma caixa de combinação em que digitar ou selecionar o texto a procurar, ou uma caixa de seleção para obter dados com esse campo vazio ou não vazio.</li>
<li>Para campos do tipo booleano o filtro é uma caixa de seleç ão com os valores &quot;Sim&quot; e &quot;Não&quot;.</li>
</ul>
Se o usuário pode modificar um campo, que o campo pode estar vazio e seu filtro é uma caixa de seleção ou caixa de combinação, ele verá uma opção na lista para obter dados com esse campo vazio.<br />
O filtro com o botão texto permite pesquisar palavras soltas (separados por um espaço) e/ou fases literais (entre aspas duplas).<br />
Se o filtro é do tipo de texto ou caixa de combinação, por padrão, ele é procurado que o texto está contido no valor do campo, enquanto que se o filtro é o tipo de lista de seleção de caixa é pedido que o texto corresponde ao valor do campo.';
$helptxt['cffp_options'] = 'Esta seção define as opções que o usuário pode escolher a partir de uma caixa de seleção, caixa de combinação, botões de rádio ou caixas de seleção. Existem alguns pontos-chave a serem observados nesta seção:<br />
<ul class="normallist">
<li>As opções padrão: Qualquer que seja a caixa de opopçõeses tem a &quot;botão de rádio&quot; (pode haver apenas um) ou &quot;Caixas de seleção&quot; (pode ser várias) ao lado desse selecionado será as seleções padrão para o utilizador quando entram dados.</li>
<li>Remoção de opcionais: Para remover uma opção simplesmente vazia na caixa de texto para essa opção - todas as mensagens com o seleccionado terá sua opção desmarcada.</li>
<li>Reordenar opções: Você pode reordenar as opções movendo texto em torno entre as caixas. Contudo - uma nota importante - você deve se certificar do que você faz <strong>não</strong> mudar o texto quando reordenação opções em contrário dados postados serão perdidos.</li>
<li>Texto (disponível se o botão não é uma caixa de combinação): Uma opção pode ser exibido com valor real ou com um texto mais significativo para o usuário.</li>
<li>Adicione várias opções: Permite adicionar várias opções de uma só vez, escrevendo cada opção em uma linha do campo de texto grande. Cada opção tem valor e, se o botão não ê uma caixa de combinação, texto, separados por vírgulas. Texto ê opcional.</li>
</ul>';
$helptxt['cffp_javascript'] = 'Código JavaScript executado quando um grupo de campos é criado ou modificado.<br />
Permite a execução de código quando um evento ocorre ao longo de um botão de formulário ou outro elemento HTML.<br />
Isto pode ser escrito como:<br />
<br />
<tt>document.getElementsByName(</tt><i>html_nome_elemento</i><tt>)[0].</tt><i>nome_evento</i><tt> = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;// ...<br />
}<br />
document.getElementById(</tt><i>html_id_elemento</i><tt>).</tt><i>nome_evento</i><tt> = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;// ...<br />
}</tt><br />
<br />
Por exemplo, este código mostra uma mensagem quando o usuário clica no botão <tt>id1</tt> e copiar o valor do botão <tt>id2</tt> sobre o assunto quando o usuário alterar esse valor:<br />
<br />
<tt>document.getElementById(&quot;id1&quot;).onclick = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;alert(&quot;Uma mensagem&quot;);<br />
}<br />
document.getElementById(&quot;id2&quot;).onchange = function (event)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;document.getElementsByName(&quot;subject&quot;)[0].value = this.value;<br />
}</tt>';
$helptxt['cffp_stats'] = 'Se um grupo de tipo &quot;campos com vários valores por membro&quot; tem um único campo e é do tipo caixa de seleção, botões de rádio ou caixas (isto é, existe um número finito de valores), pode gerar dados estatísticos a partir dos valores inseridos no campo.<br />
Os dados estatísticos a serem exibidos incluem:<br />
<ul class="normallist">
<li>Gráfico com média: é constituída por uma barra horizontal, onde o valor médio, o valor mais baixo permitido e o valor mais elevado permitido estão localizados.</li>
<li>Gráfico com barras horizontais: Representa o uso de cada valor permitido por barras horizontais.</li>
<li>Gráfico com barras verticais: Representa o uso de cada valor permitido por barra vertical.</li>
<li>Resumo: Um conjunto de dados obtidos a partir dos valores de entrada (média, o valor mais alto e mais baixo permitido, maior e o menor valor usado, valor mais e menos frequente).</li>
</ul>
O usuário vê estes dados apenas se tiver permissão. O índice de mensagens pode ser ordenado por os dados de resumo, se ele tem permissão para classificar pelo campo.<br />
Usando templates que podem ser inseridos os dados estatísticos de qualquer grupo de campos em outro lugar.';
$helptxt['cffp_search_page'] = (!$smf_version_1 ? 'Sob a opção &quot;Pesquisa&quot; a partir do menu fórum, páginas de pesquisa são localizados' : 'A opção &quot;Pesquisa de posts e registros&quot; a partir do menu fórum fornece acesso &agrave;s páginas de pesquisa') . ', mostrando os grupos e seus campos no qual o usuário tem permissão de busca.<br />
Grupos de tipo &quot;campos soltos&quot;, &quot;campos com cada valor por membro&quot; e &quot;filtro&quot; pode ser em cada página de pesquisa, e cada página contém vários grupo, com a única condição de que os grupos em uma página deve ser permitida em um conjunto comum de mensagens. Como resultado de pesquisa uma lista de postos é obtido.<br />
Para cada grupo de tipo &quot;registro&quot; com a permissão de busca tem uma página. Como resultado, uma lista de registos é obtido com as colunas indicadas na definição dos campos.';
$helptxt['cffp_counter'] = 'O número de cada tipo de registro criado pelo membro pode ser exibido nas informações desse membro.<br />
Isto pode ser visto em diversas áreas, tais como o perfil do usuário e informação do membro sobre a postagem de cada mensagem.<br />
&quot;Centro de Administração &gt; Manutenção do Fórum &gt; ' . (!$smf_version_1 ? 'Rotina' : 'Manutenção Geral') . ' &gt; Recontar todos os totais e estatísticas do fórum&quot; também relata o número de cada tipo de registro criado por membros.';
$helptxt['cffp_profile_list'] = 'No perfil de membro, na seção &quot;Informações do Perfil &gt; Ver Posts&quot;, pode mostrar uma lista para cada grupo de tipo &quot;registro&quot;, com mensagens postadas pelo próprio usuário contendo este tipo de grupo.';
if (!$smf_version_1)
{
$helptxt['cffp_moderation_list'] = 'No Comando do moderador é possível controlar o conteúdo postado pelos usuários nos grupos do tipo &quot;campos com vários valores por membro&quot;.<br />
Para cada grupo que escolheu para mostrar esta lista será exibido um acesso &agrave; lista na seção &quot;Posts &gt; Grupos de campos em posts&quot; e, opcionalmente, um link abaixo da opção &quot;Moderado&quot; a partir do menu de fórum.';
}
else
{
$helptxt['cffp_moderation_list'] = 'Moderadores globais podem controlar o conteúdo postado pelos usuários nos grupos do tipo &quot;campos com vários valores por membro&quot;.<br />
A opção &quot;Moderar os grupos de campos nas mensagens&quot; a partir do menu fórum fornece acesso &agrave; lista com dados lançados, um para cada grupo, que escolheu para mostrar esta lista.';
}
$helptxt['cffp_template_text'] = 'Texto usado para exibir o conteúdo de campos em grupo.<br />
Você pode usar as seguintes variáveis:<br />
<ul class="normallist">
<li><tt>{FIELD_</tt><i>n</i><tt>_NAME}</tt> - Nome de campo ID <i>n</i>.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_VALUE}</tt> - Valor de campo ID <i>n</i>.</li>
<li><tt>{FIELD_</tt><i>n</i><tt>_DATABASE}</tt> - O nome do campo no banco de dados do campo ID <i>n</i>. O campo pode ser de qualquer grupo.</li>
<li><tt>{ID_MSG}</tt> - ID da mensagem atual.</li>
<li><tt>{BOARDURL}</tt> - URL para pasta fórum.</li>
<li><tt>{SCRIPTURL}</tt> - Endereço Web do fórum.</li>
<li><tt>{IMAGES_URL}</tt> - URL para pasta de imagens no usuários tema atual.</li>
<li><tt>{DEFAULT_IMAGES_URL}</tt> - URL para pasta de imagens no tema padrão.</li>
</ul>
No PHP, você também pode usar as seguintes funções:<br />
<ul class="normallist">
<li><tt>{SHOW_GROUP_MSG}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>)</tt> - Exibe o grupo de uma mensagem como em uma mensagem.</li>
<li><tt>{SHOW_GROUP_MSGINDEX}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>)</tt> - Exibe o grupo de uma mensagem como no índice de mensagens.</li>
<li><tt>{SHOW_GROUP_MSG_STATS}(</tt><i>ID_mensagem</i><tt>, </tt><i>ID_grupo</i><tt>, &apos;</tt><i>tipo</i><tt>&apos;, &apos;</tt><i>params</i><tt>&apos;)</tt> - Exibe as estatísticas para o grupo de uma mensagem (se são ativados). O parâmetro <i>tipo</i> pode ser:
<ul class="normallist">
<li><tt>chart_average</tt> - Exibe o gráfico com a média. O parâmetro <i>params</i> indica as características do gráfico. Os valores permitidos: <tt>average</tt> (valor médio mostrado), <tt>minmax</tt> (valor mais baixo e mais alto permitido mostrado), <tt>options_text</tt> (mostrado o texto de opções).</li>
<li><tt>chart_hbars</tt> - Exibe o gráfico com barras horizontais. O parâmetro <i>params</i> não é utilizada.</li>
<li><tt>chart_vbars</tt> - Exibe o gráfico com barras verticais.O parâmetro <i>params</i> indica as características do gráfico. Os valores permitidos: <tt>options_text</tt> (mostrado o texto de opções).</li>
<li><tt>summary</tt> - Exibe o resumo. O parâmetro <i>params</i> indica valores para mostrar, separados por vírgulas. Os valores permitidos: <tt>average</tt> (valor médio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (mais valor frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
<li><tt>value</tt> - Exibe um valor de resumo. O parâmetro <i>params</i> indica o valor a ser exibido. Os valores permitidos: <tt>average</tt> (valor médio), <tt>max</tt> (maior valor permitido), <tt>min</tt> (menor valor permitido), <tt>highest</tt> (maior valor usado), <tt>lowest</tt> (menor valor utilizado), <tt>most_frequent</tt> (valor mais frequente), <tt>least_frequent</tt> (valor menos frequente), <tt>total</tt> (total).</li>
</ul></li>
</ul>
Esvazie o campo de texto para excluir o modelo. Se o modelo não está campos definidos são exibidos com o seu nome e conteúdo.';
$helptxt['cffp_template_message_index_text'] = $helptxt['cffp_template_text'];
$helptxt['cffp_template_quick_input'] = 'Texto usado para criar um registro.<br />
Permite que preencher todos os campos de uma só vez, escrevendo todos os valores em um único campo, chamado <strong>Campo de entrada rápida</strong>, de acordo com um modelo ou uma expressão regular.<br />
A expressão regular deve ser compatível com JavaScript. usado em <tt>String.match(regex)</tt> método e deve ser obtida uma matriz de valores de campo começando com a chave 1.<br />
O parâmetros de template consistem em linhas de texto:<br />
<ul class="normallist">
<li>Para cada elemento da matriz obtida a partir da expressão regular acrescenta uma linha com o campo ID.</li>
<li>Linhas que seguem a ordem da matriz.</li>
<li>Se um elemento de matriz não corresponde a qualquer campo, contém texto não utilizado e em que a linha é escrito 0.</li>
<li>Se é necessário formatar um valor antes de copiá-lo em seu campo, sob a linha que contém o ID campo outra linha é adicionado com o código JavaScript que transforma o valor. <tt>value</tt> variável contém o valor original e deve conter o valor transformado. com <tt>field_obj</tt> array, indexado pelo campo ID, não há acesso a todos os campos do formulário no registro.</li>
</ul>
Por exemplo, se o registro tem esses campos<br />
<br />
<table>
<thead>
<tr>
<th>Nome</th>
<th>ID</th>
</tr>
</thead>
<tbody>
<tr>
<td>ID DocBook</td>
<td>3</td>
</tr>
<tr>
<td>Autor nome</td>
<td>1</td>
</tr>
<tr>
<td>Autor sobrenome</td>
<td>2</td>
</tr>
</tbody>
</table>
<br />
é definida<br />
<br />
Expressão regular: <tt>/^(.+)\s+(.+)\s+(.+)\s*/</tt><br />
Parâmetros:<br />
<tt>3<br />
1<br />
var x = value.split(/\s+/g); for (var i = 0; i < x.length; i++) { var parts = x[i].match(/(\w)(\w*)/); x[i] = parts[1].toUpperCase() + parts[2].toLowerCase(); } value = x.join(&quot; &quot;);<br />
2<br />
var x = value.split(/\s+/g); for (var i = 0; i < x.length; i++) { var parts = x[i].match(/(\w)(\w*)/); x[i] = parts[1].toUpperCase() + parts[2].toLowerCase(); } value = x.join(&quot; &quot;);</tt><br />
<br />
e usuário escreve<br />
<br />
<tt>24<br />
LEWIS CARROLL</tt><br />
<br />
campos serão preenchidos, assim:<br />
<br />
ID DocBook: 24<br />
Autor nome: Lewis<br />
Autor sobrenome: Carroll';
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post
Post by: Sakae on June 10, 2015, 10:35:41 AM
./Themes/default/languages/Modifications.portuguese_brazilian.php
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
global $forum_version;
$smf_version_1 = 0 === strpos($forum_version, 'SMF 1');
$txt['cffp'] = 'Campos personalizados e filtros de mensagens';
$txt['cffp_desc'] = 'Painel de administração para o &quot;Custom fields and filters of post&quot; MOD';
$txt['cffp_settings_display'] = 'Definições do campo';
$txt['cffp_settings_input'] = 'Configurações de entrada';
$txt['cffp_settings_search'] = 'Filtros e configurações de pesquisa';
$txt['cffp_settings_advanced'] = 'Ferramentas extras';
$txt['cffp_settings_grouptype'] = 'Configurações para o tipo de &quot;%s&quot;'; // %s is a group type
$txt['cffp_field'] = 'Campo';
$txt['cffp_fields'] = 'Campos';
$txt['cffp_group'] = 'Grupo';
$txt['cffp_group_of_fields'] = 'Grupo de campos';
$txt['cffp_none_field'] = 'Você não adicionou nenhum campo para o grupo!';
$txt['cffp_none_group'] = 'Você não criou nenhum grupo de campos personalizados ainda!';
$txt['cffp_order'] = 'Ordem';
$txt['cffp_order_desc'] = 'Ordem do Display.';
$txt['cffp_text'] = 'Texto';
$txt['cffp_name'] = 'Nome';
$txt['cffp_field_description'] = 'Descrição do campo';
$txt['cffp_field_description_desc'] = 'Exibido junto ao nome do.';
$txt['cffp_field_long_description'] = 'Descrição longa de campo';
$txt['cffp_field_long_description_desc'] = 'Isso é exibido acima do botão. Admite BBC.';
$txt['cffp_field_search_description'] = 'Descrição do campo na página de busca';
$txt['cffp_field_search_description_desc'] = 'Exibido junto ao nome do.';
$txt['cffp_field_search_long_description'] = 'Descrição longa de campo na página de busca';
$txt['cffp_field_search_long_description_desc'] = 'Isso é exibido acima do botão. Admite BBC.';
$txt['cffp_description'] = 'Descrição';
$txt['cffp_text_previous'] = 'Texto anterior';
$txt['cffp_text_previous_desc'] = 'HTML para colocar antes do botão de entrada e saída do texto. Se o campo &quot;Exibe fechado dentro do texto&quot; é utilizada para o texto de saída deve ser escrito <tt>{TEXT_PREVIOUS}</tt> variável nesse.';
$txt['cffp_text_next'] = 'Próximo texto';
$txt['cffp_text_next_desc'] = 'HTML para colocar depois do botão de entrada e fim do texto. Se o campo &quot;Exibe anexado dentro do texto&quot; é utilizada para o texto de saída deve ser escrito <tt>{TEXT_NEXT}</tt> variável nesse.';
$txt['cffp_enclose'] = 'Mostrar dentro do texto';
$txt['cffp_enclose_desc'] = 'Recomendamos <strong>fortemente</strong> a utilização de uma máscara para validar a introdução de dados por parte do utilizador.';
$txt['cffp_text_input_before'] = 'Texto no display antes dos campos quando entrar com os dados';
$txt['cffp_text_input_before_desc'] = 'Admite BBC.';
$txt['cffp_text_input'] = 'Texto a ser exibido ao digitar os dados';
$txt['cffp_text_input_desc'] = 'Admite BBC.';
$txt['cffp_text_output'] = 'Texto a ser exibido durante a visualização de dados';
$txt['cffp_text_output_desc'] = 'Admite BBC.';
$txt['cffp_type'] = 'Tipo';
$txt['cffp_type_filter'] = 'Tipo de filtro';
$txt['cffp_type_filter_desc'] = 'Tipo de acionamento usado no filtro de indicador de mensagens e tópicos de pesquisa.';
$txt['cffp_fieldtype_text'] = 'Texto';
$txt['cffp_fieldtype_textarea'] = 'Grande texto';
$txt['cffp_fieldtype_select'] = 'Caixa de escolha';
$txt['cffp_fieldtype_combobox'] = 'Caixa de combinação';
$txt['cffp_fieldtype_radio'] = 'Acionamento tipo Radio';
$txt['cffp_fieldtype_check'] = 'Caixas de seleção';
$txt['cffp_fieldtype_boolean'] = 'Booleano';
$txt['cffp_grouptype_fields'] = 'Campos soltos';
$txt['cffp_grouptype_record'] = 'Registro';
$txt['cffp_grouptype_member'] = 'Os campos com vários valores por membro';
$txt['cffp_grouptype_filters'] = 'Filtros';
$txt['cffp_length'] = 'O comprimento máximo de dados';
$txt['cffp_length_desc'] = '0 por nenhum limite.';
$txt['cffp_length_text_desc'] = 'A largura do campo proporcional a este valor. Se for 0 ou maior do que ou igual a 100, o campo ocupa a largura total.';
$txt['cffp_dimension'] = 'Medida da largura';
$txt['cffp_dimension_row'] = 'Fileiras';
$txt['cffp_dimension_col'] = 'Colunas';
$txt['cffp_dimension_col_desc'] = 'Se o &quot;Colunas&quot; se 0 ou maior do que ou igual a 100, o campo ocupa a largura total.';
$txt['cffp_mask'] = 'Máscara de entrada';
$txt['cffp_mask_desc'] = 'Para os campos de texto, pode ser seleccionada uma máscara de entrada para validar os dados introduzidos.';
$txt['cffp_mask_email'] = 'Email';
$txt['cffp_mask_number'] = 'Numérica';
$txt['cffp_mask_nohtml'] = 'Sem HTML';
$txt['cffp_mask_regex'] = 'Expressão regular (Avançada)';
$txt['cffp_select_multiple'] = 'Selecionar mais de um';
$txt['cffp_select_size'] = 'Quantidade de campos vistos';
$txt['cffp_allow_bbc'] = 'Permitir BBC';
$txt['cffp_options'] = 'Escolhas';
$txt['cffp_options_desc'] = 'Deixe a caixa de escolha em branco para remover. Tecla de escolha ou caixa de escolha seleciona as alternativas marcadas.';
$txt['cffp_options_more'] = 'Mais';
$txt['cffp_options_add_multi'] = 'Adicionar mais de uma escolha';
$txt['cffp_options_add_multi_desc'] = 'Escreva uma escolha em cada linha. Cada escolha tem valor e texto, separados por virgulas. Texto opcional.';
$txt['cffp_options_add_multi_combo_desc'] = 'Escreva um alternativa para cada linha';
$txt['cffp_default_value'] = 'Valor oficial';
$txt['cffp_boards'] = 'Sub-Fóruns';
$txt['cffp_child_boards'] = 'Incluir Sub-Fóruns descendentes';
$txt['cffp_child_boards_until'] = 'Até %d nível';
$txt['cffp_show_group_name_message_index'] = 'Ver nome do grupo no índice da mensagens';
$txt['cffp_show_group_name_message_index_desc'] = 'Se nenhum grupo for selecionado, nenhum grupo exibido no índice da mensagens.';
$txt['cffp_show_group_name_filter'] = 'Ver o nome do grupo nos filtros';
$txt['cffp_show_group_name_filter_desc'] = 'Se nenhum nome de grupo de filtros for selecionado, nenhum grupo exibido no índice da mensagens.';
$txt['cffp_show_group_name_search'] = 'Ver o nome do grupo na busca';
$txt['cffp_show_group_name_search_desc'] = 'Se nenhum nome de grupo for selecionado, nenhum gropo exibido na busca.';
$txt['cffp_show_fields_name'] = 'Ver nome dos campos';
$txt['cffp_show_fields_name_desc'] = 'Se nenhum nome for selecionado, nada exibido ao lado dos campos do grupo.';
$txt['cffp_show_fields_set'] = 'Ver campos como um conjunto';
$txt['cffp_show_fields_set_desc'] = 'Se selecionado os campos, agrupa-se sob o nome do grupo.';
$txt['cffp_show_empty_fields_post'] = 'Ver campos vazios na mensagem';
$txt['cffp_show_empty_fields_message_index'] = 'Ver campos vazios no índice da mensagens';
$txt['cffp_show_poster_data'] = 'Exibir data de criação em dados postados';
$txt['cffp_show_modified_data'] = 'Exibir data da última modificação em dados modificados';
$txt['cffp_show_actions_as'] = 'Ver atos como';
$txt['cffp_show_actions_as_button'] = 'Teclas';
$txt['cffp_show_actions_as_icon_text'] = 'Elemento e texto';
$txt['cffp_show_actions_as_icon'] = 'Elementos';
$txt['cffp_show_actions_as_text'] = 'Texto';
$txt['cffp_show_member_expanded'] = 'Ver expandido';
$txt['cffp_show_member_expanded_data'] = 'Ver expandido os dados postados';
$txt['cffp_show_member_expanded_data_recent'] = 'Ver expandido o mais recente dados postados';
$txt['cffp_show_member_expanded_data_recent_desc'] = '0 para todos.';
$txt['cffp_show_member_expanded_new'] = 'Ver expandido o nova respota';
$txt['cffp_show_member_recent_at_top'] = 'Ver o mais recente dados da mensagens no topo';
$txt['cffp_member_max_height'] = 'Maior altura do campo dos dados postados';
$txt['cffp_member_max_height_px'] = 'px';
$txt['cffp_member_max_height_desc'] = '0 para ilimitado.';
$txt['cffp_member_one_value'] = 'Apenas um valor por membro';
$txt['cffp_member_one_value_desc'] = 'Cada membro pode publicar os dados apenas uma vez.';
$txt['cffp_show_stats'] = 'Exibir estatísticas';
$txt['cffp_show_stats_desc'] = 'O grupo deve ter apenas um campo, tipo caixa de seleção, botões de rádio ou caixas de seleção.';
$txt['cffp_show_stats_post'] = 'Exibir estatísticas no post';
$txt['cffp_show_stats_message_index'] = 'Exibir estatísticas sobre índice de mensagens';
$txt['cffp_show_stats_text'] = 'Texto a ser exibido antes';
$txt['cffp_show_stats_text_desc'] = 'Admite BBC.';
$txt['cffp_show_stats_chart_average'] = 'Exibir gráfico com média';
$txt['cffp_show_stats_chart_hbars'] = 'Exibir gráfico com barras horizontais';
$txt['cffp_show_stats_chart_vbars'] = 'Exibir gráfico com barras verticais';
$txt['cffp_show_stats_summary'] = 'Exibir resumo';
$txt['cffp_show_stats_summary_average'] = 'Valor médio';
$txt['cffp_show_stats_summary_max'] = 'Maior valor permitido';
$txt['cffp_show_stats_summary_min'] = 'Menor valor permitido';
$txt['cffp_show_stats_summary_highest'] = 'Maior valor usado';
$txt['cffp_show_stats_summary_lowest'] = 'Menor valor utilizado';
$txt['cffp_show_stats_summary_most_frequent'] = 'Mais valor frequente';
$txt['cffp_show_stats_summary_least_frequent'] = 'Valor menos frequente';
$txt['cffp_show_stats_only_numeric'] = 'Apenas se os dados sãão numéricos';
$txt['cffp_show_stats_average'] = 'Exibir valor médio';
$txt['cffp_show_stats_minmax'] = 'Exibir valor mais baixo e mais alto permitido';
$txt['cffp_show_stats_options_text'] = 'Exibir o texto de opções';
$txt['cffp_show_stats_order_by'] = 'Use estatísticas para ordenar o índice de mensagens';
$txt['cffp_show_sticky'] = 'Ver em tópicos fixos';
$txt['cffp_show_locked'] = 'Mostrar em tópicos bloqueados';
$txt['cffp_show_first_post_topic'] = 'Ativar na primeira mensagem do tópico';
$txt['cffp_show_replies_topic'] = 'Ativar nas respostas do tópico';
$txt['cffp_no_show_with_subject_prefix'] = 'Exibir nenhum campo para inserir junto ao assunto';
$txt['cffp_no_show_with_subject_prefix_desc'] = 'Prefixos separados por vírgulas. Exemplo:;.';
$txt['cffp_show_in_topic'] = 'Exibir como grupo de campos do tópico';
$txt['cffp_show_in_topic_desc'] = 'Se o grupo estive no campo em apenas no primeiro post desde o tópico pode ser visto como pertencente ao tópico ao invés do post, e exibido em outra área do tema, diferente para postar.';
$txt['cffp_show_in_topic_no'] = 'Nenhum (O grupo visto no campo da primeira mensagem)';
$txt['cffp_show_in_topic_begin_all'] = 'Sim, no começo de todos as páginas do tópicos';
$txt['cffp_show_in_topic_end_all'] = 'Sim, inserido no fim de todas as páginas do tópicos';
$txt['cffp_show_in_topic_begin_first'] = 'Sim, no começo da primeira página do tópicos';
$txt['cffp_show_in_topic_end_first'] = 'Sim, no final do primeira página do tópicos';
$txt['cffp_show_filters'] = 'Filtros';
$txt['cffp_show_filters_desc'] = 'Selecionar o filtro a ser utilizado.';
$txt['cffp_show_filters_boards'] = 'Sub-Fóruns';
$txt['cffp_show_filters_subject_start'] = 'Comece do assunto';
$txt['cffp_show_filters_subject_first_char'] = 'Primeiro caractere do sujeito';
$txt['cffp_show_filters_date_topic'] = 'Dados do tópicos';
$txt['cffp_show_filters_date_replies'] = 'Dados da última resposta';
$txt['cffp_show_filters_date_lastdays'] = 'Último %s dias';
$txt['cffp_show_filters_topic_new_posts'] = 'Tópicos com novos post';
$txt['cffp_show_filters_sticky'] = 'Fixos';
$txt['cffp_show_filters_sticky_disabled'] = 'Tópicos fixos desativados. O Filtro não será exibido.';
$txt['cffp_show_filters_locked'] = 'Trancado';
$txt['cffp_show_filters_sticky_locked'] = 'Fixos e trancados';
$txt['cffp_javascript'] = 'Código JavaScript';
$txt['cffp_javascript_desc'] = 'Código executado quando um grupo de campos for criado ou modificado.';
$txt['cffp_search_page'] = 'Procurar tópicos';
$txt['cffp_search_page_post_desc'] = 'Escrever o nome dos tópicos e seleccione a ordem dos resultados de cada. Para remover um tema simplesmente esvaziar a caixa de texto para esse tema. Para adicionar um tema já existente, selecione-o na lista.';
$txt['cffp_search_page_post_default'] = 'Tópicos predefinidos';
$txt['cffp_search_page_post_more'] = 'Mais';
$txt['cffp_search_page_post_add'] = 'Adicionar um tópicos existente';
$txt['cffp_search_page_record_desc'] = 'Predefinido: &quot;Pesquisar registros do tipo...&quot;.';
$txt['cffp_search_page_order_by'] = 'Ordenar resultados da pesquisa por';
$txt['cffp_search_page_order_by2'] = 'Ordenar por';
$txt['cffp_search_page_order_by_desc'] = 'Para que um campo seja mostrado aqui, deve ser exibido em uma coluna com apenas esse campo ou seja o primeiro campo na coluna.';
$txt['cffp_counter'] = 'Contador na informação sobre o usuário';
$txt['cffp_counter_desc'] = 'Nome predefinido: Nome do grupo.';
$txt['cffp_counter_show'] = 'Exibir contador';
$txt['cffp_counter_name'] = 'Nome';
$txt['cffp_profile_list'] = 'Lista no perfil de membro';
$txt['cffp_profile_list_desc'] = 'Nome predefinido: Nome do grupo.';
$txt['cffp_profile_list_show'] = 'Exibir lista';
$txt['cffp_profile_list_name'] = 'Nome';
if (!$smf_version_1)
$txt['cffp_moderation_list'] = 'Lista no Centro de Moderar';
else
$txt['cffp_moderation_list'] = 'Lista de moderação';
$txt['cffp_moderation_list_desc'] = 'Nome predefinido: Nome do grupo. Para que um campo seja mostrado aqui, deve ser exibido em uma coluna com apenas esse campo ou seja o primeiro campo na coluna.';
$txt['cffp_moderation_list_show'] = 'Exibir lista';
$txt['cffp_moderation_list_menu'] = 'Exibir link no menu do Fórum';
$txt['cffp_moderation_list_name'] = 'Nome';
$txt['cffp_moderation_list_order_by'] = 'Ordenar por';
$txt['cffp_show_message_index'] = 'Exibir no índice de mensagens';
$txt['cffp_show_message_index_desc'] = 'Aplica-se, se for no primeiro post do tópicos.';
$txt['cffp_show_filter_operator'] = 'Exibir filtro com operador';
$txt['cffp_show_filter_operator_desc'] = 'Se selecionado permite selecionar o operador com o qual aplicar o filtro. Operador padrão é &quot;igual a&quot; ou &quot;semelhante&quot;, de acordo com o tipo de filtro.';
$txt['cffp_show_filter_operator_like'] = 'Incluir';
$txt['cffp_show_filter_operator_not_like'] = 'Não Incluir';
$txt['cffp_hide_filter'] = 'Esconder o filtro sob uma tag';
$txt['cffp_hide_filter_desc'] = 'O filtro fica escondido e é exibido clicando na tag. A mesma tag pode esconder vários filtros.';
$txt['cffp_show_filter_used_options'] = 'Exibir apenas opções usadas';
$txt['cffp_show_filter_used_options_desc'] = 'Exibir no filtro apenas os itens que utilizados pela atual diretoria.';
$txt['cffp_show_record_list_type'] = 'Mostrar em listas de registros';
$txt['cffp_show_record_list_type_desc'] = 'Mostra este campo em uma coluna das listas de registros (por exemplo, na busca de registos).';
if (!$smf_version_1)
{
$txt['cffp_show_moderation_list_type'] = 'Exibir em listas de Centro de Moderar';
$txt['cffp_show_moderation_list_type_desc'] = 'Exibir este campo em uma coluna das listas de Centro de Moderar.';
}
else
{
$txt['cffp_show_moderation_list_type'] = 'Exibir em listas de moderação';
$txt['cffp_show_moderation_list_type_desc'] = 'Exibir este campo em uma coluna das listas de moderação.';
}
$txt['cffp_show_list_type_no'] = 'Nenhum';
$txt['cffp_show_list_type_one'] = 'Sim, em uma coluna com apenas este campo';
$txt['cffp_show_list_type_multi'] = 'Sim, em uma coluna juntamente com outros campos';
$txt['cffp_show_list_width'] = 'A largura da coluna';
$txt['cffp_show_list_width_desc'] = '0 para automatizado.';
$txt['cffp_show_list_width_unit_auto'] = 'Automatizado';
$txt['cffp_show_list_width_unit_%'] = 'Incostante';
$txt['cffp_show_list_width_unit_px'] = 'Fixo';
$txt['cffp_show_list_column'] = 'Coluna com variados campos';
$txt['cffp_show_list_column_other'] = 'Outro...';
$txt['cffp_show_list_name'] = 'Nome da coluna';
$txt['cffp_show_list_name_desc'] = 'Se não for especificado a coluna conterá somente neste campo.';
$txt['cffp_not_empty_value'] = 'Não tem valor vazio';
$txt['cffp_not_empty_value_desc'] = 'Se selecionado este campo não pode ser deixado em branco.';
$txt['cffp_unique_value'] = 'Valor único';
$txt['cffp_unique_value_desc'] = 'Se selecionado não pode ter dois valores iguais neste campo.';
$txt['cffp_subset'] = 'Subconjunto';
$txt['cffp_subset_desc'] = 'O campo é exibido dentro de um subconjunto. Os campos de um subconjunto devem ser adjacentes.';
$txt['cffp_permissions'] = 'Permissões';
$txt['cffp_permissions_field_desc'] = 'As ações que um membro pode executar ao longo deste campo, sujeitos &agrave;s permissões do fórum.';
$txt['cffp_permissions_group_desc'] = 'As ações que um membro pode executar ao longo deste grupo, sujeitos &agrave;s permissões do fórum.';
$txt['cffp_owner_post'] = 'Dono da mensagem';
$txt['cffp_owner_group'] = 'Dono do grupo';
$txt['cffp_local_moderator'] = 'Moderador local';
$txt['cffp_global_moderator'] = 'Moderador global';
$txt['cffp_administrator'] = 'Administrador';
$txt['cffp_view_message_index'] = 'Veja no índice de mensagens';
$txt['cffp_view_stats'] = 'Exibir estatísticas';
$txt['cffp_filter'] ='Filtro';
$txt['cffp_sort'] ='Ordenar';
$txt['cffp_add'] = 'Adicionar';
$txt['cffp_move'] = 'Mover';
$txt['cffp_active'] = 'Ativo';
$txt['cffp_active_field_desc'] = 'Se não for selecionado este campo não será mostrado a ninguém.';
$txt['cffp_active_group_desc'] = 'Se não for selecionado este grupo não será mostrado a ninguém.';
$txt['cffp_more_info'] = 'Mais informações';
$txt['cffp_id'] = 'ID';
$txt['cffp_make_new_field'] = 'Novo campo';
$txt['cffp_make_new_group'] = 'Novo grupo';
$txt['cffp_add_field_title'] = 'Adicionar campo';
$txt['cffp_add_group_title'] = 'Adicionar grupo de campos';
$txt['cffp_edit_field_title'] = 'Editar campo';
$txt['cffp_edit_group_title'] = 'Editar grupo de campos';
$txt['cffp_edit_delete_field_sure'] = 'Tem certeza de que deseja apagar este campo? Todos os dados da mensagens relacionados serão perdidos!';
$txt['cffp_edit_delete_group_sure'] = 'Tem certeza de que deseja excluir este grupo? Todos os dados da mensagens relacionados serão perdidos!';
$txt['cffp_template'] = 'Template para mensagens';
$txt['cffp_template_message_index'] = 'Template para índice de mensagens';
$txt['cffp_template_quick_input'] = 'Template para entrada rápida';
$txt['cffp_template_quick_input_regex'] = 'Expressão regular';
$txt['cffp_template_quick_input_regex_desc'] = 'Compatível com JavaScript. Usado em <tt>String.match(regex)</tt> método e deve ser obtida uma matriz de valores de campo começando com a tecla 1.';
$txt['cffp_template_quick_input_params'] = 'Parâmetros';
$txt['cffp_template_quick_input_params_desc'] = 'Para cada elemento da matriz obtida a partir da expressão regular acrescenta uma linha com o campo ID, ou 0 se ele não corresponder a qualquer campo. Para a formatação de um valor antes de copiá-lo em seu campo, abaixo do campo de ID para adicionar outra linha com o código JavaScript. <tt>value</tt> variável contém o valor original e deve conter o valor transformado. Com <tt>field_obj[</tt>ID_campo<tt>]</tt> pode acessar um campo de formulário.';
$txt['cffp_template_quick_input_help'] = 'Ajuda';
$txt['cffp_template_quick_input_help_desc'] = 'Texto que o utilizador verá em vez da expressão regular. Permitir BBC.';
$txt['cffp_template_quick_input_show_modify'] = 'Exibir quando os dados são modificados';
$txt['cffp_template_quick_input_show_modify_desc'] = 'Se não for selecionado só será exibido quando os dados são criados.';
$txt['cffp_template_type_html'] = 'HTML';
$txt['cffp_template_type_bbc'] = 'BBC';
$txt['cffp_template_type_php'] = 'PHP';
$txt['cffp_add_templates'] = 'Adicionar templates';
$txt['cffp_edit_templates'] = 'Editar templates';
$txt['cffp_warning_cannot_see_group_fields'] = 'Você não pode ver os campos deste grupo.';
$txt['cffp_warning_group_subject'] = 'Esses campos serão removidos se o post sujeito começa com: %s.';
$txt['cffp_quick_input_field'] = 'Campo de entrada rápida';
$txt['cffp_quick_input_field_desc'] = 'Escrever valores para entrar em campos diferentes de acordo com esta expressão regular:';
$txt['cffp_quick_input_match'] = 'Os campos são preenchidos.';
$txt['cffp_quick_input_no_match'] = 'Conteúdo do &quot;campo de entrada rápida&quot; não está formatado corretamente. Campos não pode ser preenchido.';
$txt['cffp_quick_input_apply'] = 'Preencha os campos';
$txt['cffp_created'] = 'Criado';
$txt['cffp_edit_group'] = 'Editar %s';
$txt['cffp_show'] = 'Exibir';
$txt['cffp_show_previous'] = 'Mostrar anterior';
$txt['cffp_move_to_first_post'] = 'Mover-se para o primeiro mensagem neste tópicos';
$txt['cffp_move_to_other_post'] = 'Mover-se para um outro mensagem';
$txt['cffp_move_to_other_topic'] = 'Mover-se para um outro tópicos';
$txt['cffp_move_group_to_other_post'] = 'Mover-se %s para outro mensagem';
$txt['cffp_move_group_to_other_topic'] = 'Mover-se %s para outro tópicos';
$txt['cffp_move_to_post'] = 'Mover-se para o mensagem';
$txt['cffp_move_to_post_desc'] = 'Mensagem ID. Exemplo: index.php?topic=4043.msg23892, use 23892.';
$txt['cffp_move_to_topic'] = 'Mover-se para o tópicos';
$txt['cffp_move_to_topic_desc'] = 'Tópicos ID. Exemplo: index.php?topic=4043.0, use 4043.';
$txt['cffp_search_posts_records'] = 'Pesquisa de post e registros';
$txt['cffp_search_posts'] = 'Procurar mensagens';
$txt['cffp_search_posts_desc'] = 'Escreva o texto e/ou selecione as opççõs nos campos em que deseja pesquisar. Você vai ter uma lista de mensagens que contenham esses valores em seus campos.';
$txt['cffp_search_records_type'] = 'Pesquisar registros do tipo %s';
$txt['cffp_search_records_desc'] = 'Escreva o texto e/ou selecione as opççõs nos campos em que deseja pesquisar. Você vai ter uma lista de registros que contêm esses valores em seus campos.';
$txt['cffp_show_fields'] = 'Mostrar campos';
$txt['cffp_hide_fields'] = 'Ocultar campos';
$txt['cffp_record_type'] = 'Registros do tipo %s';
$txt['cffp_records'] = 'Registros';
if (!$smf_version_1)
$txt['cffp_moderation_area'] = 'Grupos de campos em mensagens';
else
$txt['cffp_moderation_area'] = 'Moderado grupos de campos em mensagens';
$txt['cffp_moderation_area_desc'] = 'Aqui você pode rever todos os dados postados por membros em grupos de campos personalizados.';
$txt['cffp_moderation_area_delete_sure'] = 'Tem certeza de que deseja apagar estes dados?';
$txt['cffp_moderation_area_none'] = 'Não existem dados publicados';
$txt['cffp_poster_time'] = 'Dados postados';
$txt['cffp_topic_without_replies'] = 'Tópicos sem respostas';
$txt['cffp_symbol'] = 'Símbolo';
$txt['cffp_number'] = 'Número';
$txt['cffp_alphabet_letters'] = 'A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X,Y,Z'; // Portuguese alphabet (capital letters comma separated)
$txt['cffp_field_empty_value'] = 'Nenhum dados';
$txt['cffp_field_non_empty_value'] = 'Há dados';
$txt['cffp_filtertype_empty_non_empty'] = $txt['cffp_field_empty_value'] . ' / ' . $txt['cffp_field_non_empty_value'];
$txt['cffp_order_by_asc'] = 'Ordem ascendente';
$txt['cffp_order_by_desc'] = 'Ordem decrescente';
$txt['cffp_wireless_end_group'] = 'Fim %s';
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post
Post by: Sakae on June 10, 2015, 10:40:35 AM
Finally, an error, not sure if common, but happened to my smf.

I tested all my smf functions right after installed the mod, but it seems I can't delete any messages. All references I got for 'f.id_member' was on this mod edit of Sources/Removetopic.php, so I'm stuck now.

Code: [Select]
Erro na Base de Dados
Unknown column 'f.id_member' in 'where clause'
Arquivo: /xxx/Sources/RemoveTopic.php
Linha: 1020

Nota: Parece que a sua base de dados precisa de ser atualizada. Os arquivos do seu Fórum estão na versão SMF 2.0.10, enquanto que a sua base de dados está na versão SMF 2.0.9. Recomenda-se que seja executada a últiuma versão do arquivo de upgrade.php.

Something about upgrade my database to 2.0.10? Should I follow the message and see what happens?

Or perhaps should I run the db files of your mod again?
Title: Re: Custom fields and filters of post
Post by: davidhs on June 11, 2015, 04:55:21 PM
Not neccessary ;)

Edit the correct language file ("portuguese_brazilian"). Have not reviewed Americano translation, so here it goes for portuguese_brazilian-utf8:

[...]
:o I'm sorry but ... I think you are confused.

I had this problem when I published one of my mods. Before I wrote characters always (in UTF-8 and ISO 8859-1) but SMF team said to me that in ISO 8859-1 languages must be with HTML entities.

Reason (in my words):
- UTF-8 is a multilanguage code, encode all simbols of "all" languages.
- ISO 8859-1 is a basic set of latin characters and no-English characters must be written as HTML entities.

Finally, an error, not sure if common, but happened to my smf.

I tested all my smf functions right after installed the mod, but it seems I can't delete any messages. All references I got for 'f.id_member' was on this mod edit of Sources/Removetopic.php, so I'm stuck now.

Code: [Select]
Erro na Base de Dados
Unknown column 'f.id_member' in 'where clause'
Arquivo: /xxx/Sources/RemoveTopic.php
Linha: 1020

Nota: Parece que a sua base de dados precisa de ser atualizada. Os arquivos do seu Fórum estão na versão SMF 2.0.10, enquanto que a sua base de dados está na versão SMF 2.0.9. Recomenda-se que seja executada a últiuma versão do arquivo de upgrade.php.

Something about upgrade my database to 2.0.10? Should I follow the message and see what happens?

Or perhaps should I run the db files of your mod again?
Your database is correct. It is a serious bug of my mod! I am sorry, I tested "all" cases but I did not saw this... :(

I will see now and fix this.
Title: Re: Custom fields and filters of post
Post by: davidhs on June 13, 2015, 08:54:29 AM
In next update I will review all Portuguese strings (utf8 and iso).
Fixed.

Finally, an error, not sure if common, but happened to my smf.

I tested all my smf functions right after installed the mod, but it seems I can't delete any messages. All references I got for 'f.id_member' was on this mod edit of Sources/Removetopic.php, so I'm stuck now.

Code: [Select]
Erro na Base de Dados
Unknown column 'f.id_member' in 'where clause'
Arquivo: /xxx/Sources/RemoveTopic.php
Linha: 1020

Nota: Parece que a sua base de dados precisa de ser atualizada. Os arquivos do seu Fórum estão na versão SMF 2.0.10, enquanto que a sua base de dados está na versão SMF 2.0.9. Recomenda-se que seja executada a últiuma versão do arquivo de upgrade.php.
Fixed.



New version:
Code: [Select]
1.3.1   2015-06-13
------------------
! SMF 2.0.x: Error in SQL code.
! Use HTML entities in ISO-8859-1 languages.
! Since version 1.2 the help text is too long and generates an error on uninstallation. It is divided in two operations.



If your forum is in Spanish or Portuguese ISO-8859-1 (not UTF-8) and versions 1.2 or 1.3 of this mod are used, when you uninstall it to upgrade to the new version 1.3.1 can be eliminated all help in your language. This is due to the help of this mod is very large and occurs the error detected here http://www.simplemachines.org/community/index.php?topic=117506.0

I write steps for avoid this problem here http://www.simplemachines.org/community/index.php?topic=117506.msg3818378#msg3818378

In step 4, removes all the text between these texts, including these:
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
...
// END MOD CustomFieldFilterPost
Title: Re: Custom fields and filters of post
Post by: Sakae on June 15, 2015, 03:19:28 PM
In next update I will review all Portuguese strings (utf8 and iso).
Fixed.

Ok, I understand about ISO-8859-1. But I shall insist for the correct language files to be updated: portuguese_brazilian-utf8.php. There is no brazilian-utf8.php language files... :-\

Finally, an error, not sure if common, but happened to my smf.

I tested all my smf functions right after installed the mod, but it seems I can't delete any messages. All references I got for 'f.id_member' was on this mod edit of Sources/Removetopic.php, so I'm stuck now.

Code: [Select]
Erro na Base de Dados
Unknown column 'f.id_member' in 'where clause'
Arquivo: /xxx/Sources/RemoveTopic.php
Linha: 1020

Nota: Parece que a sua base de dados precisa de ser atualizada. Os arquivos do seu Fórum estão na versão SMF 2.0.10, enquanto que a sua base de dados está na versão SMF 2.0.9. Recomenda-se que seja executada a últiuma versão do arquivo de upgrade.php.
Fixed.

Working great now :D
Title: Re: Custom fields and filters of post
Post by: davidhs on June 15, 2015, 04:00:42 PM
In next update I will review all Portuguese strings (utf8 and iso).
Fixed.

Ok, I understand about ISO-8859-1. But I shall insist for the correct language files to be updated: portuguese_brazilian-utf8.php. There is no brazilian-utf8.php language files... :-\
Yes, it is true... in SMF 2.0.x does not exists "brazilian" language but in SMF 1.1.x yes (at least 1.1-1.1.5). Because of this I add "portuguese_brazilian" and "brazilian" (and "portuguese-pt", of course). Same case of "spanish", "spanish-es" and "spanish-latin".
Title: Re: Custom fields and filters of post
Post by: davidhs on June 19, 2015, 12:18:12 PM
New version:
Code: [Select]
1.3.2   2015-06-19
------------------
! Errors in source code.
Title: Re: Custom fields and filters of post
Post by: Mabba on June 19, 2015, 03:30:30 PM
Errors
see attach.
Title: Re: Custom fields and filters of post
Post by: davidhs on June 20, 2015, 07:12:42 AM
Errors
see attach.
You have installed another mod that changes the member's profile.

Attach your files

/Sources/Profile-View.php
/Themes/default/Profile.template.php

and I will tell that changes must do by hand.
Title: Re: Custom fields and filters of post
Post by: Mabba on June 21, 2015, 01:42:40 AM
Here the files are in the appendix.
Thanks in advance.
Title: Re: Custom fields and filters of post
Post by: davidhs on June 21, 2015, 07:40:38 AM
Here the files are in the appendix.
Thanks in advance.
You have install a mod with topic prefix and this mod modify same source code of my mod.

If you want install my mod do these steps:
 
1. Install my mod with errors.

2. Open your /Sources/Profile-View.php and do modifications by hand:

2.1. Do modification #8
Search (line 413)
Code: [Select]
t.approved, m.body, m.smileys_enabled, m.subject, m.poster_time, m.id_topic, m.id_msg, t.id_prefix

Replace by
Code: [Select]
t.approved, m.body, m.smileys_enabled, m.subject, m.poster_time, m.id_topic, m.id_msg, t.id_prefix
' /* BEGIN MOD CustomFieldFilterPost */ . ', t.is_sticky, t.locked' . /* END MOD CustomFieldFilterPost */ '

2.2. Do modification #9
Search (line 434)
Code: [Select]
$request = $smcFunc['db_query']('', '
SELECT
b.id_board, b.name AS bname, c.id_cat, c.name AS cname, m.id_topic, m.id_msg,
t.id_member_started, t.id_first_msg, t.id_last_msg, m.body, m.smileys_enabled, t.id_prefix,
m.subject, m.poster_time, m.approved
FROM {db_prefix}messages AS m
INNER JOIN {db_prefix}topics AS t ON (t.id_topic = m.id_topic)
INNER JOIN {db_prefix}boards AS b ON (b.id_board = t.id_board)
LEFT JOIN {db_prefix}categories AS c ON (c.id_cat = b.id_cat)
WHERE m.id_member = {int:current_member}' . (!empty($board) ? '
AND b.id_board = {int:board}' : '') . (empty($range_limit) ? '' : '
AND ' . $range_limit) . '
AND {query_see_board}' . (!$modSettings['postmod_active'] || $context['user']['is_owner'] ? '' : '
AND t.approved = {int:is_approved} AND m.approved = {int:is_approved}') . '
ORDER BY m.id_msg ' . ($reverse ? 'ASC' : 'DESC') . '
LIMIT ' . $start . ', ' . $maxIndex,
array(
'current_member' => $memID,
'is_approved' => 1,
'board' => $board,
)
);
Replace by
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
$request = $smcFunc['db_query']('', '
SELECT
DISTINCT
t.is_sticky, t.locked,
b.id_board, b.name AS bname, c.id_cat, c.name AS cname, m.id_topic, m.id_msg,
t.id_member_started, t.id_first_msg, t.id_last_msg, m.body, m.smileys_enabled, t.id_prefix,
m.subject, m.poster_time, m.approved
FROM {db_prefix}messages AS m
INNER JOIN {db_prefix}topics AS t ON (t.id_topic = m.id_topic)
INNER JOIN {db_prefix}boards AS b ON (b.id_board = t.id_board)' . ($context['is_cffp_record'] ? '
INNER JOIN {db_prefix}cffp_fields AS cffpf ON (cffpf.id_msg = m.id_msg)' : '') . '
LEFT JOIN {db_prefix}categories AS c ON (c.id_cat = b.id_cat)
WHERE m.id_member = {int:current_member}' . (!empty($board) ? '
AND b.id_board = {int:board}' : '') . (empty($range_limit) ? '' : '
AND ' . $range_limit) . ($context['is_cffp_record'] ? '
AND cffpf.id_group = {int:id_group}' : '') . '
AND {query_see_board}' . (!$modSettings['postmod_active'] || $context['user']['is_owner'] ? '' : '
AND t.approved = {int:is_approved} AND m.approved = {int:is_approved}') . '
ORDER BY m.id_msg ' . ($reverse ? 'ASC' : 'DESC') . '
LIMIT ' . $start . ', ' . $maxIndex,
array(
'current_member' => $memID,
'is_approved' => 1,
'board' => $board,
'id_group' => $context['is_cffp_record'],
)
);
// END MOD CustomFieldFilterPost

3. Open your /Themes/default/Profile.template.php and do modifications by hand:

3.1. Do modification #2
Search (line 392)
Code: [Select]
echo '
', $post['body'];
if (array_key_exists('thank_list', $post)) {
echo template_saythanks_thanker_list($post, $post['thank_list']);
}
echo '
Replace by
Code: [Select]
// BEGIN MOD CustomFieldFilterPost
// Show custom post fields.
$context['cffp']['display_readonly'] = $post['cffp']['display_readonly'];
template_cffp_show('display_readonly');

echo '
', $post['body'];

// Show custom post fields per member.
$context['cffp']['display_member_readonly'] = $post['cffp']['display_member_readonly'];
template_cffp_show('display_member_readonly');

if (array_key_exists('thank_list', $post)) {
echo template_saythanks_thanker_list($post, $post['thank_list']);
}
echo '
<!-- END MOD CustomFieldFilterPost -->

4. End. ;)

When you uninstall this mod, you must undo these modifications by hand.
Title: Re: Custom fields and filters of post
Post by: sangham.net on June 22, 2015, 12:54:11 PM
Valued Mr. Davidhs,

being directed here, generously by valued Mr. live627 from "Vision of a SMF-DIC tionary mod (http://www.simplemachines.org/community/index.php?topic=537527.msg3820022#msg3820022)", my person likes to ask kindly if Mr. Davidhs thinks, that it is proper for this use and if he appreciates the use for it, since my person is not sure about it.

Thanks a lot, and sorry for using your time in advanced.

Title: Re: Custom fields and filters of post
Post by: davidhs on June 23, 2015, 07:36:45 AM
Valued Mr. Davidhs,

being directed here, generously by valued Mr. live627 from "Vision of a SMF-DIC tionary mod (http://www.simplemachines.org/community/index.php?topic=537527.msg3820022#msg3820022)", my person likes to ask kindly if Mr. Davidhs thinks, that it is proper for this use and if he appreciates the use for it, since my person is not sure about it.

Thanks a lot, and sorry for using your time in advanced.
I reply in your topic "Vision of a SMF-DIC tionary mod" http://www.simplemachines.org/community/index.php?topic=537527.msg3820399#msg3820399
Title: Re: Custom fields and filters of post
Post by: Americano on July 06, 2015, 07:52:33 PM
Davidhs Hello, How are you?

I tested a Latest Version. Excellent.   :)

is it could have top?

You can make a top 10 rank of the custom fields.  :-X

---

I like of the Enhancements to recent posts  :D

I do the translation into Portuguese, if you want 
Title: Re: Custom fields and filters of post
Post by: davidhs on July 07, 2015, 07:10:42 AM
Davidhs Hello, How are you?

I tested a Latest Version. Excellent.   :)
Thanks for all! I am pleased that you like.

is it could have top?

You can make a top 10 rank of the custom fields.  :-X
Sorry for my bad English. I do not understand this phrases. It is an enhancement?

I like of the Enhancements to recent posts  :D

I do the translation into Portuguese, if you want 
Yes, of course, you can translate this and others of my mods. :)
Title: Re: Custom fields and filters of post
Post by: Americano on July 07, 2015, 03:43:35 PM

is it could have top?

You can make a top 10 rank of the custom fields.  :-X
Sorry for my bad English. I do not understand this phrases. It is an enhancement?

Do you can to make top 10 users who posted more custom fields

Mod Top 10 custom fields
Title: Re: Custom fields and filters of post
Post by: davidhs on July 08, 2015, 06:23:19 AM

is it could have top?

You can make a top 10 rank of the custom fields.  :-X
Sorry for my bad English. I do not understand this phrases. It is an enhancement?

Do you can to make top 10 users who posted more custom fields

Mod Top 10 custom fields
Ok, I understand.

In first post of this topic I wrote an example of use of this mod, but users can send to me their custom fields and I will publish as example.

This mod is complex and now I have only one example. The more the merrier. Examples with images of screen are welcome :)
Title: Re: Custom fields and filters of post
Post by: Americano on July 08, 2015, 02:20:27 PM

is it could have top?

You can make a top 10 rank of the custom fields.  :-X
Sorry for my bad English. I do not understand this phrases. It is an enhancement?

Do you can to make top 10 users who posted more custom fields

Mod Top 10 custom fields
Ok, I understand.

In first post of this topic I wrote an example of use of this mod, but users can send to me their custom fields and I will publish as example.

This mod is complex and now I have only one example. The more the merrier. Examples with images of screen are welcome :)

I don't understand...  :(

I want a top 10 custom field like the top 10 post.

check the example image
Title: Re: Custom fields and filters of post
Post by: davidhs on July 10, 2015, 08:57:03 AM

is it could have top?

You can make a top 10 rank of the custom fields.  :-X
Sorry for my bad English. I do not understand this phrases. It is an enhancement?

Do you can to make top 10 users who posted more custom fields

Mod Top 10 custom fields
Ok, I understand.

In first post of this topic I wrote an example of use of this mod, but users can send to me their custom fields and I will publish as example.

This mod is complex and now I have only one example. The more the merrier. Examples with images of screen are welcome :)

I don't understand...  :(

I want a top 10 custom field like the top 10 post.

check the example image
Ok, now I understand. I expect! :)

I will see...
Title: Re: Custom fields and filters of post
Post by: Americano on July 10, 2015, 08:42:33 PM
For example:

In the forum has custom field that call reviews

In a user profile contains:

Posts 20
Reviews: 10 (it works perfectly  8))

The statistics will look like this:

Top 10 posts (already exists) and Top 10 review (new mod)

This mod would be an addition to the counter custom fields

I hope you understand  :)
Title: Re: Custom fields and filters of post
Post by: davidhs on July 12, 2015, 08:00:12 AM
For example:

In the forum has custom field that call reviews

In a user profile contains:

Posts 20
Reviews: 10 (it works perfectly  8))

The statistics will look like this:

Top 10 posts (already exists) and Top 10 review (new mod)

This mod would be an addition to the counter custom fields

I hope you understand  :)
Yes, I saw Statistical section in my forum. I will add a "Top 10 user" for each group of type record. :)

Thanks for this request!
Title: Re: Custom fields and filters of post
Post by: Americano on July 13, 2015, 11:33:03 PM
hi

I'm doing a custom fields. However, all fields are in one column in filter and index.  This makes occupy a large space.  :'(

I can not get the search filter with the fields in the same line like the figure.

Note: The fields are in the same group

How do I get the fields on the same line like  figure of example.
Title: Re: Custom fields and filters of post
Post by: davidhs on July 14, 2015, 08:21:49 AM
hi

I'm doing a custom fields. However, all fields are in one column in filter and index.  This makes occupy a large space.  :'(

I can not get the search filter with the fields in the same line like the figure.

Note: The fields are in the same group

How do I get the fields on the same line like  figure of example.
Attach an image of your filters. And other image with you want to see. :)
Title: Re: Custom fields and filters of post
Post by: Americano on July 14, 2015, 02:40:58 PM
hi

I'm doing a custom fields. However, all fields are in one column in filter and index.  This makes occupy a large space.  :'(

I can not get the search filter with the fields in the same line like the figure.

Note: The fields are in the same group

How do I get the fields on the same line like  figure of example.
Attach an image of your filters. And other image with you want to see. :)

Attach an image of my filters - suporte1

And other image with I want to see - suporte2




Title: Re: Custom fields and filters of post
Post by: davidhs on July 15, 2015, 07:38:44 AM
hi

I'm doing a custom fields. However, all fields are in one column in filter and index.  This makes occupy a large space.  :'(

I can not get the search filter with the fields in the same line like the figure.

Note: The fields are in the same group

How do I get the fields on the same line like  figure of example.
Attach an image of your filters. And other image with you want to see. :)

Attach an image of my filters - suporte1

And other image with I want to see - suporte2
This problem is about CSS. But... both images use same forum and same theme?

If yes, I do not know cause.

If no, you can view these files
FORUM/Themes/default/css/index.css
FORUM/Themes/your_theme/css/index.css

and search at end of files
Code: [Select]
/* BEGIN MOD CustomFieldFilterPost */
...
/* END MOD CustomFieldFilterPost */

Both files must have "display: inline;" on this code (this write filters of message index in only one line):
Code: [Select]
form#cffp_filters div.cffp_filters,
form#cffp_filters div.cffp_filters dl,
form#cffp_filters div.cffp_filters dt
{
display: inline;
}
form#cffp_filters div.cffp_filters dd,
form#cffp_filters div.cffp_filters_button
{
display: inline;
margin-left: 0;
margin-right: 1em;
}
Title: Re: Custom fields and filters of post
Post by: Americano on July 15, 2015, 05:25:40 PM
I uninstalled the mod and then install again. Now it is working like figure 2.  :)

I do not set anything different
Title: Re: Custom fields and filters of post
Post by: davidhs on July 16, 2015, 06:41:43 AM
I uninstalled the mod and then install again. Now it is working like figure 2.  :)

I do not set anything different
Problem solved. :)
Perhaps an error occured on your last installation.  :o
Title: Re: Custom fields and filters of post
Post by: davidhs on October 01, 2015, 06:13:16 PM
Compatible with SMF 2.0.11.
Title: Re: Custom fields and filters of post
Post by: Westwegoman on November 05, 2015, 11:02:38 PM
hi

I'm doing a custom fields. However, all fields are in one column in filter and index.  This makes occupy a large space.  :'(

I can not get the search filter with the fields in the same line like the figure.

Note: The fields are in the same group

How do I get the fields on the same line like  figure of example.
Attach an image of your filters. And other image with you want to see. :)

Attach an image of my filters - suporte1

And other image with I want to see - suporte2
This problem is about CSS. But... both images use same forum and same theme?

If yes, I do not know cause.

If no, you can view these files
FORUM/Themes/default/css/index.css
FORUM/Themes/your_theme/css/index.css

and search at end of files
Code: [Select]
/* BEGIN MOD CustomFieldFilterPost */
...
/* END MOD CustomFieldFilterPost */

Both files must have "display: inline;" on this code (this write filters of message index in only one line):
Code: [Select]
form#cffp_filters div.cffp_filters,
form#cffp_filters div.cffp_filters dl,
form#cffp_filters div.cffp_filters dt
{
display: inline;
}
form#cffp_filters div.cffp_filters dd,
form#cffp_filters div.cffp_filters_button
{
display: inline;
margin-left: 0;
margin-right: 1em;
}

I've looked in both css files and they both have display: inline;.

In the SMF default theme it shows correct so I assume it has something to do with the theme I am using. (Blackjack by Crip)

Any idea what could cause this?
Title: Re: Custom fields and filters of post
Post by: davidhs on November 06, 2015, 06:46:29 AM
hi

I'm doing a custom fields. However, all fields are in one column in filter and index.  This makes occupy a large space.  :'(

I can not get the search filter with the fields in the same line like the figure.

Note: The fields are in the same group

How do I get the fields on the same line like  figure of example.
Attach an image of your filters. And other image with you want to see. :)

Attach an image of my filters - suporte1

And other image with I want to see - suporte2
This problem is about CSS. But... both images use same forum and same theme?

If yes, I do not know cause.

If no, you can view these files
FORUM/Themes/default/css/index.css
FORUM/Themes/your_theme/css/index.css

and search at end of files
Code: [Select]
/* BEGIN MOD CustomFieldFilterPost */
...
/* END MOD CustomFieldFilterPost */

Both files must have "display: inline;" on this code (this write filters of message index in only one line):
Code: [Select]
form#cffp_filters div.cffp_filters,
form#cffp_filters div.cffp_filters dl,
form#cffp_filters div.cffp_filters dt
{
display: inline;
}
form#cffp_filters div.cffp_filters dd,
form#cffp_filters div.cffp_filters_button
{
display: inline;
margin-left: 0;
margin-right: 1em;
}

I've looked in both css files and they both have display: inline;.

In the SMF default theme it shows correct so I assume it has something to do with the theme I am using. (Blackjack by Crip)

Any idea what could cause this?
I installed this theme (Blackjack) in my test forum and then I installed my mod, and works. Your theme is not the problem, I think!

When you installed my mod, had you checked your theme, at end of page? (See my attach image, blue rectangle at bottom.)
Title: Re: Custom fields and filters of post
Post by: Westwegoman on November 06, 2015, 06:54:04 AM
Yes. I looked in the index.css file and the edits were made.

When I switch to the default theme, it all looks right.
Title: Re: Custom fields and filters of post
Post by: davidhs on November 06, 2015, 08:14:43 AM
Yes. I looked in the index.css file and the edits were made.

When I switch to the default theme, it all looks right.
Perhaps another mod modify something...

Can you attach here your index.css of Black Jack theme?
Title: Re: Custom fields and filters of post
Post by: Westwegoman on November 06, 2015, 08:34:55 AM
Ok. I will attach it tonight when I get home. Thanks in advance.
Title: Re: Custom fields and filters of post
Post by: Westwegoman on November 06, 2015, 07:30:27 PM

Perhaps another mod modify something...

Can you attach here your index.css of Black Jack theme?

Here it is.
Title: Re: Custom fields and filters of post
Post by: davidhs on November 07, 2015, 06:15:15 AM

Perhaps another mod modify something...

Can you attach here your index.css of Black Jack theme?

Here it is.
You have an error on your index.css file! Perhaps was added for another mod...

Search (line 2726)
Code: [Select]
input:focus, textarea:focus, button:focus, select:focus {
border: solid 1px #FFD700;
.seperate {
Replace by
Code: [Select]
input:focus, textarea:focus, button:focus, select:focus {
border: solid 1px #FFD700;
}
.seperate {



By another hand, you have installed version 1.1 of my mod, and the latest version is 1.3.2. I added many enhancements. You can install current version (1.3.2), or wait some days/weeks because I will update to 1.4 soon (with more enhancements).
Title: Re: Custom fields and filters of post
Post by: Westwegoman on November 07, 2015, 07:31:16 AM
Thanks.

I never did update due to the errors when using the package manager. When I installed it originally, I had to do a lot of manual edits, mostly from other mods.
Title: Re: Custom fields and filters of post
Post by: davidhs on November 07, 2015, 07:38:51 AM
I never did update due to the errors when using the package manager. When I installed it originally, I had to do a lot of manual edits, mostly from other mods.
Yes, I know this. It is a problem of SMF's modifications. :(

But I recommend to you install version 1.4 when I upload. It will have many enhancements.
Title: Re: Custom fields and filters of post
Post by: Westwegoman on November 08, 2015, 10:52:40 AM
Ok. Thanks, the fix you provided worked.
Title: Re: Custom fields and filters of post
Post by: davidhs on November 11, 2015, 03:31:17 PM
is it could have top?

You can make a top 10 rank of the custom fields.  :-X
Done.



New versión:
Code: [Select]
1.4     2015-10-30
------------------
+ Field in administration panel to show, on the statistics, the top 10 posters of each type of records.
+ The total number of each type of record created can be show on the statistics.
+ SMF compatibility: 2.0.11.
+ Languages: New language string in portuguese_brazilian, portuguese_brazilian-utf8, brazilian, brazilian-utf8, portuguese_pt, portuguese_pt-utf8, thanks to Americano.
+ Languages: german, german-utf8, german_informal, german_informal-utf8, thanks to sangham.net.
- SMF 2.0.x: Languages: brazilian, brazilian-utf8, spanish, spanish-utf8 (these are not used).
Title: Re: Custom fields and filters of post
Post by: Americano on November 11, 2015, 05:50:36 PM
Please

How do i install the new version without uninstalling the old version?
Title: Re: Custom fields and filters of post
Post by: davidhs on November 11, 2015, 06:20:43 PM
Please

How do i install the new version without uninstalling the old version?
It it not possible. You must uninstall the old version (without to delete user data!) and then install the new version.
Title: Re: Custom fields and filters of post
Post by: Americano on November 11, 2015, 06:26:30 PM
I managed to uninstall. It installed perfectly !. It was excellent.

I was not getting uninstall.

I uninstall the "Enhancements to recent posts" and then went uninstall the Custom fields and filters of post and functioned normally.

Thank You very much!
Title: Re: Custom fields and filters of post
Post by: davidhs on November 12, 2015, 05:34:19 AM
I was not getting uninstall.

I uninstall the "Enhancements to recent posts" and then went uninstall the Custom fields and filters of post and functioned normally.
This is a problem of SMF mods in SMF 2.0.x :(

All my mods adds a line in copyright section (Sources/Who.php) and must be uninstalled in reverse order than they was installed... or, if you know PHP you can edit this file and to move this line at beginning of copyright section.
Title: Re: Custom fields and filters of post
Post by: moyack on February 07, 2016, 04:02:56 PM
Hi:

I'm still using this mod and I have a lot of faith with it. Now I'm working with a simple thing that is used as a thread categorization item, like a kind of tag. I'm using a combo boz where users can select the status of a thread, like assigned, confirmed, approved, finished and closed.

I've applied the example from the first post of this topic with "fields with several values per member" and I only placed a field with a combo box.

The issue is that when I select an option and I confirm, it doesn't work. it doesn't set the option at all. I'm pretty sure I missed something but I don't know which option is the cause of the failure.

Any help will be really appreciated. Thanks.
Title: Re: Custom fields and filters of post
Post by: davidhs on February 08, 2016, 06:22:30 AM
Hi:

I'm still using this mod and I have a lot of faith with it. Now I'm working with a simple thing that is used as a thread categorization item, like a kind of tag. I'm using a combo boz where users can select the status of a thread, like assigned, confirmed, approved, finished and closed.

I've applied the example from the first post of this topic with "fields with several values per member" and I only placed a field with a combo box.

The issue is that when I select an option and I confirm, it doesn't work. it doesn't set the option at all. I'm pretty sure I missed something but I don't know which option is the cause of the failure.

Any help will be really appreciated. Thanks.
I think you want the owner of a thread/topic (or moderator/admin; but not any user) sets the status of him topic. Correct?

You need a group of fields type "fields loose". In a group type "fields with several values per member" several members can insert different values (this can be used for insert comments, opinions....)

This group of field contain only one field, named "Status", a list box with options (assigned, confirmed, approved, finished, closed). If these are all values, the list box must be type "select box". A "combo box" is a "select box" + "text box" and users can select an option of select box or write a new option in text box.

Can be, a topic, to have status without value? If not, select "Not empty value" in field settings.
 
About the group, unselect "Show on the replies of topic" (only must be seen on first post).

About permissions of group and field:
- View: all
- Modify: owner, moderators, admin.
- Filter: all (if you want filter topics by status).
- Search: all (if you want search topics by status).
Title: Re: Custom fields and filters of post
Post by: moyack on March 22, 2016, 05:11:08 PM
Hi:

I'm still using this mod and I have a lot of faith with it. Now I'm working with a simple thing that is used as a thread categorization item, like a kind of tag. I'm using a combo boz where users can select the status of a thread, like assigned, confirmed, approved, finished and closed.

I've applied the example from the first post of this topic with "fields with several values per member" and I only placed a field with a combo box.

The issue is that when I select an option and I confirm, it doesn't work. it doesn't set the option at all. I'm pretty sure I missed something but I don't know which option is the cause of the failure.

Any help will be really appreciated. Thanks.
I think you want the owner of a thread/topic (or moderator/admin; but not any user) sets the status of him topic. Correct?

You need a group of fields type "fields loose". In a group type "fields with several values per member" several members can insert different values (this can be used for insert comments, opinions....)

This group of field contain only one field, named "Status", a list box with options (assigned, confirmed, approved, finished, closed). If these are all values, the list box must be type "select box". A "combo box" is a "select box" + "text box" and users can select an option of select box or write a new option in text box.

Can be, a topic, to have status without value? If not, select "Not empty value" in field settings.
 
About the group, unselect "Show on the replies of topic" (only must be seen on first post).

About permissions of group and field:
- View: all
- Modify: owner, moderators, admin.
- Filter: all (if you want filter topics by status).
- Search: all (if you want search topics by status).
My apologies for a veeeerrry late answer, but I want to let you know that your suggestion served me pretty well. I've done a lot of make up using the template feature and now I can show the post in the message index nicely.

Just one question: I've added a rate system. one thing I've noticed is that the first rate should be done twice in order to register the score properly. And second, if I try to apply a template, it doesn't show in the message index. Is the template feature disabled for the group "Fields with several values per member"?

again, thanks for this mod and big HUGS!!!
Title: Re: Custom fields and filters of post
Post by: davidhs on March 23, 2016, 12:59:02 PM
Just one question: I've added a rate system. one thing I've noticed is that the first rate should be done twice in order to register the score properly.
In my test forum this works. When I submit a rate, this is registered.  ???  Can you tell me your steps with images?

And second, if I try to apply a template, it doesn't show in the message index. Is the template feature disabled for the group "Fields with several values per member"?
Template works with this type of group (in message and in the message index).

If you has defined a template in the message index you must use tags in order to insert statistical data (you can see these tags in help button of the field template) but template must be written in PHP code.
Quote
In PHP you can also use the following functions:
  • {SHOW_GROUP_MSG}(message_ID, group_ID) - Displays the group of a message like in a message.
  • {SHOW_GROUP_MSGINDEX}(message_ID, group_ID) - Displays the group of a message like on the message index.
  • {SHOW_GROUP_MSG_STATS}(message_ID, group_ID, 'type', 'params') - Displays the statistics for the group of a message (if are activated). The parameter type can be:
    • chart_average - Displays the chart with average. The parameter params indicates chart characteristics. Permitted values: average (shown average value), minmax (shown lowest and highest allowed value), options_text (shown the text of options).
    • chart_hbars - Displays the chart with horizontal bars. The parameter params is not used.
    • chart_vbars - Displays the chart with vertical bars. The parameter params indicates chart characteristics. Permitted values: options_text (shown the text of options).
    • summary - Displays the summary. The parameter params indicates values to display, comma separated. Permitted values: average (average value), max (highest allowed value), min (lowest allowed value), highest (highest used value), lowest (lowest used value), most_frequent (most frequent value), least_frequent (least frequent value), total (total).
    • value - Displays a value of the summary. The parameter params indicates value to display. Permitted values: average (average value), max (highest allowed value), min (lowest allowed value), highest (highest used value), lowest (lowest used value), most_frequent (most frequent value), least_frequent (least frequent value), total (total).

For example, if group ID is 13 and you write this on template:
Code: [Select]
echo 'AVERAGE CHART';
{SHOW_GROUP_MSG_STATS}({ID_MSG}, 13, 'chart_average');
echo 'AVERAGE VALUE = ';
{SHOW_GROUP_MSG_STATS}({ID_MSG}, 13, 'value', 'average');
You see average chart and value.

But this is displayed instead of user rates (if you see various user rate, you will see average data repeated).

Really, I added these function for be used in others groups of fields. For example you have a group of fields "hero of video game" with fields image, type and category. In its template of the index message you wrote some like this:
Code: [Select]
<table><tr>
<td style="width: 100px;"><a href="..."> image </a></td>
<td><strong>Model Type:</strong> type<br>
<strong>Model Category:</strong> category</td>
</tr></table>
You can add here statistical data functions.
Title: Re: Custom fields and filters of post
Post by: moyack on March 27, 2016, 01:54:34 AM
In my test forum this works. When I submit a rate, this is registered.  ???  Can you tell me your steps with images?
Sure, here it is:
1. I've created a new topic, in this case is a resource model. I've set some fields so it can describe the topic properly.
(http://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=247379)

    Edit mode...
(http://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=247381)

2. Before the updates to the custom fields, I had to set twice the value in order to get it registered and visible, now when I select into the rating the option in the select box, it doesn't update the score, I've tried many times and in fact it's storing the ratings, but not the value. Check image below
(http://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=247389)


3. Here's the configuration of these fields...
(http://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=247383)

(http://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=247385)

(http://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=247387)



Quote
Template works with this type of group (in message and in the message index).

If you has defined a template in the message index you must use tags in order to insert statistical data (you can see these tags in help button of the field template) but template must be written in PHP code.
Quote
In PHP you can also use the following functions:
  • {SHOW_GROUP_MSG}(message_ID, group_ID) - Displays the group of a message like in a message.
  • {SHOW_GROUP_MSGINDEX}(message_ID, group_ID) - Displays the group of a message like on the message index.
  • {SHOW_GROUP_MSG_STATS}(message_ID, group_ID, 'type', 'params') - Displays the statistics for the group of a message (if are activated). The parameter type can be:
    • chart_average - Displays the chart with average. The parameter params indicates chart characteristics. Permitted values: average (shown average value), minmax (shown lowest and highest allowed value), options_text (shown the text of options).
    • chart_hbars - Displays the chart with horizontal bars. The parameter params is not used.
    • chart_vbars - Displays the chart with vertical bars. The parameter params indicates chart characteristics. Permitted values: options_text (shown the text of options).
    • summary - Displays the summary. The parameter params indicates values to display, comma separated. Permitted values: average (average value), max (highest allowed value), min (lowest allowed value), highest (highest used value), lowest (lowest used value), most_frequent (most frequent value), least_frequent (least frequent value), total (total).
    • value - Displays a value of the summary. The parameter params indicates value to display. Permitted values: average (average value), max (highest allowed value), min (lowest allowed value), highest (highest used value), lowest (lowest used value), most_frequent (most frequent value), least_frequent (least frequent value), total (total).

For example, if group ID is 13 and you write this on template:
Code: [Select]
echo 'AVERAGE CHART';
{SHOW_GROUP_MSG_STATS}({ID_MSG}, 13, 'chart_average');
echo 'AVERAGE VALUE = ';
{SHOW_GROUP_MSG_STATS}({ID_MSG}, 13, 'value', 'average');
You see average chart and value.

But this is displayed instead of user rates (if you see various user rate, you will see average data repeated).

Really, I added these function for be used in others groups of fields. For example you have a group of fields "hero of video game" with fields image, type and category. In its template of the index message you wrote some like this:
Code: [Select]
<table><tr>
<td style="width: 100px;"><a href="..."> image </a></td>
<td><strong>Model Type:</strong> type<br>
<strong>Model Category:</strong> category</td>
</tr></table>
You can add here statistical data functions.
AHHHHH!!! I seeeeeeeeee!!!!! you don't have to put the <php? /?> tags....

That solved my issue, now as you can see, I've been able to inject the average into the field. It really looks nice. THANKS FOR THE ADVICE!!!!
(http://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=247391)

Just one question: it's possible to get in the ratings the numerical values, this in order to do some calculation in php with the values (like showing stars for ratings instead a number)... thanks.
Title: Re: Custom fields and filters of post
Post by: davidhs on March 27, 2016, 08:25:29 AM
In my test forum this works. When I submit a rate, this is registered.  ???  Can you tell me your steps with images?
Sure, here it is:
1. I've created a new topic, in this case is a resource model. I've set some fields so it can describe the topic properly.
    Edit mode...
2. Before the updates to the custom fields, I had to set twice the value in order to get it registered and visible, now when I select into the rating the option in the select box, it doesn't update the score, I've tried many times and in fact it's storing the ratings, but not the value. Check image below
3. Here's the configuration of these fields...
Sorry, I do not see any mistake :-\
I can login in your forum and test this... Can you create a test user in your forum and send login/password by PM?

Some comments:

1. In group WC3 Models, field Keywords is a text button. User can write here keywords comma separated, but he can write
Code: [Select]
undead, knight, demonor a mistake
Code: [Select]
unndead, knight, demon
You can define this field as a combo box with multiple selections. ;)

2. In group Rating, field Score is a select box button with options 1, 2, 3, 4, 5 (only numbers, without text).
Code: [Select]
( ) 1_______________ Text  _________________________
( ) 2_______________ Text  _________________________
( ) 3_______________ Text  _________________________
( ) 4_______________ Text  _________________________
( ) 5_______________ Text  _________________________
You can write on fields text of each option this
Code: [Select]
( ) 1_______________ Text  Bad resource
( ) 2_______________ Text  Below average resource
( ) 3_______________ Text  Average resource
( ) 4_______________ Text  Bad resource
( ) 5_______________ Text  Excellent or very useful resource
or
Code: [Select]
( ) 1_______________ Text  1 - Bad resource
( ) 2_______________ Text  2 - Below average resource
( ) 3_______________ Text  3 - Average resource
( ) 4_______________ Text  4 - Bad resource
( ) 5_______________ Text  5 - Excellent or very useful resource
And then users view a select box with these text instead of numbers.

3. In group Rating, field Score, templates text are
Code: [Select]
<div></div>I do not undestand why you wrote this. Templates can be empty.

Template works with this type of group (in message and in the message index).

If you has defined a template in the message index you must use tags in order to insert statistical data (you can see these tags in help button of the field template) but template must be written in PHP code.
Quote
In PHP you can also use the following functions:
  • {SHOW_GROUP_MSG}(message_ID, group_ID) - Displays the group of a message like in a message.
  • {SHOW_GROUP_MSGINDEX}(message_ID, group_ID) - Displays the group of a message like on the message index.
  • {SHOW_GROUP_MSG_STATS}(message_ID, group_ID, 'type', 'params') - Displays the statistics for the group of a message (if are activated). The parameter type can be:
    • chart_average - Displays the chart with average. The parameter params indicates chart characteristics. Permitted values: average (shown average value), minmax (shown lowest and highest allowed value), options_text (shown the text of options).
    • chart_hbars - Displays the chart with horizontal bars. The parameter params is not used.
    • chart_vbars - Displays the chart with vertical bars. The parameter params indicates chart characteristics. Permitted values: options_text (shown the text of options).
    • summary - Displays the summary. The parameter params indicates values to display, comma separated. Permitted values: average (average value), max (highest allowed value), min (lowest allowed value), highest (highest used value), lowest (lowest used value), most_frequent (most frequent value), least_frequent (least frequent value), total (total).
    • value - Displays a value of the summary. The parameter params indicates value to display. Permitted values: average (average value), max (highest allowed value), min (lowest allowed value), highest (highest used value), lowest (lowest used value), most_frequent (most frequent value), least_frequent (least frequent value), total (total).

For example, if group ID is 13 and you write this on template:
Code: [Select]
echo 'AVERAGE CHART';
{SHOW_GROUP_MSG_STATS}({ID_MSG}, 13, 'chart_average');
echo 'AVERAGE VALUE = ';
{SHOW_GROUP_MSG_STATS}({ID_MSG}, 13, 'value', 'average');
You see average chart and value.

But this is displayed instead of user rates (if you see various user rate, you will see average data repeated).

Really, I added these function for be used in others groups of fields. For example you have a group of fields "hero of video game" with fields image, type and category. In its template of the index message you wrote some like this:
Code: [Select]
<table><tr>
<td style="width: 100px;"><a href="..."> image </a></td>
<td><strong>Model Type:</strong> type<br>
<strong>Model Category:</strong> category</td>
</tr></table>
You can add here statistical data functions.
AHHHHH!!! I seeeeeeeeee!!!!! you don't have to put the <php? /?> tags....
If template type is PHP you can put <php? /?> tags or not. ;)
If template type is not PHP and you put <php? /?> tags, system do not read this as PHP, else HTML or BBC (as template type field) :D

Just one question: it's possible to get in the ratings the numerical values, this in order to do some calculation in php with the values (like showing stars for ratings instead a number)... thanks.
Yes ;)

In templates of the message index you can use this function in order to insert average value:
Code: [Select]
{SHOW_GROUP_MSG_STATS}(ID_MSG, ID_GROUP, 'value', 'average');
Now, you want get this value (not display) and display stars instead of number. You can use PHP function for this: ob_start(), ob_get_contents() and ob_end_clean().
PHP code can be
Code: [Select]
<?php

$id_group 
5// ID of your group with statistical data.

// Display average value.
echo '<br />Average value = ';
{
SHOW_GROUP_MSG_STATS}({ID_MSG}, $id_group'value''average');

// Saves average value in $avg var.
ob_start();
{
SHOW_GROUP_MSG_STATS}({ID_MSG}, $id_group'value''average');
$avg ob_get_contents();
ob_end_clean();

// Display stars.
$img_star '<img src="..." alt="*" />';
echo 
'<br />Average with stars = '$avg' = ';
for (
$i 0$i $avg$i++)
echo $img_star;

echo 
'<br />';

?>
Title: Re: Custom fields and filters of post
Post by: moyack on April 04, 2016, 12:36:45 AM
The issue with the group field of type "fields with several values per member" that it was not registering the values submitted by the users was already solved. It was caused by the conflict with a SEF mod which rewrites the standard URLs with nice ones. In my case I use in my forum Search Engine Friendly URL (SEF) Manager from PortaMX and the solution was to add in the "actions to be ignored" field this ones: cffpeditgroup and cffpsearch.

Just for the record. And thanks to Davidhs for his great support in finding the issue. BIG HUGS!!!
Title: Re: Custom fields and filters of post
Post by: moyack on April 23, 2016, 09:16:09 PM
Hi again:

I've been tinkering with this mod and I'm enjoying how well the customization is evolving. Right now I has some small questions about some related things about this mod:

The custom fields work perfectly, but now I want to show them into custom blocks in my portal. right now I have in my site at the homepage custom blocks that shows the post content from some boards with custom fields, but I want to add the fields with the template designed for each of them. I've seen this functions in display.template.php called
cffpLoad
, but I'm not sure how to use it. An example could come handy to get the idea about how it works.

Thanks :D

Title: Re: Custom fields and filters of post
Post by: davidhs on April 24, 2016, 11:30:57 AM
The custom fields work perfectly, but now I want to show them into custom blocks in my portal. right now I have in my site at the homepage custom blocks that shows the post content from some boards with custom fields, but I want to add the fields with the template designed for each of them. I've seen this functions in display.template.php called
cffpLoad
, but I'm not sure how to use it. An example could come handy to get the idea about how it works.
I an out from home and now I can not write code.

My mod have not functions for display groups of fields in blocks of portal. cffpLoad is a private function.

But you can create a block of PHP code (if your portal have this) and use tags/functions {...}(id_group, id_msg,...) in order to display templates.
Title: SQL Error when trying to install
Post by: vjones on August 02, 2016, 12:26:54 PM
The error I get is:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
 WHERE active = 1
 ORDER BY group_order ASC' at line 2
File: C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php
Line: 43

it looks like database_2.0.php isn't getting run on install
Title: Re: Custom fields and filters of post
Post by: davidhs on August 03, 2016, 06:29:07 AM
The error I get is:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
 WHERE active = 1
 ORDER BY group_order ASC' at line 2
File: C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php
Line: 43

it looks like database_2.0.php isn't getting run on install
Are you install the last version of this mod?

Sorry, I do not know why you have this error...
Can you attach here your file C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php ?
Can you see the schema of table smf_cffp_settings_groups? What are its columns?
Title: Re: Custom fields and filters of post
Post by: vjones on August 03, 2016, 10:55:36 AM
I am installing the most recent version using the package manager built in the SMF. My install process was to input the url to download ( http://custom.simplemachines.org/mods/index.php?action=download;mod=3818;id=245288 ) and the name of the mod ( Custom fields and filters of post ) and then I get MySql errors. Additionally I have not been able to find a way to this plugin in the browse section of the package manager. I was able to find the plugin, but download was not an option.


The error I get is:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
 WHERE active = 1
 ORDER BY group_order ASC' at line 2
File: C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php
Line: 43

it looks like database_2.0.php isn't getting run on install
Are you install the last version of this mod?

Sorry, I do not know why you have this error...
Can you attach here your file C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php ?
Can you see the schema of table smf_cffp_settings_groups? What are its columns?
Title: Re: Custom fields and filters of post
Post by: davidhs on August 04, 2016, 07:45:01 AM
The error I get is:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
 WHERE active = 1
 ORDER BY group_order ASC' at line 2
File: C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php
Line: 43

it looks like database_2.0.php isn't getting run on install
Are you install the last version of this mod?

Sorry, I do not know why you have this error...
Can you attach here your file C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php ?
Can you see the schema of table smf_cffp_settings_groups? What are its columns?
I am installing the most recent version using the package manager built in the SMF. My install process was to input the url to download ( http://custom.simplemachines.org/mods/index.php?action=download;mod=3818;id=245288 ) and the name of the mod ( Custom fields and filters of post ) and then I get MySql errors. Additionally I have not been able to find a way to this plugin in the browse section of the package manager. I was able to find the plugin, but download was not an option.
If you have MySQL errrors during install process... perhaps you have an error in your forum... I do not know...

You can try search my mod with your forum:
1. Go to package section of your forum (Administration Center > Package Manager > Download Packages > Download New Packages > Package server):
2. Clic on [ Browse ] of server "Simple Machines Third-party Mod Site".
3. Clic on  New Feature > View the 2xx mods in this section.
4. Search my mod, Custom fields and filters of post, and clic on [ Download ].
5. This copy my mod on your server. Clic on install.

This process can fail because are many mods.

You can try download from SMF site, upload to your forum and install:
1. Visit download page http://custom.simplemachines.org/mods/index.php?action=download;mod=3818;id=245288 in your explorer/navigator.
2. Clic on CustomFieldFilterPost_1.4.tar.gz and download to your disk.
3. Go to package section of your forum (Administration Center > Package Manager > Download Packages > Upload a Package).
4. Upload file CustomFieldFilterPost_1.4.tar.gz
5. Install mod if there are not errors.

I hope you can install my mod without errors!
Title: Re: Custom fields and filters of post
Post by: vjones on August 05, 2016, 11:44:46 AM
The error I get is:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
 WHERE active = 1
 ORDER BY group_order ASC' at line 2
File: C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php
Line: 43

it looks like database_2.0.php isn't getting run on install
Are you install the last version of this mod?

Sorry, I do not know why you have this error...
Can you attach here your file C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php ?
Can you see the schema of table smf_cffp_settings_groups? What are its columns?
I am installing the most recent version using the package manager built in the SMF. My install process was to input the url to download ( http://custom.simplemachines.org/mods/index.php?action=download;mod=3818;id=245288 ) and the name of the mod ( Custom fields and filters of post ) and then I get MySql errors. Additionally I have not been able to find a way to this plugin in the browse section of the package manager. I was able to find the plugin, but download was not an option.
If you have MySQL errrors during install process... perhaps you have an error in your forum... I do not know...

You can try search my mod with your forum:
1. Go to package section of your forum (Administration Center > Package Manager > Download Packages > Download New Packages > Package server):
2. Clic on [ Browse ] of server "Simple Machines Third-party Mod Site".
3. Clic on  New Feature > View the 2xx mods in this section.
4. Search my mod, Custom fields and filters of post, and clic on [ Download ].
5. This copy my mod on your server. Clic on install.

This process can fail because are many mods.

You can try download from SMF site, upload to your forum and install:
1. Visit download page http://custom.simplemachines.org/mods/index.php?action=download;mod=3818;id=245288 in your explorer/navigator.
2. Clic on CustomFieldFilterPost_1.4.tar.gz and download to your disk.
3. Go to package section of your forum (Administration Center > Package Manager > Download Packages > Upload a Package).
4. Upload file CustomFieldFilterPost_1.4.tar.gz
5. Install mod if there are not errors.

I hope you can install my mod without errors!

I'll see what I can do. For reference I am working off of a fresh install of SMF no other mods are installed and no Topics or Posts have been written yet. A couple of users have been created but thats it.
Title: Re: Custom fields and filters of post
Post by: davidhs on October 12, 2016, 03:32:35 PM
Compatible with SMF 2.0.12.
Title: Re: Custom fields and filters of post
Post by: aegersz on October 12, 2016, 04:10:58 PM
what an amazing mod !
Title: Re: Custom fields and filters of post
Post by: davidhs on January 12, 2017, 04:06:03 PM
Compatible with SMF 2.0.13.
Title: Re: Custom fields and filters of post
Post by: Americano on June 16, 2017, 11:20:32 AM
Hello
I have a question.

A member of my forum, posted a message, but forgot to post the custom field. After a message has been posted, as a rule, only the moderator or administrator can post the custom field for that member in the same message, but this custom field is not computed for the member and, yes, for which he launched the custom field, in the case the moderator or administrator.

How do I make the custom field be computed to whoever posted the message?
Title: Re: Custom fields and filters of post
Post by: davidhs on June 16, 2017, 04:52:03 PM
How do I make the custom field be computed to whoever posted the message?
You can add one permission to this group of fields: Owner of post (or Owner of group, if group type is "Fields with several values per member") --> Modify
Title: Re: Custom fields and filters of post
Post by: thepitster on August 01, 2017, 11:57:16 PM
right after I installed this mod
PHP Parse error:  syntax error, unexpected 'global' (T_GLOBAL) in /Themes/default/languages/Modifications.english.php on line 600
line 600 is global $forum_version;
now I dunno what is up

SMF 2.0.14

EDIT: I removed the entire bottom block in Modification.english.php, my Modifications.english-utf8.php had the exact same thing at the bottom and no errors, and Yes I am using UTF-8
Title: Re: Custom fields and filters of post
Post by: davidhs on August 02, 2017, 06:42:41 AM
right after I installed this mod
PHP Parse error:  syntax error, unexpected 'global' (T_GLOBAL) in /Themes/default/languages/Modifications.english.php on line 600
line 600 is global $forum_version;
now I dunno what is up

SMF 2.0.14

EDIT: I removed the entire bottom block in Modification.english.php, my Modifications.english-utf8.php had the exact same thing at the bottom and no errors, and Yes I am using UTF-8
Perhaps is your PHP version... I do not know...

Works fine all now?

If no, you can to do this: At beginning of my block of strings, search
Code: [Select]
global $forum_version;
$smf_version_1 = 0 === strpos($forum_version, 'SMF 1');
and replace by
Code: [Select]
$smf_version_1 = false;
Title: Re: Custom fields and filters of post
Post by: thepitster on August 02, 2017, 01:46:26 PM
after your suggestion:
PHP Parse error:  syntax error, unexpected '$smf_version_1' (T_VARIABLE) in /Themes/default/languages/Modifications.english.php on line 602

like I said if I remove ALL the code that was placed into Modifications.english.php, and leave the code that was placed into Modifications.english-utf8.php every thing appears to still work so.
Title: Re: Custom fields and filters of post
Post by: thepitster on August 02, 2017, 05:11:00 PM
 I am so Sorry, this had NOTHING to do with your mod at all, instead I have to go find another mod author and give him a lesson in PHP like "DO NOT FORGET YOUR ;'s THEY ARE IMPORTANT!", the last mod I installed forgot a semicolon at the end and it was causing every mod to do this.

sorry again for troubles.
Title: Re: Custom fields and filters of post
Post by: thepitster on August 02, 2017, 09:55:39 PM
oh yeah I did find one edit

Code: (modification-2.0.2-2.0.99.xml Line 1540) [Select]
echo '
<!-- END MOD CustomFieldFilterPost -->
you forgot the ' at the end of line 1541 like this
Code: [Select]
echo '
<!-- END MOD CustomFieldFilterPost -->'
other wise it breaks anything to do with the Profile page.

other than that this mod IS FREAKING AWESOME!!!!!! since they are picky about certain mods here being developed, this and 2 or 3 other mods is helping us achieve this goal, YOU SIR ARE A GENIUS!!!
Title: Re: Custom fields and filters of post
Post by: davidhs on August 03, 2017, 06:49:03 AM
Sorry, I forgot this: your forum is SMF 2.0.14 and my mod was tested up to 2.0.13.
SMF 2.0.14 need PHP 5.4 and my server has PHP 5.3.8. At this moment, I can not tested my mods in SMF 2.0.14, sorry. :(
Title: Re: Custom fields and filters of post
Post by: Americano on August 15, 2017, 05:38:40 PM
Hello

Please, I wanted a modification.

I have a Custom field in my forum and have an evaluation on the form with "positive" "negative" and "neutral" options and I wanted when it was positive, it would have 1 point in the index of the topic and when it was negative it would lose 1 point.

If the topic custom form had 4 positive and 1 negative, the topic index would be +3.

It would be possible?
Title: Re: Custom fields and filters of post
Post by: davidhs on August 18, 2017, 02:16:27 PM
Hello

Please, I wanted a modification.

I have a Custom field in my forum and have an evaluation on the form with "positive" "negative" and "neutral" options and I wanted when it was positive, it would have 1 point in the index of the topic and when it was negative it would lose 1 point.

If the topic custom form had 4 positive and 1 negative, the topic index would be +3.

It would be possible?
I suppose
- your group is type "fields with several values per member",
- you have an only one field (type select box or radio buttons, with "positive", "negative" and "neutral" options)

Is better you create options with value and text:
Quote
1 -- positive
-1 -- negative
0 -- neutral

You want show statistical data of this field, but now you can show only
- Average value
- Highest allowed value
- Lowest allowed value
- Highest used value
- Lowest used value
- Most frequent value
- Least frequent value
- Total (this is number of answers)

You need another data (sum) but this not exist. I will see if I can add in next upgrade. Now you can use average value: If the topic custom form had 4 positive and 1 negative, the average value is 0.60 ( (1+1+1+1-1) / 5; values between -1 and 1).

Also, you can define your options
Quote
10 -- positive
0 -- negative
5 -- neutral
and the average value is 8.00 ( (10+10+10+10+0) / 5; values between 0 and 10).
Title: Re: Custom fields and filters of post
Post by: thepitster on September 06, 2017, 01:51:46 AM
hey man from time to time this keeps popping up in my server error_log:
Code: (error_log) [Select]
PHP Fatal error:  Call to undefined function template_cffp_show() in /Sources/Load.php(2291) : eval()'d code on line 507and line 2291 of Load.php:
Code: (Load.php:(2291)) [Select]
$file_found = file_exists($filename) && eval('?' . '>' . rtrim(file_get_contents($filename))) !== false;
now I am assuming it means line 507 in Profile.template.php:
Code: (Profile.template.php:(507)) [Select]
template_cffp_show('display_readonly');
hopefully not a SMF 2.0.14 problem?
Title: Re: Custom fields and filters of post
Post by: davidhs on September 06, 2017, 07:47:50 AM
The problem is my mod.

SMF 2.0.14 need PHP 5.4 and my server has PHP 5.3.8. At this moment, I can not tested my mods in SMF 2.0.14.
Title: Re: Custom fields and filters of post
Post by: Arantor on September 06, 2017, 07:52:10 AM
You could always set up a local test server using something like XAMPP which comes with options for 5.6, 7.0 and 7.1.
Title: Re: Custom fields and filters of post
Post by: thepitster on September 06, 2017, 11:40:19 AM
The problem is my mod.

SMF 2.0.14 need PHP 5.4 and my server has PHP 5.3.8. At this moment, I can not tested my mods in SMF 2.0.14.
that is what I meant your mod conflicting with SMF 2.0.14.

Arantor tells you the truth on that, I had XAMPP setup on one of my computers, before I formatted it and installed Linux, LAMP, LEMP, PHP7, etc. and it worked fine with what I needed. they got XAMPP for Windows with PHP 5.6.31, 7.0.22 & 7.1.8 to choose from, give it a try apachefriends.org/download.html
Title: Re: Custom fields and filters of post
Post by: inkvfd on October 22, 2017, 05:46:23 PM
I must be getting old. I hope I am asking this the right way. We have tours out on our land and visitors can go to our SMF website to post what they have seen. I am using custom fields for them to add their info. It all works great except Guest post show before I can approve them. I need to approve them first before the world can see them. Can anyone help. 
Title: Re: Custom fields and filters of post
Post by: davidhs on October 23, 2017, 12:38:03 PM
I must be getting old. I hope I am asking this the right way. We have tours out on our land and visitors can go to our SMF website to post what they have seen. I am using custom fields for them to add their info. It all works great except Guest post show before I can approve them. I need to approve them first before the world can see them. Can anyone help. 

I am sorry, this mod does not consider this... :(

If you have a unapproved guest post with custom fields, are these fields show?
Title: Re: Custom fields and filters of post
Post by: Kirolainen on October 31, 2017, 04:45:04 AM
Hello.
I installed this mod on my forum and it worked flawlessly with SMFs own original template. Now I installed new template from SMFtricks. The mod works fine BUT does not show the fields and their values in the post. Whenediting the post, it shows, when viewing the post, it does not. I think there is something I have to change in (template?) files, but what it is exactly?
Title: Re: Custom fields and filters of post
Post by: Alpay on November 05, 2017, 05:46:59 AM
Hello,
    First of all thank you for mod.. I want to activate the glossary mod ( https://custom.simplemachines.org/mods/index.php?mod=1525 ) in the field. Can you help with this ?
Title: Re: Custom fields and filters of post
Post by: davidhs on November 25, 2017, 03:30:24 PM
Hello

Please, I wanted a modification.

I have a Custom field in my forum and have an evaluation on the form with "positive" "negative" and "neutral" options and I wanted when it was positive, it would have 1 point in the index of the topic and when it was negative it would lose 1 point.

If the topic custom form had 4 positive and 1 negative, the topic index would be +3.

It would be possible?
Now you can to do this! :) I added a new statistical data: Sum.



Hello.
I installed this mod on my forum and it worked flawlessly with SMFs own original template. Now I installed new template from SMFtricks. The mod works fine BUT does not show the fields and their values in the post. Whenediting the post, it shows, when viewing the post, it does not. I think there is something I have to change in (template?) files, but what it is exactly?
You must install first your themes and then mods (some mods, like this, need to do changes in themes).

You must to do:
1. uninstall new theme,
2. uninstall mods,
3. install new theme,
4. install mods.



I want to activate the glossary mod ( https://custom.simplemachines.org/mods/index.php?mod=1525 ) in the field. Can you help with this ?
I can not to do this. But you can create your own glossary with my mod:
- Create a group of fields type record, named "Word"
- Fields of this group can be "Name" (text), "Definition" (large text), "Category" (select or combo box with options), "Synonyms" (combo box), "Word is approved?" (checkbox).
- "Show definition in messages" can be a propiety of "Definition": Show on message index.
- Create a new board ("Glossary") and your users (all, moderators, or admins) can add words (topics with group "Word") to glossary.



New version:
Code: [Select]
1.5     2017-11-25
------------------
@ There may be conflict with SEF MODs, which create friendly URLs.
+ The number of each type of record created by the member is shown on the information about the member in personal messages.
+ Statistics in groups of type "fields with several values per member": Sum of numeric values.
+ Predefined filters: Types of record.
+ Field in administration panel to indicate if is allowed selecting the operator with which apply the predefined filter.
+ SMF compatibility: 2.0.12 to 2.0.15.
+ Languages: New language string in german, german-utf8, german_informal, german_informal-utf8, thanks to sangham.net.
! Languages: Some language string in english, english-utf8, english_british, english_british-utf8, thanks to sangham.net.
Title: Re: Custom fields and filters of post
Post by: moyack on November 30, 2017, 10:42:50 PM
Hi Davidhs, you now that I'm in love of this mod and thanks to this I've made a really well customized site with an embedded resource section. But now, I have a question for you:

In the search mode in the fields of type "registry", there's an option for search by field that adds an option in the search button. But when I search, it shows a list with links with a generic text, just like that:

(https://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=255458)

Is there a way to show a name in the links instead of the word "View"?

Another question is: in order to upgrade, should I uninstall and then reinstall the mod?
Title: Re: Custom fields and filters of post
Post by: davidhs on December 01, 2017, 09:05:55 AM
In the search mode in the fields of type "registry", there's an option for search by field that adds an option in the search button. But when I search, it shows a list with links with a generic text, just like that:

[...]

Is there a way to show a name in the links instead of the word "View"?
Your group record WC3 Models has permission Search with some users. With this you can see the search page of records WC3 Models with basic columns: icon of post with record, View (link to post), date posted and posted by. You see this now.

But you can add more columns :) (fields of this record).
1. Modify a field.
2. Go to Settings for type "Record".
3. You see settings fields:

Show on records lists: You can select one of these options:
- No: column is not added to search page.
- Yes, in a column with only this field: a column with name of this custom field is added to list, and can set the column width
- Yes, in a column together with other fields: a column with this and other fields is added to list. This is usefull when list has too many columns and you want reduce number of columns. You can add values of various custom fields in only one column. In this case you can set this column with a second setting field:

Column with multiple fields: You can add this custom field to another multi-field column created before, or create a new column (with name and width) with, at this moment, only this field.

4. Save.

5. Modify another custom field. You can create a new column or show in a multi-field column.

Another question is: in order to upgrade, should I uninstall and then reinstall the mod?
Yes. You do not worry, your custom fields will be not delete.
Title: Re: Custom fields and filters of post
Post by: moyack on December 01, 2017, 02:00:28 PM
Excellent!!! Now it looks very professional :D


(https://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=255468)

Let me give you a gift: In the upper part, where users can filter the topics, I added some CSS to make it looks more organized when there's a lot search parameters. Probably you can do it better than mine :D

Check the code in the attached file :)

HUGSS!!!!
Title: Re: Custom fields and filters of post
Post by: davidhs on December 01, 2017, 03:32:40 PM
Let me give you a gift: In the upper part, where users can filter the topics, I added some CSS to make it looks more organized when there's a lot search parameters. Probably you can do it better than mine :D

Check the code in the attached file :)
If all your WC3 Maps are in only one board is better use filter (as you do). Search page is better when you have records in more than one boards (with search page you can find records in various boards in only one result list). I supose you saw this. ;)

I like your theme in filters :)

You did added CSS styles in template file (function template_cffp_show). You do not must modify CustomFieldFilterPost.template.php because your changes be lost in next uninstall/install new version. :'( Instead to do this, try add your own style in YOUR_FORUM/Themes/YOUR_THEME/css/index.css. 8)

If you open this file you see the CSS of my mod for default theme:
Code: [Select]
/* BEGIN MOD CustomFieldFilterPost */
/* You do not modify this CSS style. Add your style before line "BEGIN MOD CustomFieldFilterPost" */
div.cffp_post,
div.cffp_member,
div.cffp_search
{
padding: 0.5em;
overflow: hidden;
}
div.cffp_post div.cffp_data,
div.cffp_member div.cffp_data,
div.cffp_search div.cffp_data
{
}
div.cffp_post dl.cffp_data > dt,
div.cffp_member dl.cffp_data > dt,
div.cffp_search dl.cffp_data > dt
{
float: left;
padding: 0;
margin: .5em 0 0 0;
font-weight: bold;
clear: both;
}
div.cffp_post dl.cffp_data > dd,
div.cffp_member dl.cffp_data > dd,
div.cffp_search dl.cffp_data > dd
{
float: left;
padding: 0;
margin: .3em 0;
}
div.cffp_post dl.cffp_data > dt,
div.cffp_member dl.cffp_data > dt
{
width: 20%;
}
div.cffp_post dl.cffp_data > dd,
div.cffp_member dl.cffp_data > dd
{
width: 78%;
}
div.cffp_search dl.cffp_data > dt
{
width: 40%;
}
div.cffp_search dl.cffp_data > dd
{
width: 58%;
}
form#cffp_edit_group .roundframe,
form#cffp_search .roundframe
{
padding: 0 12%;
}
div.cffp_post .moderatorbar,
div.cffp_member .moderatorbar
{
margin: 0;
}
div.cffp_post ul.quickbuttons,
div.cffp_member ul.quickbuttons
{
}
div.cffp_member div.cffp_member_data_fields
{
background-color: #fff;
padding: 10px;
}
div.cffp_member div.cffp_member_data_fields div.cffp_member_data_fields
{
padding: 0;
}
div.cffp_member div.cffp_member_fields
{
}
div.cffp_member div.cffp_member_fields span.botslice
{
clear: both;
}
div.cffp_member div.cffp_member_new_title
{
margin: 10px 0px;
}
div.cffp_member > fieldset legend a,
div.cffp_member div.cffp_member_data > fieldset legend a,
div.cffp_member div.cffp_member_new_title a
{
color: #444;
text-decoration: none;
}
div.cffp_member div.cffp_member_data_fields,
div.cffp_member div.cffp_member_new_fields
{
}
form#cffp_search div.cffp_column
{
margin: 0;
padding: 0;
width: 50%;
}
form#cffp_search div.cffp_column div.cffp_search
{
padding: 0 12px;
}
form#cffp_search div.cffp_roundframe
{
padding: 0 24%;
}
div.cffp_message_index
{
}
div.cffp_message_index_member
{
border-top: 1px solid #c4c4c4;
}
div.cffp_message_index span.cffp_group_name,
div.cffp_message_index_member span.cffp_group_name
{
font-weight: bold;
margin-right: 1em;
}
div.cffp_message_index div.cffp_data,
div.cffp_message_index dl.cffp_data,
div.cffp_message_index dl.cffp_data > dt,
div.cffp_message_index_member div.cffp_data,
div.cffp_message_index_member dl.cffp_data,
div.cffp_message_index_member dl.cffp_data > dt
{
display: inline !important;
}
div.cffp_message_index dl.cffp_data > dt,
div.cffp_message_index_member dl.cffp_data > dt
{
float: none !important;
padding: 0 !important;
margin: 0 !important;
width: auto !important;
font-weight: normal !important;
clear: none !important;
}
div.cffp_message_index dl.cffp_data > dd,
div.cffp_message_index_member dl.cffp_data > dd
{
display: inline-block !important;
float: none !important;
padding: 0 !important;
margin: 0 1em 0 0 !important;
width: auto !important;
}
div.cffp_message_index_member .moderatorbar
{
margin: 0;
}
div.cffp_message_index_member div.cffp_member_fields
{
border-bottom: 1px solid #c4c4c4;
}
form#cffp_filters
{
margin-top: 1em;
}
form#cffp_filters div.cffp_filters span
{
font-weight: bold;
margin-right: 1em;
}
form#cffp_filters div.cffp_filters a
{
margin-right: 1em;
}
form#cffp_filters div.cffp_filters,
form#cffp_filters div.cffp_filters dl,
form#cffp_filters div.cffp_filters dt
{
display: inline;
}
form#cffp_filters div.cffp_filters dd,
form#cffp_filters div.cffp_filters_button
{
display: inline;
margin-left: 0;
margin-right: 1em;
}
ul.quickbuttons li.move_button
{
background: url(../images/icons/quick_move.gif) no-repeat 0 0;
}
div.cffp_member_stats
{
padding: 0 12%;
}
div.cffp_message_index_member_stats
{
padding: 5px 0;
}
div.cffp_stats
{
width: 100%;
}
div.cffp_stats > dl.stats > dt
{
text-align: left;
}
div.cffp_stats_average
{
max-width: 392px;
width: 100%;
padding: 0;
}
div.cffp_stats_average span
{
font-weight: bold;
}
div.cffp_stats_average_bar
{
padding: 0;
height: 16px;
}
div.cffp_stats_average_bar div
{
background: #6294CE url(../images/bar_stats.png) repeat-x -4px;
padding: 0;
height: 16px;
}
div.cffp_top_posters_left
{
float: left;
width: 49.5%;
}
div.cffp_top_posters_right
{
float: right;
width: 49.5%;
}
/* END MOD CustomFieldFilterPost */

You do not must modify this code because you will have errors in uninstall :o, but you can write here your own style:
Code: [Select]
/* Here you can add your style */
your style...

/* BEGIN MOD CustomFieldFilterPost */
/* You do not modify this CSS style. Add your style before line "BEGIN MOD CustomFieldFilterPost" */
original style...
/* END MOD CustomFieldFilterPost */

For example, in CustomFieldFilterPost.template.php, line 3560
Code: [Select]
echo '
<div class="cffp_filters">';


if ($group['show_group_name_filter'])
echo '

<span>', $group['name'], '</span>';
you replace by
Code: [Select]
echo '
<div class="cffp_filters" style="display: inline-flex; padding: 0">';

if ($group['show_group_name_filter'])
echo '
<span style="float: left; padding: 5px 10px 0 0">', $group['name'], '</span>';

You can add this to css file instead of modify template:
Code: [Select]
form#cffp_filters div.cffp_filters
{
display: inline-flex !important;
padding: 0 !important;
}
form#cffp_filters div.cffp_filters span
{
float: left !important;
padding: 5px 10px 0 0 !important;
}
Also you can try add style with
Code: [Select]
form#cffp_filters div.cffp_filters dl
form#cffp_filters div.cffp_filters dd
form#cffp_filters div.cffp_filters dt
instead of replace dl/dd/dt tags with div's ;)



In filter section also you can add a button "Sort" and order your board by "Minumum Players" or "Score".
Modify a field and check permissions Sort 8)
Title: Re: Custom fields and filters of post
Post by: thepitster on December 07, 2017, 02:21:34 PM
when I updated to the newer version this popped up in the error_log again:
Code: (error_log) [Select]
syntax error, unexpected 'thank_list' (T_STRING), expecting ',' or ';' in ./Themes/default/Profile.template.php on line 518forgot the
Code: [Select]
';on line 517 of Profile.template.php, like so:
Before:
Code: (Profile.template.php(517)) [Select]
<!-- END MOD CustomFieldFilterPost -->After:
Code: (Profile.template.php(517)) [Select]
<!-- END MOD CustomFieldFilterPost -->';that way we don't end up at a blank page trying to view any profile.

Using SMF 2.0.15
Title: Re: Custom fields and filters of post
Post by: davidhs on December 07, 2017, 03:00:07 PM
when I updated to the newer version this popped up in the error_log again:
Code: (error_log) [Select]
syntax error, unexpected 'thank_list' (T_STRING), expecting ',' or ';' in ./Themes/default/Profile.template.php on line 518forgot the
Code: [Select]
';on line 517 of Profile.template.php, like so:
Before:
Code: (Profile.template.php(517)) [Select]
<!-- END MOD CustomFieldFilterPost -->After:
Code: (Profile.template.php(517)) [Select]
<!-- END MOD CustomFieldFilterPost -->';that way we don't end up at a blank page trying to view any profile.

Using SMF 2.0.15
Perhaps you have another mod and both mods modify same code...

I need see your code. Attach here your Profile.template.php.
Title: Re: Custom fields and filters of post
Post by: moyack on March 07, 2018, 03:22:32 PM
Hi davidhs:

As always, I'm doing awesome stuff with your mod but now I have an issue: I was working with a fields group which were initially "loose field" and then I've changed to "fields with several values per user" because I wanted to make them modifiable without editing the post. I've set it and then the field group didn't show anymore in the post. Then I tried to change it back but unfortunately it keeps hidden from then posts and in the message index.

I've searched in the database but it seems legit with no error. Is there a field in the database which is keeping in conflict? Is there any information you'll need to see? I'd show you the database fields via PM.

EDIT: It seems all the information from that group has been deleted... That's a bug that should be revised. Now I've lost too many fields stored for 2 years :(
Title: Re: Custom fields and filters of post
Post by: davidhs on March 07, 2018, 04:55:16 PM
Hi davidhs:

As always, I'm doing awesome stuff with your mod but now I have an issue: I was working with a fields group which were initially "loose field" and then I've changed to "fields with several values per user" because I wanted to make them modifiable without editing the post. I've set it and then the field group didn't show anymore in the post. Then I tried to change it back but unfortunately it keeps hidden from then posts and in the message index.

I've searched in the database but it seems legit with no error. Is there a field in the database which is keeping in conflict? Is there any information you'll need to see? I'd show you the database fields via PM.

EDIT: It seems all the information from that group has been deleted... That's a bug that should be revised. Now I've lost too many fields stored for 2 years :(
First, if you want edit a group of fields always you need edit its post.

A group type "fields with several values per user" has one value for each user. This group can be used for get opinion of users about the content of post. It is not used for add fields to a post.

You can convert a group type "loose fields" to "record" (and vice versa) without losing data because both types have only one value in one post.

But if you convert a group type "loose fields" or "record" to "fields with several values per user" (and vice versa), data of this group are deleted because they are not compability with new type. You are convert a group with only one value to a group with many values.

Do you have backup of your database? If yes you can restore data of your group (I can guide you in the process).
Else, this is not possible. I am sorry.
Title: Re: Custom fields and filters of post
Post by: moyack on March 09, 2018, 10:00:41 AM
Hi davidhs:

As always, I'm doing awesome stuff with your mod but now I have an issue: I was working with a fields group which were initially "loose field" and then I've changed to "fields with several values per user" because I wanted to make them modifiable without editing the post. I've set it and then the field group didn't show anymore in the post. Then I tried to change it back but unfortunately it keeps hidden from then posts and in the message index.

I've searched in the database but it seems legit with no error. Is there a field in the database which is keeping in conflict? Is there any information you'll need to see? I'd show you the database fields via PM.

EDIT: It seems all the information from that group has been deleted... That's a bug that should be revised. Now I've lost too many fields stored for 2 years :(
First, if you want edit a group of fields always you need edit its post.

A group type "fields with several values per user" has one value for each user. This group can be used for get opinion of users about the content of post. It is not used for add fields to a post.

You can convert a group type "loose fields" to "record" (and vice versa) without losing data because both types have only one value in one post.

But if you convert a group type "loose fields" or "record" to "fields with several values per user" (and vice versa), data of this group are deleted because they are not compability with new type. You are convert a group with only one value to a group with many values.

Do you have backup of your database? If yes you can restore data of your group (I can guide you in the process).
Else, this is not possible. I am sorry.i
Fortunately I had a backup, old but usable. But I suggest to add in a next version at least a warning about this situation in order to avoid issues like this.

And dont' forget that I still love with passion this mod.  ;)
Title: Re: Custom fields and filters of post
Post by: davidhs on March 10, 2018, 10:12:55 AM
Hi davidhs:

As always, I'm doing awesome stuff with your mod but now I have an issue: I was working with a fields group which were initially "loose field" and then I've changed to "fields with several values per user" because I wanted to make them modifiable without editing the post. I've set it and then the field group didn't show anymore in the post. Then I tried to change it back but unfortunately it keeps hidden from then posts and in the message index.

I've searched in the database but it seems legit with no error. Is there a field in the database which is keeping in conflict? Is there any information you'll need to see? I'd show you the database fields via PM.

EDIT: It seems all the information from that group has been deleted... That's a bug that should be revised. Now I've lost too many fields stored for 2 years :(
First, if you want edit a group of fields always you need edit its post.

A group type "fields with several values per user" has one value for each user. This group can be used for get opinion of users about the content of post. It is not used for add fields to a post.

You can convert a group type "loose fields" to "record" (and vice versa) without losing data because both types have only one value in one post.

But if you convert a group type "loose fields" or "record" to "fields with several values per user" (and vice versa), data of this group are deleted because they are not compability with new type. You are convert a group with only one value to a group with many values.

Do you have backup of your database? If yes you can restore data of your group (I can guide you in the process).
Else, this is not possible. I am sorry.i
Fortunately I had a backup, old but usable.
Good news.

Do you need help?
- 1st Do backup now.
- 2st Change again type of you group to loose data or record (I think record is best in your case).
- 3nd Restore only data of your group:
Code: [Select]
SELECT *
FROM smf_cffp_fields
WHERE id_group =1 // if your group ID is 1, you can see data with this SQL clause

But I suggest to add in a next version at least a warning about this situation in order to avoid issues like this.
Yes, of course. I had noted this.

And dont' forget that I still love with passion this mod.  ;)
Thanks!

And I am sorry very much.
Title: Re: Custom fields and filters of post
Post by: moyack on March 10, 2018, 06:53:39 PM
Don't worry, I've fixed the things with your suggestions and everything works as before. The missing part will be done by hand.

Thanks for your help and as always: THE BEST MOD EVER!!!!!

HUGS!!!
Title: Re: Custom fields and filters of post
Post by: moyack on March 27, 2018, 01:24:25 PM
Hi!!

It's me again :)

Well, I was just creating a product catalogue with your mod, but when I try to insert data, it allows to fill the data, but it doesn't save it in the database and I can't edit the post to refill the information.

Quote
Image 1: When you insert a new topic, it seems to work...
(https://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=257353;image)

Image 2: When you see the post, nothing is added and in the database, the data has not been inserted:(
(https://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=257355;image)

I've checked the settings but I can't find why it doesn't work. Attachments included.

Added the settings so far of this field group: FireShot Capture 1... to FireShot Capture 6.

POSTDATA: this site should implement a spoiler tag to improve presentation.
Title: Re: Custom fields and filters of post
Post by: davidhs on March 27, 2018, 04:04:56 PM
I think your problems is this:

You are selected Yes option in Show in sticky topics and Show in locked topics select box. The options of these select box means:
- Yes - Show ONLY in sticky/locked topics
- No - Show ONLY in NOT sticky/locked topics
- All - Show in ALL topics (sticky/locked and not sticky/locked)

This is the reason of your problem:
- When create a new post (topic), the system do not know if your topic will be sticky/locked or not, and you can fill your custom fields.
- When you save this post, system see it is not sticky/locked, and then remove your group of fields (because your group of field only can be added in sticky/locked topics).

Perhaps you should select option No in both cases.



I have some comments (can be usefull):

1. You has defined your "Catalogo de productos" as type loose fields (campos sueltos). I think your group is really a record (Registro).

2. Name of this group can be "Producto" instead of "Catalogo de productos" (when you add a topic in forum "Productos para la venta" you want add one product (not a catalogue of products). A catalogue of products have various products (really your forum "Productos para la venta" is your catalogue. ;)

3. Your field "Imágenes" have this format: attach1,attach2,attach3,... You can use the setting Show enclosed within text (Mostrar dentro del texto) with PHP code in orden to split names of file and show images of each file:
Code: [Select]
<?php

$attach 
'{INPUT}';
$attach_array explode(','$attach);
foreach (
$attach_array as $att)
echo '<img src="...">'// Show image of $att.

?>

4. Your field "Precio base" show prices in euros... I supouse. You can add euro sign with the setting Text next (Texto posterior):
Code: [Select]
Euro sign will be added after input button and after number.

5. Also you can use this in your field "Descuento" in order to show % after input button and after number:
Code: [Select]
%
6. I suppose you have many marks to write in your field "Marca del producto" and you do not know name of all in this moment, and new marks can be created. Instead use radio buttons you can use a combo box (cuadro combinado). This button have a text button (you can write a new mark) and a select box (you can select one ark added before).

:)
Title: Re: Custom fields and filters of post
Post by: moyack on June 25, 2018, 03:48:47 PM
Hi Davidhs!!

Well, this mod is the best of the best, and I just want to show you a system I made to manage service quotations using a mix of Fields Loose and Fields with several values per member.

(https://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=258318;image)

It works like a charm and I'm impressed how your mod can manage a huge amount of data easily.

But now I have a small issue. I've set in the Fields with several values per member part the possibility to modify and delete the field. The modification is working but the deletion isn't. I press the button "eliminar" (delete) but it doesn't show anything. The only way to delete this field is with moderation. How can I solve this?

(https://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=258320;image)
Title: Re: Custom fields and filters of post
Post by: davidhs on June 26, 2018, 07:00:56 AM
But now I have a small issue. I've set in the Fields with several values per member part the possibility to modify and delete the field. The modification is working but the deletion isn't. I press the button "eliminar" (delete) but it doesn't show anything. The only way to delete this field is with moderation. How can I solve this?
Hi, I test this now and works. Perhaps problem is permissions of your group... Can you attach image with permission area of this group?
Title: Re: Custom fields and filters of post
Post by: moyack on June 26, 2018, 07:40:22 AM
Here it is...

(https://www.simplemachines.org/community/index.php?action=dlattach;topic=518886.0;attach=258339;image)

BTW, i have other questions:


Thanks in advance for your support :)
Title: Re: Custom fields and filters of post
Post by: davidhs on June 28, 2018, 03:57:32 PM
Here it is... [...]
Sorry, all is ok, I do not see any error/bug in my source code. :( Pershaps this is another conflict with SEF mods... :-\
Quote
Just one question: I've added a rate system. one thing I've noticed is that the first rate should be done twice in order to register the score properly.
In my test forum this works. When I submit a rate, this is registered.  ???  Can you tell me your steps with images?
Sure, here it is:
1. I've created a new topic, in this case is a resource model. I've set some fields so it can describe the topic properly.
    Edit mode...
2. Before the updates to the custom fields, I had to set twice the value in order to get it registered and visible, now when I select into the rating the option in the select box, it doesn't update the score, I've tried many times and in fact it's storing the ratings, but not the value. Check image below
3. Here's the configuration of these fields...
The issue with the group field of type "fields with several values per member" that it was not registering the values submitted by the users was already solved. It was caused by the conflict with a SEF mod which rewrites the standard URLs with nice ones. In my case I use in my forum Search Engine Friendly URL (SEF) Manager from PortaMX and the solution was to add in the "actions to be ignored" field this ones: cffpeditgroup and cffpsearch.
Can you uninstall your SEF mod and test this?



BTW, i have other questions:

1. I'm needing to access frequenlty into a common filtering of post, and when I set a query, it produces a link like this: http://acmherramientas.com/index.php?board=2.0;a5b559b8=5c893299647aabfd823d7e52b35b1c4c, unfortunately I can't access to the filter parameters in this way and I can't use this link to make the filtering with a link button. is it possible to configure in any way a predefined filter? if not, I recommend to add some support for filtering though the search link, like using http://acmherramientas.com/index.php?board=2.0;cffp_order=field1&asc=1;cffp_field=field2
Yes, you can access to filters of message index with cffp_filters variable.
I suppouse you have in message index of board $id_board some filters of group $id_group.
Code: [Select]
<?php

// $id_group = ID of your group.
// $id_fieldN = ID of fieldN of group $id_group.
// {FIELD_n_DATABASE} is a variable of this mod. It will be replace by fieldname of field n in database.
// There are more variables in help pages of messages template.

$filters = array(
$id_group => array(
'{FIELD_' $id_field1 '_DATABASE}' => $value1,
'{FIELD_' $id_field2 '_DATABASE}' => $value1,

),
);
$params ';cffp_filters=' cffpUrlParamsCompress($filters);
$url $scripturl '?board=' $id_board '.0' $params;

?>

I never tried to access to order filter but it is a variable with name cffp_order_by. Values (options) are two for each field (see source code of your forum page):
Code: [Select]
cffpfN.column_M asc
cffpfN.column_M desc

N = ID of group
column_M = Fieldname in database (like {FIELD_n_DATABASE})
I suppouse you can use this, but I never tried:
Code: [Select]
<?php

$params 
';cffp_order_by=' $value;

?>



2. I'm needing to access the edition of some fields in other parts of the page, I've been exploring the Subs-CustomFieldFilterPost.php but I dont' know how to set the parameters to edit or create new fiels in a specific group.
I am sorry, I do not understand... Can you tell me an example? Also you can send to me a more complex example by PM in Spanish and I understand better. ;) (after, you explain here the solution in English).
Title: Re: Custom fields and filters of post
Post by: Americano on July 31, 2018, 10:52:21 PM
I can't moderate the record fields. If a user posts wrong, I can't change.


I can't include registration for other users, so count as if it were my record.

Please, what can I do?
Title: Re: Custom fields and filters of post
Post by: davidhs on August 01, 2018, 08:33:22 AM
I can't moderate the record fields. If a user posts wrong, I can't change.


I can't include registration for other users, so count as if it were my record.

Please, what can I do?
Perhaps your group/fields have a problem with permissions?
Can you attach images with their settings?
Title: Re: Custom fields and filters of post
Post by: Americano on August 01, 2018, 06:42:40 PM
Follow the image of my problem
Title: Re: Custom fields and filters of post
Post by: davidhs on August 02, 2018, 06:43:02 AM
Follow the image of my problem
I think I saw your problem...

You want modify group TD (with field Avaliação). Correct?

If you use the "modify quickly" button of bellow of post (with only icon), you can modify only the body of post (neither custom fields, neither attachments,...).

If you want modify more things (for example, custom fields o attachments), you must use Modify button of top of post (with icon and text, near other buttons: Quote, Remove,...).
Title: Re: Custom fields and filters of post
Post by: Americano on August 02, 2018, 05:57:36 PM
Ok! Thank you. I was able to modify it for another user.

But I wanted the administrator could include custom records for other users when they forget to post.

The administrator can even add the record to another user, but it counts the record to the administrator.

In fact, I wanted the record to be computed for the owner of the message and not for the administrator.
Title: Re: Custom fields and filters of post
Post by: davidhs on August 03, 2018, 05:34:41 AM
But I wanted the administrator could include custom records for other users when they forget to post.

The administrator can even add the record to another user, but it counts the record to the administrator.

In fact, I wanted the record to be computed for the owner of the message and not for the administrator.
Sorry, this is not possible. If a user creates a group of fieldls, he is the creator. And if other user modifies values of this group, this another is the modificator.

In setting of a group you can check show/hide user name and data of creation and last modification.

An enhancement for next versions of this mod can be add an option for reattribute groups of fields to other user (similar to reattribute post in SMF 2.0+). This is easy, or very usefull? Really I do not know...  ??? Now you can hide creation/modification data of a group of fields and show only creation data of the post.
Title: Re: Custom fields and filters of post
Post by: Americano on August 03, 2018, 11:32:32 AM

An enhancement for next versions of this mod can be add an option for reattribute groups of fields to other user (similar to reattribute post in SMF 2.0+). This is easy, or very usefull? Really I do not know...  ??? Now you can hide creation/modification data of a group of fields and show only creation data of the post.

Please, could you do in the next version?
Title: Re: Custom fields and filters of post
Post by: Americano on August 03, 2018, 06:29:56 PM
Please, another request for modification. I wanted the user level to be increased with the number of records.

For example from 10 record Level "Newbie", 20 records "Jr. Member" and so on.

Title: Re: Custom fields and filters of post
Post by: davidhs on August 04, 2018, 02:23:15 PM

An enhancement for next versions of this mod can be add an option for reattribute groups of fields to other user (similar to reattribute post in SMF 2.0+). This is easy, or very usefull? Really I do not know...  ??? Now you can hide creation/modification data of a group of fields and show only creation data of the post.

Please, could you do in the next version?
I will try but not sure...

Please, another request for modification. I wanted the user level to be increased with the number of records.

For example from 10 record Level "Newbie", 20 records "Jr. Member" and so on.
This can be difficult... or not. I will see.
Perhaps a user level for each records is necesary. ??? For example one member can be "Jr. Member" in posts and "Newbie" in records "X"
Title: Re: SQL Error when trying to install
Post by: kaki on November 14, 2018, 05:14:58 AM
The error I get is:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
 WHERE active = 1
 ORDER BY group_order ASC' at line 2
File: C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php
Line: 43

it looks like database_2.0.php isn't getting run on install


Hello,

Same problem here,  I am working off of a fresh install of SMF no other mods are installed too, i use smf version 2.0.15 and CustomFieldFilterPost_1.5.tar.gz .
Only "smf_cffp_count_groups" and "smf_cffp_fields" are created in database.

Error after install is:
Erreur de base de données
BLOB 'data' ne peut avoir de valeur par défaut
Fichier: L:\wamp64\www\smf\Packages\temp\database-2.0.php
Ligne: 915

Then, (after refresh or click other forum link) i have the same error as Vjones.

Is it possible to have database-2.0 in a sql format to import it please?

Thank you
Title: Re: Custom fields and filters of post
Post by: davidhs on November 14, 2018, 08:30:23 AM
The error I get is:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
 WHERE active = 1
 ORDER BY group_order ASC' at line 2
File: C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php
Line: 43

it looks like database_2.0.php isn't getting run on install


Hello,

Same problem here,  I am working off of a fresh install of SMF no other mods are installed too, i use smf version 2.0.15 and CustomFieldFilterPost_1.5.tar.gz .
Only "smf_cffp_count_groups" and "smf_cffp_fields" are created in database.

Error after install is:
Erreur de base de données
BLOB 'data' ne peut avoir de valeur par défaut
Fichier: L:\wamp64\www\smf\Packages\temp\database-2.0.php
Ligne: 915

Then, (after refresh or click other forum link) i have the same error as Vjones.

Is it possible to have database-2.0 in a sql format to import it please?

Thank you
I found this
https://stackoverflow.com/questions/3466872/why-cant-a-text-column-have-a-default-value-in-mysql
Columns type "text" can not have a default value in MySQL (it was a warning, but it is an error in MySQL 5.7 on Windows).

I have ready a new version of my mod with some enhancements, and also I will fix this in SMF 2.0.x. Soon, today or tomorrow.
Title: Re: Custom fields and filters of post
Post by: davidhs on November 16, 2018, 12:33:30 PM
Hi davidhs:

As always, I'm doing awesome stuff with your mod but now I have an issue: I was working with a fields group which were initially "loose field" and then I've changed to "fields with several values per user" because I wanted to make them modifiable without editing the post. I've set it and then the field group didn't show anymore in the post. Then I tried to change it back but unfortunately it keeps hidden from then posts and in the message index.

I've searched in the database but it seems legit with no error. Is there a field in the database which is keeping in conflict? Is there any information you'll need to see? I'd show you the database fields via PM.

EDIT: It seems all the information from that group has been deleted... That's a bug that should be revised. Now I've lost too many fields stored for 2 years :(
First, if you want edit a group of fields always you need edit its post.

A group type "fields with several values per user" has one value for each user. This group can be used for get opinion of users about the content of post. It is not used for add fields to a post.

You can convert a group type "loose fields" to "record" (and vice versa) without losing data because both types have only one value in one post.

But if you convert a group type "loose fields" or "record" to "fields with several values per user" (and vice versa), data of this group are deleted because they are not compability with new type. You are convert a group with only one value to a group with many values.
[...] I suggest to add in a next version at least a warning about this situation in order to avoid issues like this.
Done.


An enhancement for next versions of this mod can be add an option for reattribute groups of fields to other user (similar to reattribute post in SMF 2.0+). This is easy, or very usefull? Really I do not know...  ??? Now you can hide creation/modification data of a group of fields and show only creation data of the post.

Please, could you do in the next version?
Done.

Please, another request for modification. I wanted the user level to be increased with the number of records.

For example from 10 record Level "Newbie", 20 records "Jr. Member" and so on.
This can be difficult... or not. I will see.
Perhaps a user level for each records is necesary. ??? For example one member can be "Jr. Member" in posts and "Newbie" in records "X"
Done.

The error I get is:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_cffp_settings_groups
 WHERE active = 1
 ORDER BY group_order ASC' at line 2
File: C:\inetpub\wwwroot\simple_machines_forum\Sources\Themes-CustomFieldFilterPost.php
Line: 43

it looks like database_2.0.php isn't getting run on install
Hello,

Same problem here, [...]
I found this
https://stackoverflow.com/questions/3466872/why-cant-a-text-column-have-a-default-value-in-mysql
Columns type "text" can not have a default value in MySQL (it was a warning, but it is an error in MySQL 5.7 on Windows).

I have ready a new version of my mod with some enhancements, and also I will fix this in SMF 2.0.x. Soon, today or tomorrow.
Fixed.



New version:
Code: [Select]
2.0     2018-11-15
------------------
! SMF 1.1.x: Error in PHP code.
! SMF 1.1.x: Slashes are stripped from fields in filters and searches.
! SMF 1.1.x: Theme of the generic form of displaying lists.
! SMF 2.0.x: Columns type "text" can not have a default value in MySQL.
! When posts are reattribute to another member, the number of each type of record created by the member is recount only if number of posts is recount.
! Calculation of the number of each type of record created by members.
! Registered member data are displayed instead of poster data.
* If the number of each type of record created by the member is 0 can be hidden.
+ Fields in administration panel to indicate the labels of total and average number of each type of record created.
* The filter with text button allows to use more modifiers: - (do not search for a text), OR (search for one or another text).
+ The average number of each type of record created can be show on the statistics.
+ Show warning messages when data published by the members can be deleted because of changes in settings of groups.
+ Membergroups based on the number of each type of record, in "Administration Center > Membergroups > Based on number of records".
+ Reattribute User Groups, in "Administration Center > Forum Maintenance > Members > Reattribute User Groups".
@ "Administration Center > Forum Maintenance > Members > Reattribute User Posts" section does not exists in SMF 1.1.x and "Reattribute User Groups" section is not added.
+ Actions of Administration panel are logged to Administration log.
@ Administration log does not exists in SMF 1.1.x.
+ Moderation actions are logged to Moderation log.
+ Languages: New language string in german, german-utf8, german_informal, german_informal-utf8, thanks to sangham.net.
+ Languages: New language string in portuguese_brazilian, portuguese_brazilian-utf8, brazilian, brazilian-utf8, portuguese_pt, portuguese_pt-utf8, thanks to Americano.
! Languages: Some language string in english, english-utf8, english_british, english_british-utf8, thanks to sangham.net.
Title: Re: Custom fields and filters of post
Post by: moyack on November 18, 2018, 10:38:11 AM
Hi!!!

Updated and working like a charm!!!!

Thanks :D
Title: Re: Custom fields and filters of post
Post by: Americano on January 02, 2019, 05:32:38 PM
Thanks!
Title: Re: Custom fields and filters of post
Post by: Kikoigo on January 04, 2019, 08:30:55 AM
on "./Themes/default/css/index.css" say..... found "?>" and add before......

"/* BEGIN MOD CustomFieldFilterPost */
/* You do not modify this CSS style. Add your style before line "BEGIN MOD CustomFieldFilterPost" */
div.cffp_post,
div.cffp_member,
div.cffp_search
{
   padding: 0.5em;
   overflow: hidden;
}
div.cffp_post div.cffp_data,
div.cffp_member div.cffp_data,
div.cffp_search div.cffp_data
{
}".............. etc

but on this file do not exist this tag.......

I use directly at the end and work.......
Title: Re: Custom fields and filters of post
Post by: davidhs on January 04, 2019, 11:34:14 AM
on "./Themes/default/css/index.css" say..... found "?>" and add before......

"/* BEGIN MOD CustomFieldFilterPost */
/* You do not modify this CSS style. Add your style before line "BEGIN MOD CustomFieldFilterPost" */
div.cffp_post,
div.cffp_member,
div.cffp_search
{
   padding: 0.5em;
   overflow: hidden;
}
div.cffp_post div.cffp_data,
div.cffp_member div.cffp_data,
div.cffp_search div.cffp_data
{
}".............. etc

but on this file do not exist this tag.......

I use directly at the end and work.......
Yes, you must copy this text at end of index.css. Automatic instalation works fine but manual instalation say "copy before ?>" (this is a "bug" of SMF manual instalation because css files has not ?> at end of file; the correct is "copy at end of file").
Title: Re: Custom fields and filters of post
Post by: Kikoigo on January 08, 2019, 03:39:51 AM
Thx. The CSS works
Title: Re: Custom fields and filters of post
Post by: Kikoigo on January 08, 2019, 03:42:11 AM
Ok. After complete de guide to install the MOD. When I try to create the first group, I have this error.

Field 'template_quick_input_regex' doesn't have a default value
Archivo: /customers/9/9/e/piteurope.com/httpd.www/ulzeron/Sources/Admin-CustomFieldFilterPost.php
Línea: 2382

I don't understand why......

If you can response in Spanish, it's better for me..... LOL

THX
Title: Re: Custom fields and filters of post
Post by: davidhs on January 08, 2019, 07:01:02 AM
Ok. After complete de guide to install the MOD. When I try to create the first group, I have this error.

Field 'template_quick_input_regex' doesn't have a default value
Archivo: /customers/9/9/e/piteurope.com/httpd.www/ulzeron/Sources/Admin-CustomFieldFilterPost.php
Línea: 2382

I don't understand why......

If you can response in Spanish, it's better for me..... LOL

THX
I replay in Spanish support topic https://www.simplemachines.org/community/index.php?topic=515911.msg4002256#msg4002256
Title: Re: Custom fields and filters of post
Post by: davidhs on January 09, 2019, 07:56:32 AM
Ok. After complete de guide to install the MOD. When I try to create the first group, I have this error.

Field 'template_quick_input_regex' doesn't have a default value
Archivo: /customers/9/9/e/piteurope.com/httpd.www/ulzeron/Sources/Admin-CustomFieldFilterPost.php
Línea: 2382

I don't understand why......
Fixed.



New version:
Code: [Select]
2.0.1   2019-01-09
------------------
! Columns with no default value in MySQL must be in the INSERT clause.
Title: Re: Custom fields and filters of post
Post by: OtterlyAdorable on March 04, 2019, 11:43:20 AM
Hi!

I found your mod while I was trying to solve this problem (https://www.simplemachines.org/community/index.php?topic=565443).
Quote
My forum (the Irate Pirate [nofollow]) wants to run a monthly event for users who are above the average monthly post count.

We found one mod that might help us get partway there called Enhanced Forum Statistics, but upon trying to install this mod, it got a bunch of flags for conflicting with another mod.  We have a lot of mods, and it would take me a while to figure out which mod it conflicts with.  Depending on the mod, it may be entirely unreasonable to uninstall that mod for this one.

So, our next thought was just to get a spreadsheet of info on the posts made in the past month.  All we really need is, for each post, the date and the member who posted it.  We can extrapolate the average posts per month overall and by user with that information.

The problem is, I can't find that information.  I've looked at our database on the back end, and so far as I can tell, that information isn't available, and I'm not sure where I could find it.

Your mod looks really complex and it seems like it might be able to help me with what I'm trying to accomplish, but I'm a bit lost on how to implement it.  Do you think your mod can help me?  And if so, could you point me in the right direction for implementing it properly?
Title: Re: Custom fields and filters of post
Post by: davidhs on March 04, 2019, 01:03:33 PM
Hi!

I found your mod while I was trying to solve this problem (https://www.simplemachines.org/community/index.php?topic=565443).
Quote
My forum (the Irate Pirate [nofollow]) wants to run a monthly event for users who are above the average monthly post count.

We found one mod that might help us get partway there called Enhanced Forum Statistics, but upon trying to install this mod, it got a bunch of flags for conflicting with another mod.  We have a lot of mods, and it would take me a while to figure out which mod it conflicts with.  Depending on the mod, it may be entirely unreasonable to uninstall that mod for this one.

So, our next thought was just to get a spreadsheet of info on the posts made in the past month.  All we really need is, for each post, the date and the member who posted it.  We can extrapolate the average posts per month overall and by user with that information.

The problem is, I can't find that information.  I've looked at our database on the back end, and so far as I can tell, that information isn't available, and I'm not sure where I could find it.

Your mod looks really complex and it seems like it might be able to help me with what I'm trying to accomplish, but I'm a bit lost on how to implement it.  Do you think your mod can help me?  And if so, could you point me in the right direction for implementing it properly?
Sorry, with my mod you can not do this.

This mod add custom fields and get statistical data about those custom fields.
Title: Re: Custom fields and filters of post
Post by: OtterlyAdorable on March 04, 2019, 01:05:52 PM
Yeah the more I was looking into it, the more I suspected as much.

Thank you for your response.  =)
Title: Re: Custom fields and filters of post
Post by: moyack on March 30, 2019, 05:37:28 PM
Hi Davidhs!!

I was wondering if there's in the process an update to support SMF 2.1, now that it's reaching the Stable state.

Hugs!!!
Title: Re: Custom fields and filters of post
Post by: davidhs on March 30, 2019, 07:06:33 PM
Hi Davidhs!!

I was wondering if there's in the process an update to support SMF 2.1, now that it's reaching the Stable state.

Hugs!!!
I tried to do this some time ago but this mod (and others of my mods) need write/read text of textarea editor and I did not can to do this. :(
https://www.simplemachines.org/community/index.php?topic=557881.0
Title: Re: Custom fields and filters of post
Post by: Arantor on March 30, 2019, 07:12:10 PM
The editor has been updated since then; it's possible you might find it works now.
Title: Re: Custom fields and filters of post
Post by: davidhs on March 31, 2019, 06:26:18 AM
The editor has been updated since then; it's possible you might find it works now.
I was waiting for the next release of SMF 2.1, but I did not know that RC1 and RC2 are already there! I will adapt my mods.
Title: Re: Custom fields and filters of post
Post by: Sesquipedalian on March 31, 2019, 09:00:52 AM
Among other things, you will want to pay attention to 2.1's changes to the way input fields are handled on the post authoring form. The $context['posting_fields'] array, the integrate_post_end hook, and this documentation (https://github.com/SimpleMachines/SMF2.1/blob/3899b9518f75d23d39bf643e081e6e4461278563/Sources/Post.php#L1325-L1446) will be of interest.
Title: Re: Custom fields and filters of post
Post by: tjrpcaft on April 08, 2019, 04:10:46 PM
Excuse me if my reply is "necro-posting", but could someone paste here links of forums that use this mod?

I would like to try it, but I would like to see some real examples first. Is that ok?

Regards
Title: Re: Custom fields and filters of post
Post by: tjrpcaft on April 11, 2019, 04:00:59 AM
bump
Title: Re: Custom fields and filters of post
Post by: Benqo on April 11, 2019, 08:33:06 AM
Hi,

I tried to install this mod on my new forum and find it a bit strange that files in the installation section and in core theme are reported differently. In installation section ./Themes/default/MessageIndex.template.php is marked as "Test successful", but in core theme as "Test failed" (see screenshots.

So, what message should I trust now? Or is it because the files in question are modified twice, first mod working, second one not?

Regards, Thomas
Title: Re: Custom fields and filters of post
Post by: Arantor on April 11, 2019, 08:59:06 AM
It’s more that SMF ships with 2 themes, the default theme is what this plugin was built for, and the old theme, named “Core” is sufficiently different it doesn’t work. If you’re using Curve or any other third party theme, ignore the issues for Core.
Title: Re: Custom fields and filters of post
Post by: Benqo on April 11, 2019, 11:37:46 AM
Well, it also reports errors for the theme I'm using as well.  ;D

Not sure, what I should do and if it is worth to do the changes manually.

Regards, Thomas
Title: Re: Custom fields and filters of post
Post by: tjrpcaft on April 12, 2019, 12:19:43 PM
Excuse me if my reply is "necro-posting", but could someone paste here links of forums that use this mod?

I would like to try it, but I would like to see some real examples first. Is that ok?

Regards

bump
Title: Re: Custom fields and filters of post
Post by: davidhs on April 12, 2019, 01:09:49 PM
Excuse me if my reply is "necro-posting", but could someone paste here links of forums that use this mod?

I would like to try it, but I would like to see some real examples first. Is that ok?

Regards
I can not tell you any forum but you can search in this topic. Here you can see images of some users. For example:
https://www.simplemachines.org/community/index.php?topic=518886.msg3967090#msg3967090

Also you can install a test forum, install this mod and do the example of first post of this topic.



Well, it also reports errors for the theme I'm using as well.  ;D

Not sure, what I should do and if it is worth to do the changes manually.

Regards, Thomas
I suppose your forum is SMF 1.1.x/2.0.x (not 2.1 Beta/RC).

My mod need do changes in some files modified by another mod. Can you attach image of errors in install?
Title: Re: Custom fields and filters of post
Post by: moyack on April 12, 2019, 09:30:42 PM
I can not tell you any forum but you can search in this topic. Here you can see images of some users. For example:
https://www.simplemachines.org/community/index.php?topic=518886.msg3967090#msg3967090

Well, my site could make this mod a good advertisement...

https://wc3modding.info/wc3-editing-tools/ (message index)
https://wc3modding.info/4263/the-jass-newgen-pack-jngp-2-0/ (topic example)
Title: Re: Custom fields and filters of post
Post by: davidhs on April 13, 2019, 01:13:07 PM
I can not tell you any forum but you can search in this topic. Here you can see images of some users. For example:
https://www.simplemachines.org/community/index.php?topic=518886.msg3967090#msg3967090

Well, my site could make this mod a good advertisement...

https://wc3modding.info/wc3-editing-tools/ (message index)
https://wc3modding.info/4263/the-jass-newgen-pack-jngp-2-0/ (topic example)
Good example, I like it!

Comments:

1. Field Keywords. When you add/modify a "WC3 Tools" this field is a text button and user can write keywords comma separeted, but different users can write similar words for same keyword (Jass, jass, jas, jjas, jaas...). If you define this button as combo box (text button + select box), user can write keywords in text button or select keywords from select box. Keywords written in text button will be added in select box when other register will created and could reused.

2. Add link to filter in values. Perhaps you tried this or you do not want... You can write values of field with links to filter (now you have only text) and when click on a value, filter is activated. You can try this code in templates:
Code: [Select]
<?php

if (!function_exists('cffp_filter'))
{
function cffp_filter($id_group$field_value$field_database$max 0)
{
$value_array explode(', '$field_value);

$filter_array = array();
foreach ($value_array as $k => $value)
{
if ($max && $k >= $max// If there are many values, perhaps is better show only $max values.
break; // Exit foreach.

$filter_array[] = '<a href="#" onclick="javascript: if (document.getElementById(\'cffp_filters\') && document.getElementById(\'cffp_' $id_group '_' $field_database '\')) { document.getElementById(\'cffp_' $id_group '_' $field_database '\').value = \'' $value '\'; document.getElementById(\'cffp_filters\').submit(); } return false;">' $value '</a>';
}

return implode(', '$filter_array) . ($max && $k >= $max ' [...]' '');
}
}

// Group "WC3 Tools" has ID = 5 (I see in your HTML code page ;) )
$id_group 5;

// Field "Tool Category" has ID (unknown for me, you can see in settings area of mod; for example = 7;
$field_name '{FIELD_7_NAME}'// Name of this field: Tool Category
$field_value '{FIELD_7_VALUE}'// Value of this field: Jass Scripting, Specific WE Module as a Standalone App, Text Editor &amp; Highlighter, World Editor (WE) Add on or plugin
$field_database '{FIELD_7_DATABASE}'// Column name of this field in database (I see in your HTML code page and is 'column_6').

// Now, you can write all "Tool Category" values with links to filter.
echo '<strong>'$field_name':</strong> 'cffp_filter($id_group$field_value$field_database);

?>

In next updates I will try add a function for do this more easy. :)
Title: Re: Custom fields and filters of post
Post by: moyack on August 28, 2019, 08:49:04 AM
Hi!!

Long time no see!! I have a question about reassign records to another member. I want to set some resources to a member, but when I follow the interface, it doesn't' change the resource to an specific member. Can you give me a hint??
Title: Re: Custom fields and filters of post
Post by: davidhs on August 28, 2019, 01:23:37 PM
Hi!!

Long time no see!! I have a question about reassign records to another member. I want to set some resources to a member, but when I follow the interface, it doesn't' change the resource to an specific member. Can you give me a hint??
You need fill these fields:
- Attribute guest groups made with: Username of: moyack
- Attribute specific posts: POST IDs WITH RECORDS
- Attribute groups of type: SELECT TYPE OF RECORDS TO REASSIGN
- Attribute registered member groups: [X]
- Attribute groups to member: olofmoleman

This only reattribute groups of fields. If you want also attribute post with this group, you need reattribute posts.
Title: Re: Custom fields and filters of post
Post by: moyack on September 08, 2019, 09:25:48 PM
Hi!!

Long time no see!! I have a question about reassign records to another member. I want to set some resources to a member, but when I follow the interface, it doesn't' change the resource to an specific member. Can you give me a hint??
You need fill these fields:
- Attribute guest groups made with: Username of: moyack
- Attribute specific posts: POST IDs WITH RECORDS
- Attribute groups of type: SELECT TYPE OF RECORDS TO REASSIGN
- Attribute registered member groups: [X]
- Attribute groups to member: olofmoleman

This only reattribute groups of fields. If you want also attribute post with this group, you need reattribute posts.

Thanks!!

Worked perfectly. May I suggest a feature based on this? To add a button after the "Move to another post" that changes the owner of the record to the message poster.
Title: Re: Custom fields and filters of post
Post by: davidhs on September 09, 2019, 11:32:49 AM
May I suggest a feature based on this? To add a button after the "Move to another post" that changes the owner of the record to the message poster.
I will see on next update. :)
Title: Re: Custom fields and filters of post
Post by: davidhs on March 09, 2020, 01:37:19 PM
New version:
Code: [Select]
2.0.2   2020-03-08
------------------
! SMF 2.0.x: The Quick Search of the Administration Center look for in settings variables of MOD.
+ SMF compatibility: 2.0.16 to 2.0.17.
Title: Re: Custom fields and filters of post
Post by: moyack on March 18, 2020, 06:04:57 PM
New version:
Code: [Select]
2.0.2   2020-03-08
------------------
! SMF 2.0.x: The Quick Search of the Administration Center look for in settings variables of MOD.
Awesome!!!

I'll try to update it because I've made so many changes for my needs that it's better to make the changes by hand.
Title: Re: Custom fields and filters of post
Post by: Americano on April 25, 2020, 10:31:24 AM
The latest version is not in Portuguese.
Title: Re: Custom fields and filters of post
Post by: Americano on April 25, 2020, 11:49:43 AM

An enhancement for next versions of this mod can be add an option for reattribute groups of fields to other user (similar to reattribute post in SMF 2.0+). This is easy, or very usefull? Really I do not know...  ??? Now you can hide creation/modification data of a group of fields and show only creation data of the post.

Please, could you do in the next version?
Done.

It was not what I wanted. I wanted it when a moderator was going to include a record in someone else's message, be a computer for the owner of the original message.
Title: Re: Custom fields and filters of post
Post by: davidhs on April 25, 2020, 01:31:43 PM
The latest version is not in Portuguese.
I see this. Same problem with all non-utf8 languages (except English). :( I will fixed now...




An enhancement for next versions of this mod can be add an option for reattribute groups of fields to other user (similar to reattribute post in SMF 2.0+). This is easy, or very usefull? Really I do not know...  ??? Now you can hide creation/modification data of a group of fields and show only creation data of the post.

Please, could you do in the next version?
Done.

It was not what I wanted. I wanted it when a moderator was going to include a record in someone else's message, be a computer for the owner of the original message.

I am not sure understand this. But I think you can do this with my new enhancement:
Reattribute User Groups (only series SMF 2.0.x)

Allows reattribute to registered member groups of fields published by a guest or another registered member.

This is located in "Administration Center > Forum Maintenance > Members > Reattribute User Groups".

Else, write here an example (with images if it is possible).
Title: Re: Custom fields and filters of post
Post by: Americano on April 26, 2020, 10:17:43 AM
It was not what I wanted. I wanted it when a moderator was going to include a record in someone else's message, be a computer for the owner of the original message.

I am not sure understand this. But I think you can do this with my new enhancement:
Reattribute User Groups (only series SMF 2.0.x)

Allows reattribute to registered member groups of fields published by a guest or another registered member.

This is located in "Administration Center > Forum Maintenance > Members > Reattribute User Groups".

Else, write here an example (with images if it is possible).

checked but didn't change anything.
The post goes to the owner of the message, but the record goes to whoever included it (administrator). The counter does not change the record.
Title: Re: Custom fields and filters of post
Post by: davidhs on April 27, 2020, 12:16:15 PM
The latest version is not in Portuguese.
I see this. Same problem with all non-utf8 languages (except English). :( I will fixed now...
Fixed! Same problem with help text in some languages.



New version:
Code: [Select]
2.0.3   2020-04-27
------------------
! The help text is still too long and generates an error on installation. It is divided in several files.
! Since version 1.1 the non-UTF-8 language text is too long and generates an error on installation. It is divided in several files.
Title: Re: Custom fields and filters of post
Post by: davidhs on April 27, 2020, 12:53:00 PM
It was not what I wanted. I wanted it when a moderator was going to include a record in someone else's message, be a computer for the owner of the original message.

I am not sure understand this. But I think you can do this with my new enhancement:
Reattribute User Groups (only series SMF 2.0.x)

Allows reattribute to registered member groups of fields published by a guest or another registered member.

This is located in "Administration Center > Forum Maintenance > Members > Reattribute User Groups".

Else, write here an example (with images if it is possible).

checked but didn't change anything.
The post goes to the owner of the message, but the record goes to whoever included it (administrator). The counter does not change the record.
I tested this in my forum and works. You update to new version and test again. If this not work attach images of your steps, please.

I suppose you know have two owner data (date and user): one for message (shown below subject) and another for record (shown below record). This last can be shown/hidden in Settings for type "record".
Title: Re: Custom fields and filters of post
Post by: Americano on May 12, 2020, 10:25:16 AM
I deleted the mod from the previous version and installed the new mod, but the registration is getting duplicated.
Title: Re: Custom fields and filters of post
Post by: davidhs on May 12, 2020, 11:48:59 AM
I deleted the mod from the previous version and installed the new mod, but the registration is getting duplicated.
??? Explain step by step (and with images if it is possible), please.
Title: Re: Custom fields and filters of post
Post by: Shambles on May 12, 2020, 11:51:29 AM
Quote from: Americano
I deleted the mod from the previous version ...

Deleted, or uninstalled?
Title: Re: Custom fields and filters of post
Post by: Americano on May 12, 2020, 05:13:06 PM
When I'm going to post, two identical records appear.

I already deleted and installed it again, but the problem persists.
Title: Re: Custom fields and filters of post
Post by: Shambles on May 12, 2020, 05:26:42 PM
Quote from: Americano
I deleted the mod from the previous version ...

Deleted, or uninstalled?
Title: Re: Custom fields and filters of post
Post by: Americano on May 12, 2020, 05:37:22 PM
Follows image
Title: Re: Custom fields and filters of post
Post by: Shambles on May 12, 2020, 05:53:27 PM
Quote from: Americano
I deleted the mod from the previous version ...

Deleted, or uninstalled?
Title: Re: Custom fields and filters of post
Post by: Arantor on May 12, 2020, 05:58:27 PM
I don't think he understood the question.

Americano: when you removed the previous version, did you just press delete or press uninstall first? If you just deleted it, it's still installed and installing it the second time made it install twice (because you didn't uninstall the original one first)
Title: Re: Custom fields and filters of post
Post by: davidhs on May 13, 2020, 08:01:31 AM

Regardless of whether you uninstalled or deleted the previous version of mod (I hope you have uninstalled it! Because if you only deleted the tar.gz file, it would have to be uninstalled manually),

In your image I see two problems:

Title: Re: Custom fields and filters of post
Post by: Americano on May 13, 2020, 01:55:23 PM
I don't think he understood the question.

Americano: when you removed the previous version, did you just press delete or press uninstall first? If you just deleted it, it's still installed and installing it the second time made it install twice (because you didn't uninstall the original one first)

First uninstalled and then deleted.
Title: Re: Custom fields and filters of post
Post by: Americano on May 13, 2020, 02:03:22 PM
Follows attached
Title: Re: Custom fields and filters of post
Post by: davidhs on May 13, 2020, 05:34:07 PM
Ok. First we must fixed problem of record duplicate.

Problem can be there was an error on uninstall previous version and some code did not remove.

To check this I need to see your files:
- Sources/Display.php
- Themes/YOUR_THEME/Display.template.php
Can you attach here?
Title: Re: Custom fields and filters of post
Post by: Americano on May 13, 2020, 09:33:22 PM
Segue anexo.
Title: Re: Custom fields and filters of post
Post by: davidhs on May 14, 2020, 09:02:10 AM
Segue anexo.
Code inserted by this mod is duplicated (perhaps an error occurred while uninstalling the previous version, or perhaps installation of new version was twice... I do not know.

First, I suppose you have latest versions of SMF (2.0.17) and my mod (2.0.3). Correct?

You need remove duplicate code from php files from your server. Can you (and do you know) modify code on files from your server? I suppose yes.

The code inserted by this mod is between text BEGIN MOD CustomFieldFilterPost and END MOD CustomFieldFilterPost.

You must search this text in files, and remove one copy if it is duplicate. But there is a problem: This mod modify many files (31+) and do many changes (114+).

The best is:

1. Uninstall my mod.

2. Open Sources/Admin.php, search this and delete if exists:
Code: [Select]
// BEGIN MOD CustomBlocks
array('cffpSettingsShow', 'area=modsettings;sa=cffp'),
// END MOD CustomBlocks
(Here I wrote MOD CustomBlocks instead of MOD CustomFieldFilterPost: an copy/paste error; I will fix on next update.)

3. Search MOD CustomFieldFilterPost in all files of your site. Can be this files:

Sources/Admin.php
Sources/Display.php
Sources/Load.php
Sources/ManageMaintenance.php
Sources/ManageMembergroups.php
Sources/ManageSettings.php
Sources/MessageIndex.php
Sources/ModerationCenter.php
Sources/Post.php
Sources/Printpage.php
Sources/Profile-View.php
Sources/Recent.php
Sources/RemoveTopic.php
Sources/Stats.php
Sources/Subs-Members.php
Sources/Subs-Post.php
Sources/Who.php

Themes/YOUR_THEME/Display.template.php
Themes/YOUR_THEME/ManageMaintenance.template.php
Themes/YOUR_THEME/MessageIndex.template.php
Themes/YOUR_THEME/PersonalMessage.template.php
Themes/YOUR_THEME/Post.template.php
Themes/YOUR_THEME/Printpage.template.php
Themes/YOUR_THEME/Profile.template.php
Themes/YOUR_THEME/Recent.template.php
Themes/YOUR_THEME/Stats.template.php
Themes/YOUR_THEME/Wireless.template.php
Themes/YOUR_THEME/css/index.css

Themes/YOUR_THEME/languages/Errors.ANY_LANGUAGE.php
Themes/YOUR_THEME/languages/Help.ANY_LANGUAGE.php
Themes/YOUR_THEME/languages/Modifications.ANY_LANGUAGE.php

4. Tell me what files have text MOD CustomFieldFilterPost.
In most times the code between this text can be delete, but in a few times must be replaced for other code (the SMF original code). Because of this I need know what is the file before remove or replace the code.

5. Finally, you must remove integrate hooks, from your database. We will see how.
Title: Re: Custom fields and filters of post
Post by: Americano on May 15, 2020, 10:11:29 AM
I deleted the forum and created another one.
Title: Re: Custom fields and filters of post
Post by: Americano on May 15, 2020, 10:46:42 AM
This mod is full of problems. Several things going wrong. In previous versions it was even working, but now it is full of defects.

I am too lazy to report the problems
Title: Re: Custom fields and filters of post
Post by: davidhs on May 15, 2020, 12:19:59 PM
This mod is full of problems. Several things going wrong. In previous versions it was even working, but now it is full of defects.

I am too lazy to report the problems

I am sorry, I do not understand what happen to you. Now I installed in my local server another test forum SMF 2.0.17 and I installed my mod (last version: 2.0.3). And works fine:
1. I created a record with one field and counter.
2. I created a post with record, the counter increased.
3. I removed a post with record, the counter decresed. The record is show only one time in each post, of course.
4. I uninstalled my mod
5. I installed again my mod.
6. I saw post and record created before uninstall.

Have somebody a similar problem?

Can you see the error log of your forum? There are something?

I supose you have correct version of PHP. If not, you should had problems with SMF, not only with my mod.

Do you have an online test forum? If yes, I can visit it and see how work (you send PM with URL and admin account).
Title: Re: Custom fields and filters of post
Post by: Tarkidu on May 18, 2020, 09:01:07 AM
I was waiting for the next release of SMF 2.1, but I did not know that RC1 and RC2 are already there! I will adapt my mods.

Are there any updates? ;D
Title: Re: Custom fields and filters of post
Post by: davidhs on May 18, 2020, 10:51:11 AM
I was waiting for the next release of SMF 2.1, but I did not know that RC1 and RC2 are already there! I will adapt my mods.

Are there any updates? ;D
I am sorry, no. I have problems with editor of SMF 2.1. :(