Recent

Author Topic: Invoke java script  (Read 1175 times)

michoux

  • Full Member
  • ***
  • Posts: 112
Invoke java script
« on: July 08, 2020, 03:35:32 pm »
Hello,

I have a web page with some javascript.
Is it possible to call some javascript code for this web page from Lazarus?

PascalDragon

  • Hero Member
  • *****
  • Posts: 5444
  • Compiler Developer
Re: Invoke java script
« Reply #1 on: July 09, 2020, 09:22:02 am »
You can either embed a browser in your application or you essentially need to use your own JS interpreter which can be done for example by using the libsee library for which headers are provided by FPC (plus a how to) or you can use the full Pascal JS engine BESEN.

yus

  • Jr. Member
  • **
  • Posts: 57
Re: Invoke java script
« Reply #2 on: July 09, 2020, 09:00:57 pm »
I know that it is possible to execute code written in python. https://wiki.freepascal.org/Using_Python_in_Lazarus_on_Windows/Linux
I also know that it is possible to execute javascript in python.

Maybe this way will help solve your problem.

I myself have not tried to do this.

If you achieve any results, it will be very interesting to know about it.  :)
« Last Edit: July 09, 2020, 09:05:22 pm by yus »

 

TinyPortal © 2005-2018