Content Type
Downloads
Release Notes
IPS4 Guides
IPS4 Developer Documentation
Invision Community Blog
Development Blog
Deprecation Tracker
Providers Directory
Forums
Events
Store
Gallery
Posts posted by Nathan Explosion
-
-
Thank you - I'm unable to reproduce the issue based on your configuration, and viewing as a guest (feel free to go to here to see it in effect)
24 minutes ago, Dru Vagale said:2. As we are checking through as guest, so we don't have any frontend-settings for guest
As you've offered up this information, I have to ask whether clicking the notice work when you are logged in?
Looking at your site, I am going to point out that there is a general Javascript-related error in the developer console, which is likely to have a knock-on effect on the JS functionality used when the notice is clicked on:
24 minutes ago, Dru Vagale said:FYI, we have also checked in the default theme
Can you make the Invision default theme available to Guests, please, as I'd like to verify something myself.
-
A link to that page would be helpful here, as that doesn't look like the default theme so I'd need to see the actual page (if page is behind a login, send me a link plus authentication credentials via PM)
In addition:
- What are the setting in place in the ACP?
- Same with your own front-end settings, via the "Account Settings", if you have enabled that functionality.
-
X tables in one block (X = 1 or more...just edit the 'tableIds' array to put the IDs in place)
<table id="table1"> <thead> <tr> <th>Item</th> <th>Variable 1</th> <th>Variable 2</th> <th>Variable 3</th> <th>Variable 4</th> <th>Variable 5</th> <th>Variable 6</th> <th>Total</th> </tr> </thead> <tbody> <tr> <td>Item 1</td> <td>1</td> <td>0</td> <td>0</td> <td>0</td> <td>0</td> <td>0</td> <td></td> </tr> <tr> <td>Item 2</td> <td>0</td> <td>1</td> <td>0</td> <td>0</td> <td>0</td> <td>0</td> <td></td> </tr> <tr> <td>Item 3</td> <td>0</td> <td>0</td> <td>1</td> <td>0</td> <td>0</td> <td>0</td> <td></td> </tr> <tr> <td>Item 4</td> <td>0</td> <td>0</td> <td>0</td> <td>1</td> <td>0</td> <td>0</td> <td></td> </tr> <tr> <td>Item 5</td> <td>0</td> <td>0</td> <td>0</td> <td>0</td> <td>1</td> <td>0</td> <td></td> </tr> </tbody> </table> <table id="table2"> <thead> <tr> <th>Item</th> <th>Variable 1</th> <th>Variable 2</th> <th>Variable 3</th> <th>Variable 4</th> <th>Variable 5</th> <th>Variable 6</th> <th>Total</th> </tr> </thead> <tbody> <tr> <td>Item 1</td> <td>1</td> <td>0</td> <td>0</td> <td>0</td> <td>0</td> <td>0</td> <td></td> </tr> <tr> <td>Item 2</td> <td>0</td> <td>1</td> <td>0</td> <td>0</td> <td>0</td> <td>0</td> <td></td> </tr> <tr> <td>Item 3</td> <td>0</td> <td>0</td> <td>1</td> <td>0</td> <td>0</td> <td>0</td> <td></td> </tr> <tr> <td>Item 4</td> <td>0</td> <td>0</td> <td>0</td> <td>1</td> <td>0</td> <td>0</td> <td></td> </tr> <tr> <td>Item 5</td> <td>0</td> <td>0</td> <td>0</td> <td>0</td> <td>1</td> <td>0</td> <td></td> </tr> </tbody> </table> <script> const tableIds = ['#table1','#table2']; let table, rows, rowTotalCell, cells, total, totalCell; tableIds.forEach(myTable => { table = document.querySelector(myTable); if(table !== null){ rows = table.querySelectorAll('tbody tr'); rowTotalCell = document.getElementById('rowTotal'); rows.forEach(row => { cells = row.querySelectorAll('td'); total = 0; cells.forEach((cell, index) => { if (index > 0 && index < cells.length - 1) { total += parseFloat(cell.textContent); } }); totalCell = row.querySelector('td:last-child'); totalCell.textContent = total.toFixed(0); }); } }); </script>
-
1 minute ago, My Sharona said:
I tried leaving the 'table id' the same (in both places, within a block)
Well, that's a definite no-no.
2 minutes ago, My Sharona said:Just a FYI here
Do you need assistance with trying to figure that one out, or is literally just an 'FYI'?
-
33 minutes ago, My Sharona said:
if (index === 1 || index === 2 || index === 3 || index === 4 || index === 5 || index === 6) { total += parseFloat(cell.textContent); }
That makes me twitch.
Change it to:
if (index > 0 && index < cells.length - 1) { total += parseFloat(cell.textContent); }
-
Show your modified code...
And maybe look at what the JS function toFixed() does, as that may give you a clue at to what that 2 is for.
On 8/17/2023 at 11:25 AM, Nathan Explosion said:totalCell.textContent = total.toFixed(2);
-
-
39 minutes ago, Carole Asselin said:
Well, just before I purchased the plugin, someone in my community pointed out that by simply highlighting the text in the other language, one could right-click and get the option to translate, right there and then.
Good - the resource is overkill for your situation, really, and is the reason I stepped in to go against the suggestion of it for your use-case. As I said in this post - browser support is making it defunct really.
-
BOOM - thanks mate.
-
Any chance of getting this reset, please?
-
I'm currently unable to use MFA as a result of it claiming I have failed authentication too many times (see screenshot) even though entering the correct code as per Google Authenticator.
You appear to require an admin to reset this, so can you please do so, or advise how long I will need to wait to be able to try again?
-
Interesting - works for a short while, then complains about the table selector.
Few mins...
and code updated - changed order of JS/HTML to HTML/JS
-
Page Builder: Text
Literally a copy/paste of the relevant code, with a slight modification to how the table is selected in the Javascript code. Free free to add your style to it.
<table id="thisismytable"> <thead> <tr> <th>Identifier/Product</th> <th>Column 1</th> <th>Column 2</th> <th>Total</th> </tr> </thead> <tbody> <tr> <td>Item 1</td> <td>17</td> <td>24</td> <td></td> </tr> <tr> <td>Item 2</td> <td>13</td> <td>2</td> <td></td> </tr> </tbody> </table> <script> const table = document.querySelector('#thisismytable'); const rows = table.querySelectorAll('tbody tr'); const rowTotalCell = document.getElementById('rowTotal'); rows.forEach(row => { const cells = row.querySelectorAll('td'); let total = 0; cells.forEach((cell, index) => { if (index === 1 || index === 2) { total += parseFloat(cell.textContent); } }); const totalCell = row.querySelector('td:last-child'); totalCell.textContent = total.toFixed(2); }); </script>
-
Show your actual used code - what you are actively using in the block.
-
1 hour ago, My Sharona said:
I am trying to add it to a Page Builder: Text Block
OK - so what actually happens when you try?
That code works as expected as HTML page - so how have you taken that code and implemented it? What happens when you try? What is your own code?
Or are you looking for someone to convert that for you?
And isn't a "Text block" just that - a block for adding simple text to a page? Does it allow HTML/Javascript?
-
Just now, Carole Asselin said:
So this is something that each user would have to install, correct?
If you are referring to the items I linked to - yes, those are browser extensions.
-
8 minutes ago, Carole Asselin said:
Does that allow any user to translate the particular post? Or just admins?
It allows whichever group you provide permission to.
However - in this day, you may not even need it as native browser functionality is become more prevalent:
https://www.deepl.com/en/chrome-extension
https://blog.mozilla.org/en/mozilla/local-translation-add-on-project-bergamot/
-
1 minute ago, Esther E. said:
It's slightly frustrating to see people over and over again insist that things aren't going to work because we won't have hooks, after we've gone through so much trouble to make sure that people can continue to do most of the things they currently do.
But Adriano only stated that hooks won't be possible for what he wants to do...that is all. It's his use-case, he's identified what is possible in v4 and identified that that specific approach won't be possible, and then identified another possible approach.
Daniel overreacted; disagree if you wish. No skin off my nose.
-
7 minutes ago, Daniel F said:
How do you know this? Have you seen v5 yet? Have you read about all upcoming dev related changes? I guess the answer is no, so please stop posting this constant false claims and FUD about v5 until you see at least the first public alpha..
Mate - you've misread his comment; he's clearly talking about hooks. And he followed it up with a possible option in v5.
-
Spotted that there are some x.com/ URLs now appearing for the normal tweet links - as a result, oembed will fail and they'll be links.
'twitter.com' => array( 'https://publish.twitter.com/oembed', static::EMBED_TWEET ), 'mobile.twitter.com' => array( 'https://publish.twitter.com/oembed', static::EMBED_TWEET ),
Tested and adding x.com equivalents of the above to oembedServices in \IPS\Text\Parser will sort it out.
'x.com' => array( 'https://publish.x.com/oembed', static::EMBED_TWEET ), 'x.twitter.com' => array( 'https://publish.x.com/oembed', static::EMBED_TWEET ),
-
34 minutes ago, My Sharona said:
I have a table
A SQL table?
A Pages database table?
A form helper table?
What is the code?
-
5 minutes ago, Christian Meixner said:
But I hesitate to buy this one because of market place closure and unclear support of future version of Invision Community
Why? If you had enquired with me, I would advise you that the application will continue to be provided and supported by myself. And "unclear support of future version of Invision Community" is unknown at this time, so can't be answered by myself until we get hands on the software.
- Joel R and Christian Meixner
- 2
-
36 minutes ago, mtlurb said:
passed to the cloud offering
Plus there is that, so...
-
7 minutes ago, SeNioR- said:
Why?
(NE) Content Warnings
in Marketplace
Posted · Edited by Nathan Explosion
OK - I think one of your own customisations is having a knock-on effect on the Javascript that my application utilises, and here is why I believe this (You've got ability for Guests to post so can check this)
That is this field, which is clearly not set with that class at the time of page load:
Unfortunately, I think something early on is resulting in my JS not even running
If you can present a page to me that has none of your own customisations on it (disable other 3rd party apps/plugins, set the default theme, etc) and reproduce the issue then I am happy to take a further look.