Place to put your Basic demos and examples

Moderator: Mmiscool

User avatar
By tcontrada
#49492 I think what is really needed is a real toggle button, rather than an image button. Basically a CSS modified HTML checkbox to toggle a digital output via websockets. This way there is no refresh as the checkbox changes state within the browser.

Can a checkbox/toggle button be included in the web GUI components?
User avatar
By cesare2a
#51279 Hello
I'm a french user.
I have a problem to use : imagebutton
the example doesn't worh on my ESP8266 and i don't no why !
It's impossible to display the file.
my ESP8266 is programmed with basic 3.0
Somebody can help me ?
thank you.
Cesar
User avatar
By forlotto
#51307 tcontrada have you tried to use v2.24 and use a javascript based toggle or html toggle possibly I am not really sure on the code off the top of my head but java is an on click event.

What about just making a phone application and using say an android toggle.

I see your point a toggle button something standard and baked in would be kind of neat but I really don't believe the reaction is going to be much quicker or smoother.

The kicker if you want quicker response use a button sized toggle as small as you can get in file size. And make your code as efficient as possible as well it may be possible that some SPI flash has better latency on read and writes as well so you may want to consider a hardware upgrade if that is true.

@cesare2a
What version of basic are you using?
What version of chip are you using esp12e nodemcu etc..?

Could you upload the images you are trying to display?

This will all help also share with us your code.

I will test and let you know if it works.