Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Access Stylesheet from catalog/conditions.php


bigbird_3156

Recommended Posts

Posted

Hi I am trying to create a table inside the text on my conditions.php page (ie in the define('TEXT_INFORMATION', ... section in the english folder)

I have got the table to work no worries, but I cannot seem to reference the stylesheet this way, what I have done (that does not work) is;

define('TEXT_INFORMATION', '<table width="580" border="0"  cellpadding="0" cellspacing="0" class="tablestuff">

and then in the stylesheet file;

.tablestuff, th, td {
    border: 1px #7e0049;
}

Could anyone please tell me how I make this work?

 

 

 

Posted

Try this:

.tablestuff th, .tablestuff td {
    border: 1px #7e0049;
}

Regards

Jim

See my profile for a list of my addons and ways to get support.

Posted

Hi Jim,

 

That made no difference.

 

I think the problem is how I am referencing the stylesheet rather than the stylesheet entry itself but I have no idea how to fix that

Posted

or perhaps you have made an error in your stylesheet before this section and thus it doesn't function anymore

try adding something like

body {

background: red;

}

 

to the end of the stylesheet file to see if it has trouble parsing the css due to an error.

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Posted

Have you asked your browser to show you the page HTML, to confirm that your stylesheet is in fact being linked in? Are there any .css files or in-line <STYLE> declarations after this file, that might be overriding your .tablestuff definitions? In osC 2.3.4BS, there is a user.css file that should have all your customizations (leave the stock .css files alone), but in earlier versions you either have to add your own .css file to the <HEAD> section or modify a stock .css file.

 

If you're sure your CSS code is in, use something like Firebug (for Firefox) or another CSS debugger to show just what the browser understands the CSS to be at that point of the table.

 

You might also try taking out the obsolete border="0" cellpadding="0" cellspacing="0" code and using CSS instead. Maybe something is confusing your browser with the mix of old and new?

Posted

thanks  bruyndoncx and Mr Phill,

 

I used your suggestions but am still having no luck,

 

I put a background colour into the tablestuff style and the colour displays in the table as it should, but not the border colour...

.tablestuff th, .tablestuff td {
	background: red;
	border: 1px #7e0049;
}

Is there possibly some other style that overrides this? It is the last style in the style sheet so I thought that meant it was the active one.. but maybe I'm wrong.

 

thanks

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...