• Welcome to Tux Reports: Where Penguins Fly. We hope you find the topics varied, interesting, and worthy of your time. Please become a member and join in the discussions.

General

LPH
Views
2K
Reaction score
2
Comments
1
Technology
PhpMyAdmin is a great tool. It's included with MAMP Pro and I've used it for years. However, work on the Classroom Laravel project provided me an opportunity to branch out today into Sequel Pro in order to learn more about MySQL tables.* My naive understanding is Sequel Pro can help build...
LPH
Views
3K
Reaction score
2
Comments
4
Technology
The file WPPostsWide.php was placed in the community/library/TRN/XenWord/Model directory. <?php /** * Filename: WPPostsWide.php * Author: LPH */ class TRN_XenWord_Model_WPPostsWide extends XenForo_Model { public static function getHtml() { define( 'WP_USE_THEMES', false )...
LPH
Views
2K
Reaction score
2
Technology
The get_posts function has many arguments which allow a developer to pull from the meta table. <?php $args = array( 'posts_per_page' => 5, 'offset' => 0, 'category' => '', 'category_name' => '', 'orderby' => 'date', 'order' =>...
LPH
Updated
5.00 star(s) 1 ratings
Views
3K
Reaction score
2
Comments
3
Reviews
1
Technology
The Post Ratings addon by Luke is an essential XenForo addon. Basic XenWord support for the addon was included in April 2015, release 2.5.0 ( number 78 ) and the last changes were made in March 2016. Since support has been limited to showing likes on the WordPress side then I've been trying to...
LPH
Views
2K
Reaction score
2
Comments
1
Technology
The new WordPress widget for showing the latest threads in a wide view is now included in XenWord 3.3. The widget is live on the front landing page of the website. Even though this widget was built a few days ago, I changed the coding today to respect the User permissions. If a forum is hidden...
LPH
5.00 star(s) 1 ratings
Views
5K
Reaction score
1
Reviews
1
Technology
A widget for showing the latest blog entry was added to XenWord 3.3 and is live on this site. This is the first row of the main loading page on the WordPress side. The CSS is not included in the xenword-public.css file and is very easy to add in the customizer CSS available in WordPress 4.7...
LPH
Updated
Views
2K
Technology
The setup_postdata() function confused me for a bit. The examples on the WordPress Codex page didn't seem to explain why using setup_postdata() could be useful. Specifically, there is no difference in the var_dump using $post in example 1. After running a few different tests, it became clear...
The featured thread and forum widgets have been reworked. The select dropdown is populated with information pulled from a model rather than from a direct query to the database. The parsing of the featured thread has also been changed. Several div tags were added so that the overall look of the...
A very simple XenWord widget returns a list of forums based on a selection of the forum category. The first version had too many sql queries and so I rewrote the widget today. Other widgets are on my list to also fix. The original version used two sql queries. /** @var $node_qry...
The XenWord Settings Panel, Dashboard widget, and Board Totals widget now match in sequence and options. Links to the add-ons are now included in the init.php file for the Settings Panel. These options mainly turn on the board totals and dashboard community statistics widgets. Plans are still...
There are 24 files included in the Widget System. Several have not been touched in months, others are using procedural calls, and others are using poor code to pull threads. Two files regarding XenReviews will be deprecated soon. Work on widgets continued tonight: All of the widget file names...
I started working on widgets the other day. A goal for XenWord 3.3 is for the widgets to be consistent in six key areas: Use ob_start() PHP 5.3 hook $fetchOptions and $conditions Views return $instance or 'no form' proper class naming (match file name and class name) The use of $fetchOptions...
While tinkering with new code on a test project, I asked Bob from Xen Addons for some advice and help. His answers led to more questions, however, there were several gold nuggets in the answers. Due to my reliance on var_dump, the treasure was missed until this morning when I used print_r...
The login widget included with XenWord allows webmasters to integrate Twitter, Facebook, and Google. Unfortunately the code is terrible and I've been wanting to fix it. Currently, the widget file must be opened and the Google code and secret must be modified. I'll try to pull this information...
Even though I'm still going through the widgets, I started looking at this method in the class XenWord_XF_Users, which strangely sits in the file name class-xenword-add-wpusers.php. This needs to be fixed. I quickly decided the method breaks way too many of my new coding guidelines that were...
LPH
Views
2K
Reaction score
1
Comments
3
Technology
It's been quite some time since looking at widgets. Before opening PhpStorm, I was thinking this might be an opportunity to use Views. After opening PhpStorm and reading about WP_Widget::form on the developer documentation site, I quickly saw the return 'noform' was missing in the majority of...
XenForo 2.0 is being completely rewritten. It's a huge project and will have an impact on addon development. The XF Development Team will release a developer version and allow addon developers the opportunity to learn how the 2.0 will influence addon development. On the 2.0 alpha demo site...
Instead of using a deactivation hook or the register_uninstall_hook, XenWord has an uninstall.php file that runs automatically if a user deletes the XenWord plugin. This was rewritten this afternoon to include a conditional for checking if the column exists. <?php /** * Filename...
Purpose The bootstrap file for WordPress plugins can be done in many different ways. I recently changed the PHP file but am always on the lookout for a better way. Considerations Proper Hook No God Class (Uh oh.) No hooks in constructors Use Namespaces Don't mix types (Interfaces, Classes)...
The PHP Documentation Site is the first place to look for OOP information An awesome list of resources on GitHub
Top