• 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.

XenWord Development: Bridging the Gap

LPH
Views
2K
Reaction score
1
Comments
1
Technology
This code has me excited. Most XenWord classes reuse the same code for calling the options in WordPress database. class Post { protected $options; /** * Post constructor. */ public function __construct() { $this->options = get_option( 'xenword_options' ); }...
LPH
Views
2K
Reaction score
1
Technology
XenForo thread prefixes were challenging to add to a widget. This is because a var_dump of the $prefixTitle was returning thread_prefix_. object(XenForo_Phrase)[255] protected '_phraseName' => string 'thread_prefix_1' (length=15) protected '_params' => array (size=0) empty...
LPH
Views
3K
Reaction score
1
Comments
1
General
This week has been all about trial-and-error, reading, watching tutorials, and finally asking why code is failing. It turned out to be a silly error in not using the Fully Qualified Name (FQN) in a conditional. And now I'm sitting relaxed, smiling, and gleefully looking at the horizon. It's...
LPH
Views
1K
Reaction score
1
General
The last released version of XenWord included a new checkbox option, replacing the use of "allow comments" as the conditional. This works well for people who rely on promoting threads. This morning, I was exchanging forum posts with someone who was explaining the default off position made...
LPH
Views
268
Reaction score
1
General
A new widget was developed for XenWord 3.3.3 which shows the comments of a WordPress post sorted by the number of likes. I couldn't figure out a way to do this with a model, therefore, a replies queries was created and used to fetch all of the values. These replies were sent through a simple...
LPH
Views
1K
Reaction score
3
Comments
1
General
Early versions of XenWord automatically created a thread. Some customers asked for the allow comments to be used as a conditional for creating the thread. If unchecked then XenWord would not create the thread. This created confusion for some people who simply wanted an option available to...
LPH
Views
1K
Reaction score
1
General
There are days in which coding becomes a series of starts and stops. Create or Edit Thread What seemed like a simple idea has turned into doubt about the need for such an option. Adding a checkbox to decide whether to create or edit a thread started out fine last week. I was able to get the...
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
Updated
5.00 star(s) 1 ratings
Views
2K
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
1K
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...
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...
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
1K
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...
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...

Blog information

Author
LPH
Blog entries
22
Last update

More entries from LPH

More blogs from LPH

Top