forked from scribu/wp-posts-to-posts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
readme.txt
245 lines (198 loc) · 9.01 KB
/
readme.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
=== Posts 2 Posts ===
Contributors: scribu, ciobi
Tags: connections, custom post types, relationships, many-to-many, users
Requires at least: 3.4
Tested up to: 3.4
Stable tag: 1.4.2
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Efficient many-to-many connections between posts, pages, custom post types, users.
== Description ==
This plugin allows you to create many-to-many relationships between posts of any type: post, page, custom etc. A few example use cases:
* manually curated lists of related posts
* post series
* products connected to retailers
* etc.
Additionally, you can create many-to-many relationships between posts and users. So, you could also implement:
* favorite posts of users
* multiple authors per post
* etc.
Links: [**Documentation**](http://github.com/scribu/wp-posts-to-posts/wiki) | [Plugin News](http://scribu.net/wordpress/posts-to-posts) | [Author's Site](http://scribu.net)
== Installation ==
See [Installing Plugins](http://codex.wordpress.org/Managing_Plugins#Installing_Plugins).
After activating it, refer to the [Basic usage](https://github.com/scribu/wp-posts-to-posts/wiki/Basic-usage) tutorial.
Additional info can be found on the [wiki](http://github.com/scribu/wp-posts-to-posts/wiki).
== Frequently Asked Questions ==
= Error on activation: "Parse error: syntax error, unexpected..." =
Make sure your host is running PHP 5. The only foolproof way to do this is to add this line to wp-config.php:
`var_dump(PHP_VERSION);`
<br>
== Screenshots ==
1. Basic connection metabox
2. Advanced connection metabox
3. Admin column
4. Widget
5. Connection Types screen
== Changelog ==
= 1.4.2 =
* fixed each_connected() returning wrapped objects
* fixed issue with user queries and get_current_screen()
* fixed "Delete all connections" button
* fixed bugs with reciprocal and non-reciprocal indeterminate connection types
* added Dutch translation
= 1.4.1 =
* fixed errors in admin box
* fixed each_connected()
= 1.4 =
* added 'p2p_init' hook
* replaced 'View All' button with '+ Create connections' toggle
* improved usability of connection candidate UI
* fixed issues related to auto-drafts
* show columns on the admin user list screen
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-1-4.html)
= 1.3.1 =
* sanitize connection fields values on save, preventing security exploits
* improved connection field default value handling
* added 'default_cb' as an optional key when defining connection fields
* fixed parameter order for 'p2p_admin_box_show' filter
* pass the current post ID to the 'p2p_new_post_args' filter
= 1.3 =
* allow passing entire objects to get_connected(), connect() etc.
* made get_related() work with posts-to-users connections
* made each_connected() work with simple array of posts
* introduced [p2p_connected] and [p2p_related] shortcodes
* allow 'default' parameter in 'fields' array
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-1-3.html)
= 1.2 =
* added Tools -> Connection Types admin screen
* fixed migration script
* made p2p_get_connections() accept arrays of ids
* added 'separator' parameter to p2p_list_posts()
* made P2P_Directed_Type->connect() return WP_Error instances instead of just false
* when a user is deleted, delete all the associated connections
* fixed conflict with bbPress Topics for Posts plugin
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-1-2.html)
= 1.1.6 =
* convert "View All" tab into button
* refresh candidate list after deleting a connection
* fix cardinality check
* introduce 'p2p_connection_type_args' filter
* make 'connected_type' accept an array of connection type names
* inadvertently remove support for queries without 'connected_type' parameter
= 1.1.5 =
* added P2P_Connection_Type->replace() method
* added 'self_connections' flag to p2p_register_connection_type()
* made P2P_Connection_Type->each_connected() work for posts-to-users connections
* made admin list table columns work for posts-to-users connections
* fixed 'from_labels' and 'to_labels' parameters
* fixed search being limited only to post titles
= 1.1.4 =
* show attachment thumbnail instead of title
* merged 'from_object' into 'from' and 'to_object' into 'to'
* made posts-to-users queries respect 'to_query_vars' args
* added $prop_name parameter to P2P_Type::each_connected()
* fixed connection field name conflict
= 1.1.3 =
* fixed regression related to posts-to-users direction
* fixed admin columns overwriting each other
* fixed incorrect direction in admin column links
* added notices when connection type is not properly defined
= 1.1.2 =
* fixed fields not being saved for posts-to-users connections
* fixed missing "New Post" tab in admin box
* fixed notice when deleting post
= 1.1.1 =
* fixed faulty scbFramework loading
* simplified syntax for defining posts-to-users connection types
= 1.1 =
* add p2p_type column to the wp_p2p table
* new low-level api: p2p_create_connection(), p2p_get_connections(), p2p_delete_connections(), p2p_connection_exists()
* support posts-to-users and users-to-posts connection types in the admin
* add 'from_labels' and 'to_labels' args to p2p_register_connection_type()
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-1-1.html)
= 1.0.1 =
* don't show metabox at all if user doesn't have the required capability
* fix checkbox handling when there are no other input fields
* improve metabox styling
* rename 'show_ui' to 'admin_box'
* add 'admin_column' parameter
= 1.0 =
* widget can now list related posts
* add P2P_Connection_Type::get_related() method
* add 'can_create_post' arg to p2p_register_connection_type()
* two-box mode for `'reciprocal' => false`
* more options for 'show_ui'
* allow checkboxes, radio buttons and textareas as connection fields
* allow drag & drop ordering in both directions
* added get_previous(), get_next() and get_adjacent() methods to P2P_Connection_Type
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-1-0.html)
= 0.9.5 =
* add '{from|to}_query_vars' args to p2p_register_connection_type()
* add 'cardinality' arg to p2p_register_connection_type()
* add 'id' arg and p2p_type() function
* introduce p2p_split_posts()
* remove p2p_connect(), p2p_disconnect() and p2p_get_connected()
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-9-5.html)
= 0.9.2 =
* fix incorrect storage when creating a connection from the other end
* respect 'reciprocal' => false when 'from' == 'to'
* pass pagination numbers through number_format_i18n()
= 0.9.1 =
* fix bug with each_connected()
* add widget
* allow 'from' and 'to' to be arrays again
* improve RTL support
= 0.9 =
* introduce dropdown connection fields
* introduce 'sortable' arg to p2p_register_connection_type()
* introduce 'data' arg to p2p_register_connection_type()
* replace 'box' arg with hooks
* replace p2p_each_connected() with P2P_Post_Type->each_connected()
* allow using 'connected_meta' and 'connected_orderby' together
* fix some translations
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-9.html)
= 0.8 =
* added ability to create draft posts from the connection box. props Oren Kolker
* show post status in the connection box. props [Michael Fields](http://wordpress.mfields.org/)
* reduced number of queries by caching connection information
* revamped p2p_each_connected()
* introduced p2p_list_posts()
* introduced 'connected_orderby', 'connected_order' and 'connected_order_num' query vars
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-8.html)
= 0.7 =
* improved UI. props [Alex Ciobica](http://ciobi.ca/)
* added 'fields', 'context' and 'prevent_duplicates' args to p2p_register_connection_type()
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-7.html)
= 0.6 =
* added p2p_each_connected()
* fixed p2p_is_connected()
* made p2p_get_connected() return p2p_ids even with `$direction = 'any'`
* made compatible with [Proper Network Activation](http://wordpress.org/extend/plugins/proper-network-activation)
* [more info](http://scribu.net/wordpress/posts-to-posts/version-0-6.html)
= 0.5.1 =
* fixed fatal error on Menus screen
= 0.5 =
* added 'connected_meta' var to WP_Query
* attach p2p_id to each post found via WP_Query
* 'connected_to' => 'any' etc.
* $data parameter can also be a meta_query
* metabox bugfixes
* fixed l10n loading
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-5.html)
= 0.4 =
* introduced 'connected_from', 'connected_to', 'connected' vars to WP_Query
* replaced $reciprocal with $data as the third argument
* p2p_register_connection_type() accepts an associative array as arguments
* removed p2p_list_connected()
* added p2p_delete_connection()
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-4.html)
= 0.3 =
* store connections using a taxonomy instead of postmeta
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-3.html)
= 0.2 =
* UI that supports multiple related posts. props [Patrik Bón](http://www.mrhead.sk/)
* added p2p_list_connected() template tag
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-2.html)
= 0.1 =
* initial release
* [more info](http://scribu.net/wordpress/posts-to-posts/p2p-0-1.html)