| Index
» Projects
» phpMyEdit
» Forum
» Color alternate rows on initial view? |
 |
rumex
Joined: 27 Oct 2017
Posts: 7
Posted: 2018-05-15 15:55
Back to top
Reply with quote
|
Hi
Whats a good way to color the background of alternate rows to make them more readable?
|
doug
Joined: 10 Feb 2003
Posts: 1013
Location: Denver, Colorado (USA)
Posted: 2018-05-15 23:31
Back to top
Reply with quote
|
Right click on the form when in List mode. View Source and note the existing style classes, then create a corresponding style in your stylesheet. There are probably two TR classes one with a 0 and another with a 1, thus create one or two classes to match. I moved on to Bootstrap HTML5, an alternative, in which you can hack the TABLE tags in the class file in order to add Bootstrap classes.
https://getbootstrap.com/docs/4.1/content/tables/
|
rumex
Joined: 27 Oct 2017
Posts: 7
Posted: 2018-05-17 15:08
Back to top
Reply with quote
|
just in case anyone else is interested I successfully did the following. From the generated php, I cut out the style section into a file called styles-agenter.css, so it looks like
<!DOCTYPE html>
<html>
<head>
<title>Agenter</title>
<link rel="stylesheet" type="text/css" href="styles-agenter.css">
</head>
---
In the styles-agenter.css file it looks like
-- <style type="text/css">
hr.pme-hr { border: 0px solid; padding: 0px; margin: 0px; border-top-width: 1px; height: 1px; }
--- ... copied code cut out for clarity ----
td.pme-stats { text-align: right; }
tr.pme-row-0 { background: #d3d2c2 } -- this gives me the colored coloured alternate row
-- </style>
|
|
Post new topic
Reply to topic
|
|
|
|