Click to See Complete Forum and Search --> : Local styles on included charts


OhLordy
09-25-2003, 08:01 AM
Hi, this isn't a php question at all. It's just a general "how on earth!!".
I've got a load of html file product charts auto-generated that other sites can include on their pages. The problem I'm having is that I want these to use a stylesheet but if I make the include a page in it's own right (<html></html> tags and all that jazz) it sometimes screws up the page which is including it. I have been told that I can do it with I frames but the height of would be different each time because sometimes all the products would have long names and sometimes short.
Does anyone have any ideas?
Cheers
Rob

drawmack
09-25-2003, 09:27 AM
you can do it with a style sheet but you have to use abstract classes and named classes with really weird names like this

body.jte2003 {
}

OhLordy
09-25-2003, 10:40 AM
I don't wuite understand what you mean, could you point me in the direction of some good documentation. Also the problem we have with stylesheets is we don't have access to to the other sites html header and creating a page within their page caused problems.

stolzyboy
09-25-2003, 10:48 AM
you can do inline stylesheets

<span style="background-color:#ff0000">something like that</span>

OhLordy
09-25-2003, 10:49 AM
Yea, but if we have loads of different charts and want to include a single style across all the charts how can we include this style half way through the page?

OhLordy
09-25-2003, 01:25 PM
I'm building a css parser which when the dynamic chart is built from the database it reads the css file and appends all relevant tags with a style"..." tag.
Seems like a rather long-winded way around. Anyone think of a better way?
Rob

Moonglobe
09-25-2003, 08:53 PM
what do you mean by charts? GD-generated images? obviously not but could you please elaborate? :confused:

OhLordy
09-26-2003, 07:09 AM
Top 10 product lists. that sort of thing. We generate js files every now and then and then they link to them from their sites and people can see our top ten forks or plates or whatever.