Forum Academy Marketplace Showcase Pricing Features

🎛 New plugin - theCountable (now free)

Is there any way to have this Countable plugin display the correct count when the page loads.

For example, if there are 200 words in a multiline input by default, when the page loads Countable is saying there are 0 words. As soon as you edit the input then Countable updates itself and displays the correct count.

Hope you can help as otherwise I’ll be lumbered with having to figure it out with regex :frowning:

@ZeroqodeSupport is there a way to have an option for this plugin to include spaces in the character count? As well as custom modifications… for example:

If I have a tag {firstname} I want it to search my database to find the user’s first name and take that character count instead of displaying the count for {firstname} at 11 characters.

So let’s say the user’s name is John and he uses the tag {firstname} in a text box, I’d want it to count 4 characters instead of 11, because when the app is ran it will pull his first name from the database and count the characters in place of the tag. I know that’s possible through conditional formatting but the delay makes it almost not even worth doing. I’d love to learn to code this myself if you’re open to that also.

Hello there @laflash8, could you please show me the setting of your plugin element and the Input, and the result which you obtaining now.

You may share with me some screenshots, or a video recorded by useloom.com

Thank you,
BR,
Nik.

1 Like

@ZeroqodeSupport

You can see from this image that I have included spaces to be accounted for as well as the actual length of text for a tag using the built in :numberofcharacters function as well as a regex count for \s but it doesn’t update in real time, there is a slight delay.

If you count the characters it would be 28 including spaces, but it shows only 25 because it automatically replaces the count for {FNAME} with the actual value that would be input into it (John).

So 7 characters for {FNAME} and 4 for John, there are 3 less characters represented in the total count because John is 3 characters smaller.

The same can be seen here where the first name is 9 rather than 7 characters and the count is then increased. by 2 overall from 28 to 30.

Hello there @laflash8, you are able to count all the characters in the input with help of plugin state “All”, as you can see in our demo it counts characters with spaces.

And regarding the name replace I suggest you set everything like here, this will be better solution. And everything will be fixed.

Thank you,
BR,
Nik.

@ZeroqodeSupport

Thanks for the input, but due to the way I am planning to use this, it’s not really an option for me to use the search function for my users in the way that I want it to work.

I think I will just add a delay with a loading screen each time a tag is inserted to ensure that the proper length is accounted for.

Does this plugin work with your Rich Text Editor? I cant seem to get it to count the words in the Rich text Editor.

@zeroqode

Hello @hofst038,

Unfortunately no, this plugin is not compatible with Rich Text Editor Elements. theCountable plugin works only with Bubble elements.

Best Regards,
Zeroqode Team

How did you make it count down like in your test? Instead of counting up to 1000 characters yours counts down from 1000

@ZeroqodeSupport I am curious if there is any known issues with the plugin not capturing the count of an input when that input has it’s initial value set based on a conditional?

I have my input and countable element set up as below and it works fine normally:

However, when I am using a conditional to set the initial value of the input as below:

Screen Shot 2020-10-01 at 1.05.51 AM

I am noticing that my conditionals that utilize the countable value are not being registered correctly

Countable

Is there any workaround for this?

Hi @boston85719,

Thanks for pinging us. Please let us check on this usecase with our dev team and get back to you with a reply asap!

Best regards,
Zeroqode Team

Hi @boston85719,

We managed to push an update to this plugin. The problem was setting dynamic data for initial content and it was not seeing it.

Now, you can use plugin’s Get Countable Values action on page load event, but set the condition to check on your input element not to be empty, as this is an important note:

image

And it should run smoothly. Also refresh your page before giving it a try.

Best regards,
Zeroqode Team

1 Like

Thank you for the plugin! Works perfectly on one of my pages.

However, when I add the countable element to a reusable element on an input, it throws an error. Anyone seen this before and knows how to address this? @ZeroqodeSupport

Hey @mazorshimon, I think it’s because the plugin tries to initialize before the pop-up/group loads on the page.

Try this:

  1. In countable settings, make it not visible on page load
  2. Add “a do when condition is true” (Run this: just once)
  3. When X (element) is visible → Show countable

Redu.

1 Like

Thank you for your answer! It actually didn’t work, but I ended up including a countable element on the page itself, which loads the library, and then the reusable countable elements were able to load without error.

However, now the counter itself is not reset when the popup closes and then reappears. Or when the input is dynamically populated in the popup the counter shows 0/150

I attempted to create the workflow the “Get countable values Countable A” but it didn’t solve the proble.

Hi folks,

@yusaney1 thanks for suggestions! It might be a workaround because plugin indeed might not catch up to initialize on page load.

@mazorshimon we are not able to reproduce this error on our side, unfortunately:

But could you please share screenshots and/or screencast of your app with exact steps to reproduce it so we can try on our side and provide a better feedback on this matter. Also, the browser and OS version you are using and what you are trying to accomplish with this plugin.

However, if you want to solve this problem:

Just use plugin’s Get Countable Values action On Page Load event, with a single condition (mandatory!):

Best regards,
Zeroqode Team

1 Like

Hi @ZeroqodeSupport and thanks for the quick response.

I wasn’t able to reproduce my error in a new editor.

With that said I was able to reproduce the second problem on countable not resetting

Here is the editor: https://bubble.io/page?type=page&name=index&id=counter-testing&tab=tabs-6&subtab=General

Let me know what you think?

Thanks,
Shimon

Hi @mazorshimon,

Sorry but what is your project idea and how exactly you are trying to use this plugin? Why would you need to place it into a Reusable Element, could you please explain a bit more on this matter so we can understand whether or not it is possible to use this plugin accordingly. :pray:

Best regards,
Zeroqode Team

Hi @ZeroqodeSupport and thank you for the ongoing support,

I am using a reusable element that holds a popup I have in a few places in the app, hence the use of a reusable element.
The popup is sort of a “Post a message” popup where there is a thing associated with the popup (i.e. a Message) and the input field gets dynamically populated with the message if the user is editing a message, or the field is empty if the user wants to post a new message.

In both cases above I would like to have the field both have a character limit and to have a count under it “0/650 characters”.

When I open the popup to post a new message it displays “0/650”, however, typing anything there and clicking out of the popup does not clear the countable element’s count if I were to open it up again. Wheres it would show an empty input but the count would say for example “11/650”.

I hope this makes sense, and yes having a countable element inside of a reusable element that works as a popup is what I am currently in need of, however, it is not your problem, so it’s ok if it’s just not possible at the moment.

I appreciate your response so far and thank you if you read down to here.
:pray:t3:
Best,
Shimon

Thanks @mazorshimon for details.

We have tweaked your testing project a bit, and made it work with the current setups, but changing a bit the workflow as per our previous instructions.

So first thing is required to actually show the popup and only then display the data. After that, we added a pause before next action so it takes time for the library to load everything, and then use plugin’s action to get Countable Values.

Best regards,
Zeroqode Team

1 Like