|
Posted by dorayme on 02/16/07 21:29
In article
<1171621920.759700.57610@a75g2000cwd.googlegroups.com>,
"shimmyshack" <matt.farey@gmail.com> wrote:
> On 16 Feb, 07:47, dorayme <doraymeRidT...@optusnet.com.au> wrote:
> > In article
> > <1171600584.942773.271...@q2g2000cwa.googlegroups.com>,
> >
> > "shimmyshack" <matt.fa...@gmail.com> wrote:
> > > On 16 Feb, 03:12, mbstevens <NOXwebmast...@xmbstevensx.com> wrote:
> > > > On Thu, 15 Feb 2007 19:02:00 -0800, windandwaves wrote:
> > > > > a. find all the IDs and classes used on the site.
> > > > > b. check if these classes and IDs are listed in the css
> > > > > c. find any classes and IDs listed in the css that are no longer used
> > > > > on the site
> >
> > > > I know of nothing ready-made, but it should be reasonably easy to
> > > > program in either Perl or Python.
> >
> > > if i were you I would write a small reg exp that goes and grabs
> > > classes from the css files, put them inside a javascript object/array
> > > and download the behaviour.js library and include the object and class
> > > in a script on each page.
> >
> > Would you now! I gave a perfectly simple way to do the job and
> > yet you still would do this.
> >
> > --
> > dorayme
>
> sorry to cause you so much offence dorayne, but I felt your idea
> didn't catch dynamic building of css using client side code, or css
> coming from a database query - in fact any complex web application
> which is not completely abstracted, and only covers plain text files
> in a ready built state. Even php files might have some css styles as
> echo 'border:1px #'.(($i%2==0)?'ccc':'ebebeb').' solid;';
> Using users as your engine gives you a distributed solution, which you
> can also use to check links, validate code, and many other things.
> It is more reliable because it checks the final application when it is
> running in all different user agents, and therefore gets the true
> picture, it is a bit different to real life where you make the cake
> with eggs, here we make the mixing bowl and throw it, a hen and some
> grain at the client. If they have a compliant user-agent their cake
> will taste nicer.
God almighty! If the task is so much more complex than was
conveyed by the OP then sure, maybe what I do is too simple
minded for words. I can scarcely believe what you have just
said... php, dynamic, css, database, client this and that, shake
it all up and bake it for 2 hours at 250 C... <g>
I was not really offended, just miffed at the general silence or
off key replies whenever I propose S & R techniques. I am
beginning to think that a lot of people simply do not know the
capabilities of good S & R engines that come with good text
editors.
Yes, I know many of the regulars here know all about these things
(they know too much for their own good in my opinion) but perhaps
many many others have less of a clue?
Perhaps I have been spoilt with BBEdit, a fine Mac editor with
fine S & R capabilities including GREP. Perhaps Windows editors
are not generally as good or lack an absolutley crucial feature
that is required for the technique I proposed, namely to Search
over a whole folder (including sub folders) at the press of a
mouse in seconds and, equally crucial, to issue a report of all
found instances and in that report to be able to go to those
instances at their source at the press of a mouse...
But for what the OP seemed to want, not even GREP needed to be
used.
--
dorayme
[Back to original message]
|