Linkedin Snippet Help

{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.org-top-card-summary__title}
{key: tab}
{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.org-top-card-summary-info-list > .org-top-card-summary-info-list__info-item}
{key: tab}
{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.org-top-card__primary-content .inline-block > :nth-child(1)}
{key: tab}
{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.link-without-hover-state}
{key: tab}
{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.organization-about-module__content-consistant-cards-description}

Hello ,This is my Linkedin Snippet,the last option in the snippet is for the extraction of company description. But it only includes the portion of the description of the company until ''See more'' is written. I have tried to use the click command but since I am entering data into my google sheets. The click command is not working.

For example:

''The Leasing Agency is a commercial real estate agency specialising in leasing and advisory services. We are property experts with an established network of stakeholder relationships which enables us to maintain balanced and longstanding relationships between tenants and landlords. “Our extensive experi ... see more''

How can I include the full description in my google sheets,without pressing the ''See more'' button everytime??

Plus,if the desciption consists of more than one paragraph,how can I include all the information in the description in the same cell,of my sheets.

Please modify this snippet.
Thank You..

Thanks for this question. We are reviewing this internally and should have an answer shortly.

Hi @Faiza_Finsoul

Thanks for the interesting question. Until we click on the See more button, the data is hidden inside a complex data structure in partially-encoded form. I have written a regex to extract the data, along with a few replace calls to decode the data. Snippet:

{name={site: text; page=https://www.linkedin.com/*; select=ifneeded; selector=.org-top-card-summary__title}}
{=replace(replace(replace(extractregex({site: html; page=https://www.linkedin.com/*; select=ifneeded}, name & ".+?\"description\":\"(.+?)\",\""), "\\n", "\n"), "\\t", "\t"), ">", ">")}

It works for me on this company's page. But it might break on others, because the regex is a bit brittle. You might also need to replace few more encodings as I didn't handle all of them.

Please let us know if it works for you.

This alone works great
for example if I just use this as a snippet alone,it extracts complete description of the company.

But when I tested this snippet by combining it with my previous snippet ,which is

{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.org-top-card-summary__title}{key: tab}{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.org-top-card-summary-info-list > .org-top-card-summary-info-list__info-item}
{key: tab}
{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.org-top-card__primary-content .inline-block > :nth-child(1)}
{key: tab}
{site: text; page=https://www.linkedin.com/company/*; select=ifneeded; selector=.link-without-hover-state}
{key: tab}
{name={site: text; page=https://www.linkedin.com/*; select=ifneeded; selector=.org-top-card-summary__title}}
{=replace(replace(replace(extractregex({site: html; page=https://www.linkedin.com/*; select=ifneeded}, name & ".+?\"description\":\"(.+?)\",\""), "\\n", "\n"), "\\t", "\t"), ">", ">")}

On reaching the cell where company description should be inserted,5-6 cells down the main cell in my google sheets,the company description gets inserted.

While when I use this snippet independently only with in one cell where company description is to be inserted. It successfully inserts all the description in the required cell,without disrupting my other data.

Plus, I love the new feature,that text blaze now allows us to choose among the opened tabs as to which tab's data we want to insert from linkedin.

Additionally is it possible to also include website of the company ..

Can there be something like this ,which allows us to enter data from all the current opened tabs from linkedin at once??

I am extremely sorry to ask so many questions at once.

To further clarify when I have combined your snippet with my previous sniipet,it when reaches the cell of the company description,the text gets spread into multiple pieces and gets inserted in the cells below the main cell,because of multiple paragraphs. But while using it alone ,it inserts all the description successfully in a single cell,even if the data consists of multiple paragraphs.

Hope I am able to explain clearly...

That is correct. This is a behavior of Google Sheets. If you double click into a cell and then paste, it pastes into the same cell. But if you single click into a cell, and then paste, paragraphs will spread out into multiple cells. We will look into improving it. Meanwhile, does it work for you if we remove all newlines from the company description? You can do that with this command instead:

{=replace(replace(replace(replace(extractregex({site: html; page=https://www.linkedin.com/*; select=ifneeded}, name & ".+?\"description\":\"(.+?)\",\""), "\\n", "\n"), "\\t", "\t"), ">", ">"), "\n", " ")}

You can use this:

{name={site: text; page=https://www.linkedin.com/*; select=ifneeded; selector=.org-top-card-summary__title}} 
{=replace(replace(replace(replace(extractregex({site: html; page=https://www.linkedin.com/*; select=ifneeded}, "VIEW_WEBSITE.+?\"url\":\"(.+?)\",\".+?" & name), "\\n", "\n"), "\\t", "\t"), ">", ">"), "\n", " ")}

Currently it's not possible to process all LinkedIn open tabs at once. Although it's a good request and we'll look into it.

No worries those are great questions :slightly_smiling_face: