[AP] Style Suite

[AP] Style Suite [Paid] 2.11.9

No permission to buy (€15.00)
If I upload a postbit cover that isn't too wide and save it, I'm getting a strange issue where it distorts and stretches so that it essentially shows a fraction of the image as the whole postbit. As seen below, it appears to just be a beige background, when attached is what was working just fine as a background not long ago...
Sorry pal I only ended up seeing this now. Do you know what image backend DH has set (GD or ImageMagick)? I did actually encounter a similar issue using ImageMagick when I was trying to resize rank images from a game as username icons, but since those were the only images that showed issues I figured it was down to something the game devs had done to the images.
If you could send me the original image you tried to upload I'll try have a look soon.
 
Sorry pal I only ended up seeing this now. Do you know what image backend DH has set (GD or ImageMagick)? I did actually encounter a similar issue using ImageMagick when I was trying to resize rank images from a game as username icons, but since those were the only images that showed issues I figured it was down to something the game devs had done to the images.
If you could send me the original image you tried to upload I'll try have a look soon.
It's ImageMagick, the original is attached to my first post :)

I appreciate you taking a look!
 
@apathy when I go to edit a profile in the admin panel, i get this error and it won't let me edit any users:
Error: Call to a member function isUpdate() on null in src/addons/apathy/StyleSuite/XF/Service/Message/Preparer.php at line 22
  1. apathy\StyleSuite\XF\Service\Message\Preparer->prepare() in src/addons/XFMG/XF/Service/Message/Preparer.php at line 11
  2. XFMG\XF\Service\Message\Preparer->prepare() in src/addons/SV/UserMentionsImprovements/XF/Service/Message/Preparer.php at line 23
  3. SV\UserMentionsImprovements\XF\Service\Message\Preparer->prepare() in src/XF/CustomField/Set.php at line 185
  4. XF\CustomField\Set->set() in src/XF/CustomField/Set.php at line 105
  5. XF\CustomField\Set->bulkSet() in src/XF/Admin/Controller/User.php at line 332
  6. XF\Admin\Controller\User->XF\Admin\Controller\{closure}() in src/XF/Mvc/FormAction.php at line 164
  7. XF\Mvc\FormAction->run() in src/XF/Admin/Controller/User.php at line 517
  8. XF\Admin\Controller\User->actionSave() in src/XF/Mvc/Dispatcher.php at line 350
  9. XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 257
  10. XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.php at line 113
  11. XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 55
  12. XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2344
  13. XF\App->run() in src/XF.php at line 512
  14. XF::runApp() in admin.php at line 13


image_2022-08-23_161102073.webp
 
@apathy when I go to edit a profile in the admin panel, i get this error and it won't let me edit any users:
TY for the report, I actually had another admin report this exact error, but the context to trigger it was different (they were hitting the error when trying to edit the first post in a thread).
Unfortunately I can't seem to reproduce it in either case, but I'll have a mess around tomorrow and try get a quick hotfix out then.
 
I upgraded to 2.9.3 and the edit user bug I had seems fixed. I did see one more minor issue, however, when I try to edit a custom user style (like Postbit, etc) from the ACP, if that feature is disabled, I get a "opps, ran into some problems" and below that, "Loading....". I was able to close the dialog, and it didn't produce any server errors. Looks like just a cosmetic bug. :)
 
apathy updated [AP] Style Suite with a new update entry:

2.9.4

Changelog​

  • Fix "Please enter a valid ID" message when editing a profile block
  • Fix avatar frame list not appearing in the dropdown of the admin user editor
  • Create sizemaps for postbit & username icon upload services
  • Create disable Custom Post Style checkbox (currently ignores default bbcode option until a future update)
  • Hide tabs in admin user editor if relevant style option is disabled
  • Clean up apPostbits registry column during...

Read the rest of this update entry...
 
Hello. Does this addon allow styles to be defined as items that users can unlock, or can everyone style the profile as they wish?
 
Hello. Does this addon allow styles to be defined as items that users can unlock, or can everyone style the profile as they wish?
Sorry pal, only saw this now - there's no built in "reward" functionality as such but if there was an existing reward addon that worked off Xenforo's permission system then this should work just fine with it.
I'd recommend holding off on buying the addon for another update or two, still trying to work out some issues with it.

@apathy -- We're still having some strange alignment issues, could you take a peek at https://discussionhub.io/threads/postbit-cover-questions.4531/page-3#post-57527 just to see what we're seeing. It's just ever so slightly misaligned.
It might be a good idea to replace the position radio row with sliders (like what's available for the opacity/brightness/contrast options), that way one could position the image exactly how they wanted.
I don't think that'd be a difficult change to make either, but unfortunately it wont make it into the next update.

In the meantime you can put background-position: X%, where X is whatever value you want, into the CSS box, but yeah it'd be nice to not have to resort to that.

EDIT: as far as the "stretching" goes, still not had a proper chance to look at that - I know it only happens with ImageMagick but possibly it happens on PHP < 8.1
 
Last edited:
apathy updated [AP] Style Suite with a new update entry:

2.9.5

  • [Cleanup] Use traits for the public controller settings
  • [Cleanup] Create macros for certain style settings (colors, glows, bold/italic/underline)
  • [Cleanup] Massively reduce JS & template code required for the previews to work
  • [Cleanup] Use traits for templater functions
  • [Cleanup/Fix] Revert to old postbit injection method - postbit container is now limited to the width of the user info block, rather than the entirety of the message container
    • Use...

Read the rest of this update entry...
 
apathy updated [AP] Style Suite with a new update entry:

2.9.6

  • [Cleanup] Combine some template modifications and apply them to more suitable templates
  • [Fix] ap-ss-postbitFilter class doesnt always fill the entire height of the postbit
  • [Feature] Add "Postbit background blur" option
  • [Fix] Long-standing issue where you couldn't tag users in Siropu Chat 2 if they had certain username effects applied
  • [Cleanup] Add a "Profile block settings" link to the visitor menu
  • [Fix] Addon-provided assets no longer soft-delete...

Read the rest of this update entry...
 
Running 2.9.6, a user said he could not register an account; I noticed this error in the logs, and once I disabled the app, it worked fine.

Code:
Server error log
XF\Db\Exception: MySQL statement prepare error [1054]: Unknown column 'ap_post_style' in 'field list' src/XF/Db/AbstractStatement.php:230
Generated by: Unknown account Nov 23, 2022 at 12:41 PM
Stack trace
INSERT  INTO `xf_user` (`visible`, `activity_visible`, `user_group_id`, `timezone`, `language_id`, `last_summary_email_date`, `username`, `email`, `user_state`, `privacy_policy_accepted`, `terms_accepted`, `dbtech_shop_purchase`, `display_style_group_id`, `secondary_group_ids`, `secret_key`, `user_id`, `username_date`, `username_date_visible`, `style_id`, `permission_combination_id`, `message_count`, `question_solution_count`, `alerts_unviewed`, `alerts_unread`, `conversations_unread`, `register_date`, `last_activity`, `trophy_points`, `avatar_date`, `avatar_width`, `avatar_height`, `avatar_highdpi`, `gravatar`, `security_lock`, `is_moderator`, `is_admin`, `is_staff`, `is_banned`, `reaction_score`, `vote_score`, `custom_title`, `warning_points`, `dbtech_credits_credits`, `dbtech_credits_lastdaily`, `dbtech_credits_lastinterest`, `dbtech_credits_lastpaycheck`, `dbtech_credits_lasttaxation`, `dbtech_mail_defaultkeyword`, `dbtech_mail_inactivereminder`, `dbtech_mail_numreminders`, `dbtech_mail_newsletter_frequency`, `dbtech_mail_newsletter_receive`, `dbtech_mail_newsletter_lastreceive`, `dbtech_mail_validation_date`, `dbtech_shop_purchases`, `dbtech_shop_immunity`, `dbtech_shop_pendingtrades`, `dbtech_shop_item_count`, `siropu_chat_room_id`, `siropu_chat_conv_id`, `siropu_chat_rooms`, `siropu_chat_conversations`, `siropu_chat_settings`, `siropu_chat_room_join_time`, `siropu_chat_status`, `siropu_chat_is_sanctioned`, `siropu_chat_message_count`, `siropu_chat_last_activity`, `xa_ams_article_count`, `xa_ams_series_count`, `xa_ams_comment_count`, `xa_ld_item_count`, `xfmg_album_count`, `xfmg_media_count`, `xfmg_media_quota`, `tlg_total_own_groups`, `tlg_badge_group_id`, `andrew_user_note_count`, `fake_deleted`, `user_disable_id`, `useress_tags`, `ap_username_style`, `ap_title_style`, `ap_post_style`, `ap_tooltip_style`, `ap_frame`, `ozzmodz_badges_badge_count`, `ozzmodz_badges_cache`, `ozzmodz_badges_last_award_date`, `snog_forms`) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
------------

#0 src/XF/Db/Mysqli/Statement.php(198): XF\Db\AbstractStatement->getException('MySQL statement...', 1054, '42S22')
#1 src/XF/Db/Mysqli/Statement.php(41): XF\Db\Mysqli\Statement->getException('MySQL statement...', 1054, '42S22')
#2 src/XF/Db/Mysqli/Statement.php(56): XF\Db\Mysqli\Statement->prepare()
#3 src/XF/Db/AbstractAdapter.php(96): XF\Db\Mysqli\Statement->execute()
#4 src/XF/Db/AbstractAdapter.php(220): XF\Db\AbstractAdapter->query('INSERT  INTO `x...', Array)
#5 src/XF/Mvc/Entity/Entity.php(1516): XF\Db\AbstractAdapter->insert('xf_user', Array, false)
#6 src/XF/Mvc/Entity/Entity.php(1248): XF\Mvc\Entity\Entity->_saveToSource()
#7 src/XF/Service/User/Registration.php(301): XF\Mvc\Entity\Entity->save()
#8 src/XF/Service/ValidateAndSavableTrait.php(42): XF\Service\User\Registration->_save()
#9 src/XF/Pub/Controller/Register.php(426): XF\Service\User\Registration->save()
#10 src/addons/OzzModz/Spaminator/XF/Pub/Controller/Register.php(166): XF\Pub\Controller\Register->actionRegister()
#11 src/XF/Mvc/Dispatcher.php(352): OzzModz\Spaminator\XF\Pub\Controller\Register->actionRegister(Object(XF\Mvc\ParameterBag))
#12 src/XF/Mvc/Dispatcher.php(259): XF\Mvc\Dispatcher->dispatchClass('XF:Register', 'Register', Object(XF\Mvc\RouteMatch), Object(OzzModz\Spaminator\XF\Pub\Controller\Register), NULL)
#13 src/XF/Mvc/Dispatcher.php(115): XF\Mvc\Dispatcher->dispatchFromMatch(Object(XF\Mvc\RouteMatch), Object(OzzModz\Spaminator\XF\Pub\Controller\Register), NULL)
#14 src/XF/Mvc/Dispatcher.php(57): XF\Mvc\Dispatcher->dispatchLoop(Object(XF\Mvc\RouteMatch))
#15 src/XF/App.php(2353): XF\Mvc\Dispatcher->run()
#16 src/XF.php(524): XF\App->run()
#17 index.php(20): XF::runApp('XF\\Pub\\App')
#18 {main}


Request state
array(4) {
  ["url"] => string(18) "/register/register"
  ["referrer"] => string(23) "https://mysite.com/"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(18) {
    ["_xfToken"] => string(8) "********"
    ["010956ca9cf075a8fd04aef9e66d4e571a4e43b3"] => string(11) "billythekid"
    ["url"] => string(0) ""
    ["94055e2d3992bd24f87cd4f789c4e42d3cebe883"] => string(18) "mysite.com"
    ["6f9937537627c6d9e35be3bf75e80aafc66f5588"] => string(8) "********"
    ["password_confirm"] => string(8) "********"
    ["additional_security"] => string(0) ""
    ["dob_month"] => string(1) "9"
    ["dob_day"] => string(2) "24"
    ["dob_year"] => string(4) "1970"
    ["g-recaptcha-response"] => string(548) "03AEkXODBi6HQ-5s4WOBct5CAjfqLjrA05XV-mGhvPSIa25xq9rrkXwzPw2nip93Jz-V7VVUogX0S1c6Y4Ty7jFQNjTod5LwW7fyf7pxDnz_OhaRcUFL4btLkdttZUXZyIDb6H231RXwbAxq7-GzHEbawQWGjRe9pfXnLgCCJJHHbVoH6YlwUCoHi9L2uo4-gRoNwsLEoCoBz8ZWseLFDqharxs4f0CuokH6giXhPgXY_35I67TNNt9g_sctiqdR4jFRp2Pb-J8hHAthGEkzJsvXfRD2Mv1sdxvp6W-VdNUJEuFfUqKuQRq7T8vxL8yIEJmOBI10BKsqQ66Q252gw1RtDSNdWoiNgIbSVDUfpBVHEjTcWFyWziTxYJtM0BGEZ3dQCSBVG7MYtstVbISa9B9dOWo0QqH87qmVD7pjqD4RoDqRSLSWm-tcgdcp5FJt312db4R5RLRbor-aGy_h0Wfgh7Lkf76VySE0omXHDV0OyVRcZkWIyvllBdHS3ej_T05_mPl_nhso0LsEAssoLffOFY6Jy0TiI74w"
    ["accept"] => string(1) "1"
    ["website_code"] => string(0) ""
    ["reg_key"] => string(16) "iZNRTyy1UFpt5Mow"
    ["fa6b2c1002999c42ddb7d71f5313f945e5c476a5"] => string(14) "America/Denver"
    ["_xfRequestUri"] => string(1) "/"
    ["_xfWithData"] => string(1) "1"
    ["_xfResponseType"] => string(4) "json"
  }
}

 
Running 2.9.6, a user said he could not register an account; I noticed this error in the logs, and once I disabled the app, it worked fine.

snip
This is strange because not only have registrations been working fine on my own site but there hasn't been any work done to the Post styles in a while now if I'm remembering correctly.
Was this site running perhaps a reasonably older version, and was then upgraded to 2.9.6? In other words, the upgrade wasn't directly 2.9.5 -> 2.9.6?
 
@NobleMan this is gonna be solved in the next update but since I can't exactly say when that will be, you can solve this by running an SQL query in PHPMyAdmin. If you click into the xf_user table and then click the SQL tab, you can paste this and it'll create the missing column:
ALTER TABLE `xf_user` ADD `ap_post_style` BLOB NULL DEFAULT NULL;
 
Top Bottom