How to block elements only on exact URL - adblock

I'm trying to apply a filter to youtube so that all the suggested videos on its homepage are hidden. I'm using ublock origin (uses EasyList rules mostly) and it's easy enough to do through the UI, and adds this rule:
www.youtube.com##.ytd-two-column-browse-results-renderer.style-scope > .ytd-rich-grid-renderer.style-scope
This works great, but the problem is that it applies that rule all over youtube, and so if I go to a creator's channel and try to look at all the videos (for example: youtube.com/c/{username}/videos) then all of those get hidden as well.
I'm guessing it's pretty simple, but how can I apply this rule only to the base youtube url?

To add on to the above answer (which I've been looking for for a while, so thanks!), you can switch out the "ytd-app" for "ytd-two-column-browse-results-renderer.style-scope" if you still want to keep the access to the search bar on the front page.

Related

Change image next to Website in Google search results

Good morning,
a customer of ours asked us if it was possible to change the image that Google shows next to his site in Google search results.
After several searches, we tried using different techniques all followed by re-indexing the page in order to instantly see the results.
We tried using structured data (both with ld+json and using microdata) and also of the attributes "og:image" and "og:title" in the "meta" tags, but none of these tests changed the image displayed on the right side next to the site in Google results.
We expected that with one of these methods would have changed the image, but nothing happened
Therefore, we wondered whether it was possible to change that image or whether Google chose the best image based on its search parameters.
Thank you for your valuable help,
Best regards

Comic navigation in joomla?

I have a joomla site and would like to integrate some old unfinished webcomics to it, so I can pick them up where I stopped in a CMS that won't leave me in an absolute frothing rage (thanks, wordpress).
I've got some experience with Joomla and I believe it would be a pretty good platform for managing multiple comics... except for the small issue of horrid navigation between pages/articles. Joomla's integrated article navigation is a humble but passable start, but if you intend to use categories to organize chapters then getting from the end of one to the beginning of the next is... yeah. This is a pity, as Joomla's category and article management options are beautiful for archiving and presentation, and adding gantry 5 to it means a great deal of control over the reading experience. Basically, joomla has pretty much everything I want, except for the navigation.
Ideally, what I'd like to be able to accomplish for comic navigation in joomla is:
Clickable full-article-image leading to next article/page
Prev/next article buttons (already available)
Prev/next category buttons (do we have those?)
The latter two in a module I can choose where to publish (optional)
And this is it, basically. I understand that implementing the first could be very hard without some major template customization, in which case I'd be willing to insert the image as a link in the article body... but only if there was one single code I could use, like the one that generates the next category article button. Because I'm not willing to create hundreds of menu items to generate links page-by-page.
So is any of this doable?
This is a quick answer but too much for a comment. I'm assuming since you are on SO that you don't mind coding (as opposed to just configuring).
I think you need to do two things. First you need to create a pagination.php for your template. This will let you really super control what the pagination looks like. You can have images, special css and js, whatever you want. You can also add the "last" and "first" options.
I think you need to make a new plugin to replace the core pagenavigation plugin and that also generates the previous/next category links. (Or I guess you could make one just to do categorynavigation depending on what you want.) HOWEVER, it seems to me that there is data on the sibling links that is already being generated in the content category model so you might be able to use that. (Check the code; I think there was never a UI for it, but it is there. Even if it isn't there, siblings are very easy to obtain in nested sets)
The other thing you can really think about if you go that route is changing the whole thing somewhat to use a module that gets the current ID and category ID from JInput. You might also be able to use JPagination. The important thing, however is that you make sure to do the caching the way the pagination that is there does it. In other words you really want to cache the whole list in the order you want so you are not running so many queries and slowing your site down. You may want to look at the categories and category modules to get some ideas about the queries to do.
Hope that gets you started, but it is definitely something you can do without too much trouble.

Best way to group scripts or styles in the Head without a div?

Twofold question.
Using a web template that utilizes AJAX for loading new pages, rather than traditional point-the-browser-to-the-url style, how would one go about adding new script or style tags to the page head as necessary?
I think using jQuery $('head').append(script); works just fine, but (and here's the second half), if I wanted to group all of the scripts that were page-dependent away from those that are universal across the site - how would I do that?
Using a div sounds so enticing since I could print it at the initial page render and just call
$('head div.external').append(script), but still probably a bad idea inside the head.
Is there any other element or method I could use to group these? The goal being to easily remove all of them when the user navigates away from the current page. A smaller consideration is that Google Analytic instructs you to place it at the end of the head tag (I'll be honest, I don't know why being the last script matters), and I don't want my scripts to interfere. Do these even need to be in the head, could I place a div at the end of the body and use that?
Surely the easiest way to do this, if it is necessary, is with classes:
$(script).addClass('external').appendTo('head');
then later:
$('script.external').remove();
I'm honestly not sure what this would achieve, however.

CEWP to show images (HTML) works until I use grouping. Then I see the DIV tag

I'm fairly new to Share Point so forgive me if this is to easy for you guys, but I could not seem to find the answer anywhere and I am rather stumped.
I am currently trying to make a website to track if particular tasks go over their due date. I have a calculated column that leaves a DIV tag to the image of a red/yellow/green circle which is displayed by the javascript for a Content Editor Web Part (CEWP) made by Christophe on his site here:
http://blog.pathtosharepoint.com/2008/09/01/using-calculated-columns-to-write-html/
I was able to put his code into the CEWP and everything looks great when it is in a standard list.
But I want a web part version of this on the homepage for easy view. When I make the web part (of a view grouping by the image tag) and place on the main site all I see is the DIV tag! I made sure to put an identical CEWP on the homepage as well but i get as grouping:
+[columnName] : DIV>img title=blahblahblah>/DIV> (2)
Needles to say when I expand this it stays the same for all entries below
Any Ideas?
Thanks for your time :D
Nobody has responded, but I found the answer so hopefully this will save someone the hours of grief I had. This will seem ridiculous but just go with it.
In the calculated column instead of returning the type as text, return it as a currency. Sounds ridiculous BUT IT WORKS!!

Algorithm / API for converting HTML to email friendly HTML (for newsletters)

I'm sure this is a very old question, but I could not find a straight answer
I'm looking for a works-mostly algorithm to take regular HTML content, and make it email client friendly.
I can rewrite any nice DIV layout to table layout, this is OK, but is there anything that will do it for me?
Here are my concerns
Overflow content - gmail etc ignores any overflow:hidden, the algorithm should address it
Clipped images - same as above, but here the solution will probably be server side clipping
CSS / Script / non standard tags - the algorithm should remove but keep the general look and feel
DIV layout to table layout, I heard it's a must, but I'm sure it's not an easy task to automate
There are many HTML to PDF converters, but I could not find a good HTML to "HTEMAIL" converter
Is there any standard or proposed standard for HTML for email clients? or is it an open jungle out there?
There is no way to make a converter that will be cross email client compatible. The closest you can get is using templates and adding text in certain sections using php or .net
I've been creating emails for 6 months, and the amount of time you spend correcting email client differences is normally around 50% of the time you spend making the email.
Here is some reading that may help you:
http://www.sitepoint.com/code-html-email-newsletters/
http://www.campaignmonitor.com/css/
As you can see from that last link there is no way to create an algorithm that can sort out all these issues.
Hope this helps
Another option that I've been using is to build the email in HTML or directly in Mailchimp. Once I'm happy with it, using Mailchimp, I click on preview and I get the email in a popup. The source code from the popup is email-client friendly (in tables). I then copy that code and use it for my emails.
Not ideal and a bit of trouble, but so far the best solution I can find.
And before people ask, I mostly us Mailchimp directly, but there is one situation that I have to kick it old school.

Resources