Developer Connection
Use this forum to interact with our development team on technical issues, suggestions and official best practices advice.
1,680 topics in this forum
-
- 2 followers
- 10 replies
- 520 views
I have some question to CMS templates included into app: 1. Is it intentional that CMS templates delivered with the application are not removed if application is uninstalled? 2. If it is supposed that deleting must be handled in Uninstall extension manually, how do I know what templates belong to the app? I can see the field template_app in cms_templates table. However there is no value in it for any template. Is there any mapping table or function to get all templates that belong to the app? 3. If the application is uninstalled and the templates are still there and I try to install the application again, I get the error: The error persists until I…
Last reply by bfarber, -
- 1 follower
- 4 replies
- 367 views
I am beginning to think I am unlucky here. So far, just about every IPB install has gone the way of the dinosaur while in development mode. With errors like: [[Template core/admin/global/globalTemplate is throwing an error. This theme may be out of date. Run the support tool in the AdminCP to restore the default theme.]] There is either missing css or missing template files when in developer mode. So far, I have had to reinstall my localhost developer build 5 times and it has just happened again. I didn't even get to the stage of installing my applications or plugins, installed, turned on dev mode and I got the above error. I have downloaded the I…
Last reply by bfarber, -
- 1 follower
- 3 replies
- 373 views
I'm going to use this thread for reporting minor API bugs (still using the forums as my support area is still bugged and I can't submit or reply to support tickets.) POST /api/core/members/{id}/follows :: Does not update the front-facing following counter for content items when a member is added through the API datetime fields do not accept timestamp inputs >>> $r = $api->system()->members()->addWarning(49, ['moderator' => 1, 'reason' => 'For <strong>science</strong>', 'points' => 2, 'memberNote' => 'you food', 'moderatorNote' => 'they food', 'modQueue' => -1, 'expire' => 1601742513]) InvisionApi/E…
Last reply by bfarber, -
- 1 follower
- 1 reply
- 263 views
It is possible to send variables to templates using this exemple code: {template="includeCSS" app="core" group="global" location="global" params="VARIABLES"} Is it possible to send variables to a raw php Pages block? {block="my_block_key" params="VARIABLES"}
Last reply by bfarber, -
- 5 replies
- 283 views
4.5.3 You do not account for all screenshot image copies; specifically you do not move the original not-watermarked screenshot images when those files are watermarked. record_no_watermark is not accounted for during the move process End result is record_location and record_thumb files are moved, but record_no_watermark, the only copy of the screenshot not watermarked, is left behind. If the actual OLD file storage location is still valid, that record_no_watermark file will still be retrieved as the file and url remain valid since they were not moved. Obviously nothing ideal happening here though.
Last reply by bfarber, -
- 1 follower
- 1 reply
- 372 views
The "hide" option when deleting a member via the API does not seem to work as intended. Posts are left visible and unhidden even when specifying this parameter. The delete action works as intended, however.
Last reply by bfarber, -
- 1 follower
- 4 replies
- 308 views
From within a plugin, I want to establish the status of a file storage setting. Is it possible to check what or if a Storage Setting Configuration is set to either local or remote S3 storage for a specific file category (say custom emoji, reactions, or theme resources etc)? If so how can I do this? Many thanks.
Last reply by The Old Man, -
- 5 followers
- 1 reply
- 337 views
XRegExp is 135KB when minified as part of root_library.js (that whole bundle is only 383KB, so it's a significant chunk), but it's only used in two places: In ipsautolink/plugin.js, it's just used to evaluate a native JS regex, which I believe is totally unnecessary (use this.urlRegex.test(text) instead!) In ips.search.results.js, where it's just used to replace using a native JS regex (use $(this).text().replace(new RegExp(...), '...') instead, as you do for each subsequent replacement in that chain) (while you're at it, why does that code replace with HTML, HTML escape everything, then selectively unescape the content you just added?!) Removing those two…
Last reply by bfarber, -
- 1 follower
- 9 replies
- 459 views
I have 2 PHP scripts, One i made to display a table with Variables from a table in MySQL. its just to display, no comments, no ad-dons, no adding, nothing special like that, as the system itself takes changes straight from GitLabs and just posts the changes to our website database. The problem I am having is, i want to be able to display these entries on my site, I got the admin able to remove the entries, but when i try doing the front end (Just to show the values) i keep getting errors cant see database, and such. I am not new to PHP but newer to developing IPBoard Applications, so please bare with me. I have 2 options on my side. Opt…
Last reply by sobrenome, -
- 1 follower
- 3 replies
- 303 views
<?php /** * @brief Notification Options * @author <a href='https://www.invisioncommunity.com'>Invision Power Services, Inc.</a> * @copyright (c) Invision Power Services, Inc. * @license https://www.invisioncommunity.com/legal/standards/ * @package Invision Community {subpackage} * @since {date} */ namespace IPS\{app}\extensions\core\Notifications; /* To prevent PHP errors (extending class does not exist) revealing path */ if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) ) { header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' ); exit; } /** * Notification Options */ class _{class} { /** …
Last reply by bfarber, -
- 2 replies
- 300 views
Hello, when developing my custom Invision applications, useful IDE features (like code completion/navigation) are really hampered by the monkey patching as my IDE can't resolve \IPS\Member to the relevant "_Member" class. Do the internal IPS team (or anyone) have a solution to this? I use the PHPStorm IDE and couldn't find a way to manually configure it to look for these class names. It's quite frustrating when you're used to these IDE features that speed up development... so thought I'd reach out to see if anyone has a solution, or uses a different IDE that can handle this scenario. Thanks!
Last reply by CTRoss, -
- 1 follower
- 5 replies
- 401 views
I'm working on a plugin with a CSS file, and some of the values in this file comes from the plugin settings. What I need is a way to rebuild the CSS files (custom.css?) when the plugin settings are changed. With my current code I'll have to edit my theme and save custom.css (without making any changes) for the new values to show up. There must be a better way?
Last reply by bfarber, -
- 1 follower
- 9 replies
- 396 views
Hey IPS, What is the best way to grab the location of a forum visitor? This is what we are trying to come up with. So we have products in the Store on our forum. The only payment method to buy these products are via PayPal. Some of these products have recurring charges, so the package gets renewed every 30 days, 90 days, or 180 days. However, if the individual lives in Germany, they have PayPal restrictions that prevent them from purchasing recurring products. So I want to grab the location of the user, if they are in Germany then I want to display a message on the store index stating the PayPal restrictions and to only buy the non-recurring products. What is the bes…
Last reply by sobrenome, -
- 1 reply
- 265 views
That's a plugin I just created, nothing on it: No version: Not exactly a bug but can lead us to confusion and export a plugin without version so if the plugin has new table or columns, it won't add without a version.
Last reply by bfarber, -
- 0 replies
- 1.4k views
Folks, please try to pay more attention to the version numbers you're using for your customisations! There's just another upset client who can't upgrade his file via the ACP - Marketplace because the system doesn't recognise the new upgrade release as "upgrade" because the recent version has long version 2800 while the old long version is 24344. I hope everybody here sees the issue?! The newer version is lower than the last version. Another common concern confusing clients and our backend is that some developers started going back with version numbers for their 4.5 releases. So from 1.4.2 ( 104020 ) they went back to 1.0.0 ( 100000 ) Personally, I would sug…
Last reply by Daniel F, -
- 2 followers
- 2 replies
- 381 views
How to filter by additional fields in a template? I cannot understand how to filter by additional fields in the "Featured Records (First page when viewing a database set to show featured articles)" template? Filtering (sorting) is available in the "Categories" template, but I can't do it in the news list ... Prompt or push on the right idea. Thanks in advance.
Last reply by Andrey S, -
- 1 follower
- 2 replies
- 256 views
Firstly, this was in the Tracker but it has been locked for us, so I'm going to post here as I'm not sure it will be addressed as a bug there. Anything I tried to add, in any place of the report template (\IPS\Theme\class_core_front_modcp::report), breaks the layout. Even a single letter or number, anywhere! See: Using: CSS Selector: #elReportSidebar Acition: Insert content inside the chosen element(s), at the start. Now a single letter in the beginning of the template: Basically, doesn't matter where I try to add my content, it always break the layout, reposition the sidebar boxes after the content. Correct view: …
Last reply by Gabriel Torres, -
- 1 reply
- 271 views
/** * Save translatable language strings * * @param string|int|\IPS\Application|\IPS\Plugin $appOrPlugin Application key or Plugin ID So alright, string or int. For plugins hitting the settings method or the uninstall routines will give us the plugin_id via the request var. \IPS\Lang::saveCustom( \IPS\Request::i()->id, 'muh_word', $values['muh_word_setting'] ); If you do that, you're setting things up for a bad time down the road. That will set both the word_app AND word_plugin entries, together, to the plugin_id value instead of NULL, plugin_id respectively. if ( $appOrPlugin instanceof \IPS\Application ) { $appOrPlugin = $appO…
Last reply by bfarber, -
- 1 follower
- 1 reply
- 294 views
I deleted a plugin's hook in the dev center, but it wasn't removed from hooks.json. It was caught by CI for me, but it's obviously not great.
Last reply by Daniel F, -
- 1 follower
- 1 reply
- 317 views
I have a question. How is it possible that a resource has been approved in Marketplace without having been downloaded? Or have you reseted a download number for this?
Last reply by Daniel F, -
- 1 follower
- 0 replies
- 3.9k views
Hi, I wanted to clarify the process for any critical updates you may need to make that may potentially need a higher priority when it comes to a review. A critical issue would be something that causes a large impacting issue to your resource, such as a fatal error that prevents it from working. Submit the new version of your resource with only the fix for the issue, no other bug fixes or enhancements. Specify in the change log what the fix is for (so it's obvious to us what you are fixing). Submit a support ticket asking for an expedited review. Asking for an expedited review doesn't guarantee we'll be able to do it, but we'll try our best whe…
Last reply by Stuart Silvester, -
- 1 follower
- 0 replies
- 2k views
Hi and welcome to our new series of updates for our contributors. We'll highlight the most common mistakes, ways to resolve them and also generic improvement suggestions once a month here:) As first, I want to apologies that some files took really long to get approved, but we really expected that new submissions and upgrades would have a better quality, but unfortunately >60% of the submissions ( 90% in the first week) were still not following the new marketplace guidelines, which resulted in a devils circle. Let's recap the last months issues resulting in rejections🙂 Core Database changes. Version details not changed. Us…
Last reply by Daniel F, -
- 1 follower
- 6 replies
- 755 views
I use `\IPS\Node\Model` to manage some things in my application, yet any time I save the form I get a CSRF error. I looked into the Security Considerations documentation and it only mentions that calling `$form->values()` will automatically handle CSRF, but it also only explains how to use CSRF for URLs, which aren't used with `\IPS\Node\Model` subclasses. The nodes example also doesn't mention anything about CSRF.
Last reply by MrFisc, -
- 3 followers
- 6 replies
- 361 views
I ran into probably a very "use" case scenario here, but here are the details. I was updating my app names 2 avatar, since we aren't allowed to append columns to the core tables any longer, i decided to move the columns i was appending to core tables to their own table, and then do a join onto that table for \IPS\Members\Clubs, \IPS\downloads\File and \IPS\Member. however this is where i ran into my problem. Since i had already had hooked these 3 classes in previous version of the app, the hooks were active at the time of an upgrade. however with how the hooking system works, the hook is eval'ed from the contents of the files found in applications/myapp/hooks/*…
Last reply by bfarber, -
- 1 follower
- 2 replies
- 485 views
All of the following testing was done on a production style ICS installation without `IN_DEV=true` or the developer toolset installed. It was just a naked ICS 4.5 installation with only my application installed as a third party application. The hook in question: //<?php /* To prevent PHP errors (extending class does not exist) revealing path */ if ( !defined( '\IPS\SUITE_UNIQUE_KEY' ) ) { exit; } class ts3integration_hook_AppLogo extends _HOOK_CLASS_ { /* !Hook Data - DO NOT REMOVE */ public static function hookData() { return array_merge_recursive( array ( 'appmenu' => array ( 0 => array ( 'selector' => '#acpAppList', '…
Last reply by Ryan Ashbrook,