I'm just trying to write a program to scrape from a website and I'm trying to set the parameters for my code but I can't find it anywhere. Only "general", "response headers", and "request headers" are showing up.
Related
When using WhatsApp web, when you send a message there are no requests showing up, but the message still delivers. Why are there literally no signs of any requests made in the networking tab??
And how to make it visible (if it's hidden)??
Note: It happens only on WhatsApp web. On other sites, it works and shows the GET and POST requests...
This is a common source of conufsion when debugging networking requests done from the web.
Normally, developers look at these network requests from top down and assume that the lowest one is the most recent request made - therefore assuming that the request must be at the bottom. For 'plain' HTTP this is correct. However, many apps that want to show data in real-time, use WebSockets to communicate with an API.
The same thing happens in the Web-version of Whatsapp. Only assets like the actual JavaScript-app, icons etc are loaded using plain HTTP. Then, a WebSocket is opened through which messages are exchanged for example.
To see the actual request do the following:
Open DevTools, go to networking tab
Open Whatsapp web. Make sure that at this step (1) is already recording!
Filter for "WS" in the filtering bar
There will be only very few results which you can click to investigate
Inspect this Socket using the 'messages' tab
Now send a message, you will see a message called binary message with your message as payload.
Try "Settings" -> "Preferences" -> "Network" -> "Record network log" in Chrome DevTools. This checkbox is probably unchecked in your situation. So, check it.
Otherwise if "Record network log" is checked, then try "Settings" -> "Preferences" -> "Restore defaults and reload".
Is there a way to covert "Test Results Analyzer" or "Test Result" Jenkins plugins reports to beautiful HTML.
I want to share the report only and did not want anyone to login or see reports via Jenkins UI.
I'm learning the basics of Chrome DevTools, and I've got the task where I need to get access to the linked information, but when I click on the link I've got an error:
"this endpoint is not avalible in production mode" page
I've tried to find something using Devtools, but vainly.
I'm a complete newbie, where should I search?
here is the task itself
I am trying to run Google Drive API using Google Client V3 in PHP. I have credentials for my locahost site set up, have downloaded the JSON and load the client with those credentials and on my local site everything works fine.
When I move it to the live site and download the JSON for the the project we use on the live site I keep getting a redirect_uri_mismatch. I've checked the console for this project and the redirect uri's are set correctly. I have the following for redirect uri
https://www.awesomestories.com/Google/getClient
https://awesomestories.com/Google/getClient
https://www.awesomestories.com/Google/getClient/
https://awesomestories.com/Google/getClient
I realize this is over kill but I wanted to make sure every possible version was set to eliminate this as the problem. The Google prompt is happening and when the code is returned and I try to to load the code parameter into Google client:
$resp = $client->authenticate($_GET['code']);
I get the following response
array(3) {
["error"]=>
string(21) "redirect_uri_mismatch"
["error_description"]=>
string(11) "Bad Request"
["error_uri"]=>
string(0) ""
}
The url that it is being redirected to is
https://www.awesomestories.com/Google/getClient
Which matches what is set in the console. Also we use this same project's credentials on the site already although we are just using the API key associated with this project not the Oauth2 credentials which GoogleClient is using. So for this project this is the first time we are using the Oauth2 credentials set up in the Google Console. I just can't figure out why the authentication is succeeding on the test site but not on the live site.
Another thing that is strange is that initialization of the client looks like this:
$client = new Google_Client();
$client->setAuthConfigFile(SYSTEM_PATH.'/shared/php/google-api-php-client/client-prod.json');
$client->setAccessType('offline');
$client->setApprovalPrompt("force");
$client->setPrompt("consent");
and on my local site when the google prompt authorization screen comes up it asks to allow offline access, but on the live site it never asks to allow offline access.
If someone could point me to what is going wrong I would really appreciate it.
So I don't know why this worked, but it did. I removed all the redirect uris from my console with the project associated with this, ran my code and at prompt screen got a redirect mismatch uri error as expected, I then re added the redirect uris, copying the one from the error message displayed on the prompt and then ran my code and the call succeeded. The strange thing is that the redirect I copied from the error message was the same that was in there before, because I copied the ones I deleted and compared them so I have no idea why this worked. Also before when I set the Google Client with the redirect uri the prompt screen went through fine without a hitch it was only when trying to load the authorization code sent back from Google prompt screen that the uri mismatch error would show up. I've ran Google prompts before where the redirect uri was set incorrectly on the client and this error appears in the prompt screen, so I'm not positive what was going on here, but it now is working.
Does Google Chrome allow any manipulation of the default spelling lexicons? I've searched for material based on this and cant find any. Trying to develop a speller that works in Google Chrome web apps like Google Documents. Currently, my spell checking app won't work in any text field or area related to Google docs or Office 365. Additionally, I have my own word list I want to incorporate into Chrome's speller? Can that be done? Can a third party custom dictionary be added to Google Chrome's spelling tool? Simply looking for resources that explain this as I can not find any.
After a quick search on the issue tracker, I found an issue that adds a (badly documented) feature to the extension platform.
According to the commit message, you can add a new dictionary using the "spellcheck" key in the manifest file.
{
"name": "Dictionary Test",
"description": "Load a spellcheck dictionary.",
"version": "1.0",
"manifest_version": 2,
"spellcheck": {
"dictionary_language": "testEnglish",
"dictionary_locale": "te",
"dictionary_format": "hunspell",
"dictionary_path": "testEnglish.bdic"
}
}
Because documentation on this feature is non-existent, you have to read Chromium's source code if you want to know how to use this feature at all. Here's the diff for the commit that added the new feature to the extension API: https://chromiumcodereview.appspot.com/download/issue14064004_10001.diff
And here's some documentation about the format of the dictionaries: http://www.chromium.org/developers/how-tos/editing-the-spell-checking-dictionaries