"ERR_NETWORK_ACCESS_DENIED" appears when loading local HTML with QWebEngineView
Solved
QtWebEngine
-
The C++ source code is as follows:
QVBoxLayout *layout = new QVBoxLayout; m_view = new QWebEngineView(); layout->addWidget(m_view); ui->widget->setLayout(layout); QString filepath = qApp->applicationDirPath() + "/test.html"; m_view->load(QUrl(filepath));
and the HTML file is as follows:
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="refresh" content="0;url=http://baidu.com/"> </head> <body> </body> </html>
When the program was running, an error occurred:

"Please, could anyone tell me how to solve this issue? I would be very grateful." -
S SGaist has marked this topic as solved on