SilverWav's Journal

The best is yet to come…

Posts Tagged ‘platypus

A simple alternative to Hacktheweb, aardvark, platypus or Tampermonkey.

leave a comment »

Because I hate ugly distracting cruft on websites. :-)

History:

I loved Platypus but moved on to Aardvark when it died, then created Hacktheweb to enable aardvark to save scripts to Stylish (recreating most of the platypus functionality with out the risks).

But while creating extensions can be a lot of fun, maintaining them… not so much.

Each time Stylish changes you need to update Hacktheweb to match. Tried that for a few years and… meh. So instead I just used Hacktheweb with the old 1.4.1.1 Stylish.

Also Hacktheweb was created on Firefox and I have moved to Chrome… but the Stylish scripts were usable on both, so I was still using Hacktheweb when I needed a quick and dirty script.

On Chrome the closest extension I could see was Stylebot, but with no easy saving to Stylish and a quirky interface, it was not something I could live with.

So looking around for something simple and safe, I looked at Tampermonkey which seems great but requires a lot of trust… and is probably overkill for my needs.

The Binding Flash of Inspiration:

But I had a revelation… Adblock Plus! Never really considered it after ruling it out a while ago (no widthify, no stylish, and I had hid the ABP button so out of sight out of mind).

But looking at it in this new light (looking for Simple, Quick and Good Enough, rather than Perfect).

I turned the ABP button back on then hid the distracting ‘Shown number of ads blocked’ badge.

In testing ABP, I found it to be a good fit for my requirements; the block element function does 90% of what I wanted. Just getting rid of sidebars was my main aim, the filters are not synced but easily cut and pasted.

As this looked to be a wining solution, it was worth thinking of a way around the ‘Site Not Centred ‘issue, resulting from blocking sidebars…

My solution:

  1. Create Stylish scripts to change margin-left to 10%, 20% etc…
  2. Upload the Scripts to https://userstyles.org/users/98352 so that I can install on all of my browsers.

So on each browser on the ABP Options page, I just paste the filter text into the ‘Your Own Filters’ tab.

Then I go to userstyles.org and install the scripts I need e.g. ‘0sw_MLeft10percentWhite’ and I am done.

The Benefits for me are:

No extra extensions, I am using ABP and Stylish already, so no extra trust needed. Also both extensions are backed by big name developers.

ABP block element is quick and easy to use, as is transferring filters.

The Result:

Fantastic clean, distraction free, easy reading of my favourite web sites… without having to build and maintain my own extension.

Looks like a plan :-)

Written by SilverWav

July 21, 2015 at 3:09 pm

A Stylish How To – Alter The BBC News Site To Drop The Sidebar (5mins).

leave a comment »

Dropping Greasemonkey for a more “Stylish” Add-on.

Stylish is better in the following areas:

  1. Speed, Stylish appears to be instantaneous, whereas Greasemonkey slowed page loads appreciably.
  2. CSS not JS so no security issues.
  3. A huge number of great ready made styles at http://userstyles.org/ presented in a nice clean manor.
  4. Fantastic extra tools to help you such as the DOM Inspector and the Stylish-Custom add-ons.
  5. Great developer support for both the main add-on and the extra tools.

__________________

TBH now that I look at it I cant see how it took me so long to move :-)

That said the main issue with Stylish was a lack of an easy “How To” so …

Here you go ;-)

__________________

A Stylish How To – Alter The BBC News Site To Drop The Sidebar (5mins).


Sidebar

No Sidebar

The basics:

Install Stylish.
Install the DOM Inspector.
Reboot.
Put the DOMi button on a Toolbar for easy access.

From the stylish statusbar icon:

Left Click > Write new style > For bbc.co.uk…

Add the code below:

@namespace url(http://www.w3.org/1999/xhtml);

@-moz-document domain("bbc.co.uk") {

.layout-block-b { display: none !important; }
.layout-block-a { width: 100% !important; }
.story-body { width: 816px !important; }
.story-header{ width: 120% !important; }

}

Save, close & you are done!

__________________

The Stylish Trick (Use the DOM Inspector)

To find which elements to use e.g. “.layout-block-b” I did the following:

Clicked the DOMi button on the Toolbar. (Firefox > Web Developer > DOM inspector).

Clicked on the Top Left Icon. (Magnifying glass with white mouse cursor) “Find a node to inspect by clicking on it”.

On the BBC web page I clicked on the sidebar that I wanted to remove… (A red box surrounded it).

The DOM inspector now displayed a tree view of the web page and the item “hyperpuff”.

I moved up the tree a little and saw that “.layout-block-b” is the element that I wanted to hide and “.layout-block-a” the one I wanted to maximise (A red box surrounded it).

How cool is that!

Once you have this trick down, you have the keys to the city!

No ugly website is safe :-)

__________________

Note: The element selector “name” can be a LOT more involved, especially if its in a table, but the solution is the same.

Right click the element and choose “Copy Selector”.

__________________

More examples of my newbie fumblings here: http://userstyles.org/users/98352

__________________

Written by SilverWav

April 24, 2011 at 1:27 pm

Platypus Workaround for Firefox 3.6* – Use a Firefox 3.5 profile

leave a comment »

What Platypus is.

Platypus is a Firefox extension which lets you modify a Web page from your browser — A Tool to let you Hack out all the stuff that annoys you — and then save those changes as a Greasemonkey script so that they’ll be repeated the next time you visit the page. (here).

______________________________

The Praise.

I have tried using the net without Platypus but it is just too painful.
None of the alternatives are anywhere near as easy to use or as powerful.
(One rather neat possibility is Readability, which I now use for day to day stuff).

______________________________

The Problem.

What to do when Platypus will no longer work with Firefox 3.6?

______________________________

The Solution.

  • Platypus works fine with Firefox 3.5.9.
  • So create a profile and install platypus with Firefox 3.5.9.
  • Now upgrade to Firefox 3.6.

Yeah! It still works!

______________________________

Quick Hack Here.

Or you can just use the profile I have created for my own use here.
Then you can install whatever else you want on top :-)

Profiles:

The command below allows you to start up profile manger.

firefox -P

Warnings:

If you don’t see Platypus then check that the old firefox process isn’t still hanging round after you have closed it.

If it is kill it.

___________
Notes:

Platypus works fine with Firefox 3.5.9 so create a profile and install platypus and greasemonkey first, then upgrade to Firefox 3.6.

Workaround1
Use the 3.5.9 profile, then “make  compatible” with Mr Tech Toolkit)

Workaround2
Use the 3.5.9 profile, then “bump version to 3.6*” open the xpi (with a zip manager), alter the “max version” line in the file “intall.rdf” (with a text editor), then save changes, restart firefox.

___________
Last Thoughts:

This is a workaround but it buys me some time.
Hopefully someone will update Platypus for Firefox 4.0 or I will need to run 3.6 in tandem just to create the scripts – ugh :-|


Written by SilverWav

June 8, 2010 at 9:22 pm