WebGadget()
- the.weavster
- Addict
- Posts: 1537
- Joined: Thu Jul 03, 2003 6:53 pm
- Location: England
WebGadget()
Update WebGadget() so it's underpinned by something that can display modern web pages.
- RSBasic
- Moderator
- Posts: 1218
- Joined: Thu Dec 31, 2009 11:05 pm
- Location: Gernsbach (Germany)
- Contact:
Re: WebGadget()
I'm sorry, but that's not the job of PureBasic. WebGadget based on windows control (ActiveX object) and Microsoft must update.
- the.weavster
- Addict
- Posts: 1537
- Joined: Thu Jul 03, 2003 6:53 pm
- Location: England
Re: WebGadget()
Why not?RSBasic wrote:I'm sorry, but that's not the job of PureBasic.
And my feature request is for it to be based on something else.RSBasic wrote:WebGadget based on windows control (ActiveX object)
Re: WebGadget()
At the moment the WebGadget is useless
Last edited by HanPBF on Sun Jan 07, 2018 11:04 am, edited 1 time in total.
- the.weavster
- Addict
- Posts: 1537
- Joined: Thu Jul 03, 2003 6:53 pm
- Location: England
Re: WebGadget()
You can use Firefox in chromeless mode too but it only works with the file protocol not when loading a web uri, e.g.:HanPBF wrote:I would not complain if
- browsers could be set into an desktop application mode (chromeless like HTA did)
- if Chrome and Opera, which can do this, would not be blocked from many companies for their "curiosity"
- at the moment You can use Firefox (portable avialable) or IE what ever version is installed and host PB as CGI on the desktop
firefox --chrome file:///home/whoever/public_html/index.html
I don't know if you can make ajaj web requests in that mode though, you'd have to try and see.
- the.weavster
- Addict
- Posts: 1537
- Joined: Thu Jul 03, 2003 6:53 pm
- Location: England
Re: WebGadget()
A while ago I created a project in Qt using the WebKit bridge that enables you to expose C++ objects to JavaScript. Even though I was completely new to Qt it was remarkably easy to create and inject an object that enabled me to access SQLite and ODBC databases direct from JavaScript like this:
The problem with Qt is the runtime is huge.
Today I was experimenting with PureBasic to see if I could create a browser and server combined into one application with the network events and gadget events inside the same Repeat Until loop. To my surprise it didn't choke but I lost enthusiasm for my experiment the moment I got an error from an *.html file that included JQuery.
Code: Select all
function onNext(rec) {
console.log(rec);
}
function onFieldData(fld) {
console.log(fld);
}
function onError(msg) {
console.log(msg);
}
window.onload = function() {
sb_database.onNext.connect(onNext); //sb_database is the object I injected
sb_database.onError.connect(onError);
sb_database.onFieldData.connect(onFieldData);
var db = sb_database.connect(0,"mydb.sdb","",""); // 0 = SQLite, 1 = ODBC
if(db==0) { return; }
if(sb_database.begin(db)!=1) { return; }
var params = ["United Kingdom"];
var jsparams = JSON.stringify(params);
var rs = sb_database.select(db,"SELECT * FROM COUNTRIES WHERE COUNTRY=?",jsparams);
if(rs==0) { return; }
while(sb_database.moveNext(rs)==1) {
// handled by callbacks...
}
sb_database.commit(db);
sb_database.freeQuery(rs);
if(sb_database.begin(db)!=1) { return; }
params = ["No","United Kingdom"];
jsparams = JSON.stringify(params);
if(sb_database.execute(db,"UPDATE COUNTRIES SET IS_EU=? WHERE COUNTRY=?",jsparams)!=1) { return; }
if(sb_database.commit(db)!=1) { return; }
sb_database.close(db);
console.log("done");
}
window.onunload = function() {
sb_database.onNext.disconnect(onNext);
sb_database.onError.disconnect(onError);
}
Today I was experimenting with PureBasic to see if I could create a browser and server combined into one application with the network events and gadget events inside the same Repeat Until loop. To my surprise it didn't choke but I lost enthusiasm for my experiment the moment I got an error from an *.html file that included JQuery.
Re: WebGadget()
So, a year has gone by and PureBasic is still
using the same very obsolete webgadget!
It looks like SpiderBasic is also using the same
gadget, which is ludicrous. Don't you think that
it's time to really get on the HTML5 bandwagon?
PureBasic is great software. Why spoil it with
junk like this gadget?
using the same very obsolete webgadget!
It looks like SpiderBasic is also using the same
gadget, which is ludicrous. Don't you think that
it's time to really get on the HTML5 bandwagon?
PureBasic is great software. Why spoil it with
junk like this gadget?
Re: WebGadget()
Your program can use a newer IE version. You only have to create a key value in
HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION
with the name of your exe file with a value of 11001 and you have the latest IE. And all features of IE 11 are yours...
HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION
with the name of your exe file with a value of 11001 and you have the latest IE. And all features of IE 11 are yours...
Re: WebGadget()
Hello Bisonte,
thanks for the tip.
If I can not change users registry settings due to admin rights is's a problem.
But, I think I have read something online maybe here in PB forum about setting users registry entries at runtime.
Or in context of the application built with PB.
Any hint?
IE11 is in fact the browser kept by Microsoft for big enterprises; enterprises don't like the Edge browser due to security reasons.
Anyway, IE11 gives alle the modern web things needed.
I think, first comment is right: PureBasic can not take care of all the things of off its context.
thanks for the tip.
If I can not change users registry settings due to admin rights is's a problem.
But, I think I have read something online maybe here in PB forum about setting users registry entries at runtime.
Or in context of the application built with PB.
Any hint?
IE11 is in fact the browser kept by Microsoft for big enterprises; enterprises don't like the Edge browser due to security reasons.
Anyway, IE11 gives alle the modern web things needed.
I think, first comment is right: PureBasic can not take care of all the things of off its context.
Re: WebGadget()
I forget to mention :
At compileroptions, don't check "Request User Mode" and don't check "Request Admin Mode" and all is working in Windows "virtual store".
No special rights needed.
At compileroptions, don't check "Request User Mode" and don't check "Request Admin Mode" and all is working in Windows "virtual store".
No special rights needed.
Last edited by Bisonte on Thu May 11, 2017 9:20 am, edited 1 time in total.
-
- Always Here
- Posts: 6425
- Joined: Fri Oct 23, 2009 2:33 am
- Location: Wales, UK
- Contact:
Re: WebGadget()
.... the bigger problem is the bank-busting price!The problem with Qt is the runtime is huge.
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
If it sounds simple, you have not grasped the complexity.
Re: WebGadget()
SB uses your browser for its gadget, it's not the same at all than PB.ramme wrote:It looks like SpiderBasic is also using the same
gadget, which is ludicrous. Don't you think that
it's time to really get on the HTML5 bandwagon?
About PB webgadget, MS doesn't seems to care to provide a good native webview for app, and we don't want to have a build server to compiler a 40 MB dll based on chrome which needs to be updated every month.
-
- Always Here
- Posts: 6425
- Joined: Fri Oct 23, 2009 2:33 am
- Location: Wales, UK
- Contact:
Re: WebGadget()
I was hoping that WebKit could be used for Windows OS.
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
If it sounds simple, you have not grasped the complexity.
-
- Addict
- Posts: 2218
- Joined: Mon Jun 02, 2003 9:16 am
- Location: Germany
- Contact:
Re: WebGadget()
There is no vanilla webkit implementation afaik. They are either connected to Qt or GTK.IdeasVacuum wrote:I was hoping that WebKit could be used for Windows OS.
bye,
Daniel
Daniel
Re: WebGadget()
Chromium WebGadget
Why the Chromium WebGadget
1. No dependencies; works with or without WebView2 installed.
2. No worries about an abandon project; the Chromium WebGadget is not effected by changes to WebView2.
3. Most major browsers have adopted the Chrome DevTools Protocol, fully accessible from the Chromium WebGadget.
4. Can be used as a WebGadget or applied to any installed Chromium browser.
5. Can run in Headless Mode when applied to a Chromium browser.
6. Headless mode supports controlling any Chromium browser remotely.
7. There are a wide variety of examples including Progressive Web Apps (PWA) via ISAPI.
8. The WebSocket scripts are cross platform, used for accessing the Chrome DevTools Protocol.
Why the Chromium WebGadget
1. No dependencies; works with or without WebView2 installed.
2. No worries about an abandon project; the Chromium WebGadget is not effected by changes to WebView2.
3. Most major browsers have adopted the Chrome DevTools Protocol, fully accessible from the Chromium WebGadget.
4. Can be used as a WebGadget or applied to any installed Chromium browser.
5. Can run in Headless Mode when applied to a Chromium browser.
6. Headless mode supports controlling any Chromium browser remotely.
7. There are a wide variety of examples including Progressive Web Apps (PWA) via ISAPI.
8. The WebSocket scripts are cross platform, used for accessing the Chrome DevTools Protocol.
Last edited by JHPJHP on Fri Dec 23, 2022 3:18 am, edited 5 times in total.