Avatar of brian_appliedcpu
 asked on

Is there a css or other stylesheet mechanism that can be run locally that would allow for the page columns to be resized on the local browser?

We have a vendor who produces a report each month via web portal.  The web page report is extremely poorly designed.  The report consists of a table with column descriptions and the table values contain either numbers or a text box.  The problem is that the columns widths are not adjustable and the text in the boxes gets truncated mid word and wrapped to the next line.

CSS* chrome plugin* Stylesheets

Avatar of undefined
Last Comment
Julian Hansen

8/22/2022 - Mon
Terry Woods

GreaseMonkey (for Firefox an extension) came to mind as a tool that could help you do that. There seems to be an alternative for Chrome too, called TamperMonkey: https://chrome.google.com/webstore/detail/tampermonkey/dhdgffkkebhmkfjojejmpbldmpobfkfo

As I understand it, the extensions allow you to write javascript that will update content as required, which could be used to achieve your goal. I haven't used them before though.


You can use Datatables https://datatables.net/
Responsive https://datatables.net/extensions/responsive/examples/initialisation/className.html
And Bootstrap for the page https://getbootstrap.com/

You will need to edit the code page .

I think a combination of what has been mentioned above would probably work well.

TamperMonkey to insert content and script, and have it load and run datatables.net to convert the table, and then finally use the colresize plugin (https://github.com/dhobi/datatables.colResize) for datatables.net to allow you to resize the columns by dragging.

This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.

Datatables is very powerful and flexible so you can adapt to your need with less code, this has a learning curve for more complex table but it work it  I'm using it for all my tables.
with the responsive plugin you can display a lot of columns and these will be visible even on mobile, this is user friendly.
Julian Hansen

Can you give us a bit more information about deployment?

As I understand it you have an html page you are loading from the file system - rather than a server - and the page is rendered in a less than desirable way. You would like a way to "massage" the page to make it look better but without having to edit the underlying HTML file?
Is this correct?

If so:
a) How many people will be accessing this file?
b) Where and how do they load the file?
c) Will they all want to see the same modifications - or make their own?
d) Do you have access / permission to add plugins to their browsers?
e) How often is this process required?
f) What is the level of technical literacy of those that will be using this solution?

Answers to the above will help us (me) understand the problem space a bit better.


All great questions.
So we are an MSP IT group (used to have an inhouse dev guy... but no more)
The web site is an external vendor n-able MSP Manager, I have already reached out to them and they basically told me they dont plan to fix it and they dont have an api that we can hook.
The report is a billed tickets report and deliverable for our clients, which i am embarrassed to provide each month
Even their save to PDF is broken looking.  And trying to edit the pdf with adobe acrobat is virtually impossible because each client may have 20 pages or so of logs.  So if we cant fix it at the presentation layer we are screwed.
We have no control over the vendor's server but being a bunch of IT engineers, we have full control over everyones system in the office.  
I only need to generate the batch of reports 1x per month.
We have one guy who has written a front end that is able to link with internal sql dbs and AWS dynamoDb so he may be able to work something, we just need to know if a solution is possible.
The vendor's output looks like this, the blue is available real estate and the red is the abomination that is their system.
Note we have used this system for years hoping they would fix it.....nope.  
Inspecting the page i see it uses alot of css and js.

Thank you for your assistance.

Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
Julian Hansen

View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.

Even scraping we lose the format,
Decided to just copy and paste into a word doc, then we can resize the columns and run a few macros against it to clean it up.
Thanks for your suggestions.
Julian Hansen

Even scraping we lose the format,
All you are doing is exactly what the browser is doing - requesting a URL. You get an HTML page back - insert the style and send that on to your users?