enter image description here
below is the link taken by Instagram scraper.
https://www.instagram.com/p/Cnz_Un4Dg6N/
you can see in image When i hover on the link it say could not load the image.
It work when i open it in new tab but when i fetch data then its not working.
It work when i open it in new tab but when i fetch data then its not working.
It work when i open it in new tab but when i fetch data then its not working.
Related
I have an iframe which displays the html file I grab from firebase, but in those files there are twitter/ discord links which when you click say "... failed to load". The links do work if you click open in a new tab, which I know is target="_blank", but I am unsure how to edit those a tags in an already loaded iframe
I use api in the from of json. In JSON file have many link as well as a video link. I want the video link play in next window.
Similar to this medium article where a custom og:image, og:title, and og:description are displayed for different articles, when the facebook share button is clicked a popup opens to let the user type a message and below is the image/title/description grabbed from meta tags (og:image, og:title, etc)
When the user clicks on the facebook share button I then dynamically change the meta tags to customized images/descriptions using javascript like so
document.head.querySelector("[property='og:image']").setAttribute("content", image_url)
the problem is that the image isn't appearing at all when the fb share button is clicked - when I enter the url into Sharing debugger it works, but on the actual website it doesn't
Not certain what your aim is but you won't be able to set the og:image using Javascript because facebook is getting the image url etc. from the HTML returned by the url when its own server requests that url. It's not getting that data from the client.
I am building a Chrome Extension for ,my Bookmarks app.
A bookmark record has 4 images fields.
Each image filed has these options to set an image:
Generate a screenshot of the viewport of the webpage
select an image scraped from the webpage HTML
Select a region of the webpage screen and then edit it with annotations
Orginally I had a modal style app that loaded in the popup.html file when the extension button was clicked in the toolbar. Because I added the ability to select a region for the screenshot image though I now have to move that modal into the actual webpage DOM.
The reason is that when a user select to select a region screenshot from the modal, it has to close the modal/hide it and show the screen to make the selection. On completion there is no way to re-open the popup from the menu bar!
So I am moving the modal to the webpage. Clicking the toolbar button will then build and show the modal. Then when user selects to select region for 1 of the 4 image fields, I will hide the modal and on completion I can simply show the hidden modal and populate a text input filed with the newly generated and uploaded image.
I am now trying to go a step further though. After selecting the image region, instead of showing the Modal window right away. I want to instead show the image in an editor style page which would be an HTML webpage that belonged to the extension (like this chrome-extension://mcbpblocgmgfnpjjppndjkmgjaogfceg/fsCaptured.html). It would open this in a new tab.
The user would then annotate with text, shapes, etc in the editor and then upload file.
This is where I am stuck. When I get the URL back from the uploaded image, I need to then close this new tab window and go back to the main webpage that had the app modal window and where the screenshot selection was made from. I would need to then open/show the modal again and fill in the text input for the new image upload field.
So my question here is...
Is it possibble for my extension to pass a message from my chrome-extension://mcbpblocgmgfnpjjppndjkmgjaogfceg/fsCaptured.html page with the editor back to the webpage the modal is on?
I would need to:
Pass the image URL back to the webpage with a message
Close the extension editor page/tab
go back to/bring focus to the webpage with the modal on it
Is this even possibble? I realize you can send messages from background scripts to content scripts and content scripts back to background scripts.
UPDATE
For the first part. Perhaps the extension webpage would send a message to the background.js and then the background.js could send a message to the webpage content script. This would solve that part of the process!
Would just need to figure out if the extension webpage can close itself and then bring focus to the original webpage?
Update 2
Looks like I figured it out.
You can make a tab selected/active with:
chrome.tabs.update(tabId, {selected: true});
I believe my custom extension page can send a message to the background.js
and then the background.js could send a message to the webpage content script with the modal window and have it then update the image fields in that modal.
Next from my custom extension page I should be able to call chrome.tabs.update(tabId, {selected: true}); after it sends the above message to the content script which would then close the extension page and bring focus back to my webpage with the modal in it.
I am working on a project using Phonegap, i am creating profile page but the issue is that when user uploads new profile picture, picture successfully uploaded to the server, but it does not show updated picture in the profile, instead it shows the previous image, i know it is using the image from cache that was already there. So how can i avoid using the image from cache, i want new image from the server.
i used following code in ajax call but it is not working.
cache:false,