Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: May 2002
Posts: 153
Member
Member
Offline
Joined: May 2002
Posts: 153
Can you please tell me what code i have to ad to a web page if i wanted it to use a cetain stylesheet

Sponsored Links
Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
You'll need to make the classes you use for the styles the same in the rest of your site like you have in threads


- Allen wavey
- What Drives You?
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Yeah basically where you have <td> you might want something like <td class="lighttable"> or <td class=darktable>

Every element on your page needs a CSS class assigned to it - coresponding with the Threads Classes for them to appear.

Then it knows what it's supposed to display in what color and with what properties.


Joined: Feb 2002
Posts: 2,286
Veteran
Veteran
Joined: Feb 2002
Posts: 2,286
Looking at your page - you have created the page in FrontPage - and it has added

style="border-collapse: collapse" bordercolor="#111111" id="AutoNumber1"

These will overwrite any table settings within the Stylesheet - go to the html view and remove these items.



Fans Focus - Focusing on Fans of Sport

(Okay - mainly football (the British variety wink at the moment - but expanding all the time....)
Joined: May 2002
Posts: 153
Member
Member
Offline
Joined: May 2002
Posts: 153
Thank you to all for the responses.
Looks like it si going to be more complicated than I anticipated :-)
For now I can not even understand what is it that you are suggesting :-( but I will look at it and try to figure it out before my next post for help

I take it it will be a lot of work to change all existing pages and that it is not just a matter of adding some headers to the exisating pages...

Sponsored Links
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
JaneDoe,

Okay Lets see if I can make it a little easier to understand. You can add as Allen said the stylesheet call that is easy.

<link rel="stylesheet" href="/freeboard/stylesheets/infopop.css" type="text/css" />

However I do not even bother with this. Any page of content on my site I remake into a PHP file and use Threads header and footers. This makes my entire site look uniform. There is a hack here called BasicPage which will show you how to do this.

If you choose to just add the link statement like you already suggested to your HTML files then follow Josh's advice. A stylesheet is made up of CLASS calls. This is what tells the page what to load. In order to accomplish this a class call must be in the html tags where you want them to display the appropriate tag. Here is an example

<table class="tableborders">
<tr>
<td class="darktable">
CONTENT HERE
</td>
</tr>
</table>

This will create a table with Threads table border around it whatever content you place in the table and it will be colored like the darktable in the forums.

Allen has posted alot of good links in the New Forum Design Matters here at ThreadsDev that may give you some insight on how CSS works if you have trouble understanding the basics.







Joined: May 2002
Posts: 153
Member
Member
Offline
Joined: May 2002
Posts: 153
Thank you again.
Looks like this is a case of "can not get there from here"
I need to learn a few thing before...

What would be the best way to make the rest of a site look like UBBthreads?

Or is that silly? Should I just make the board look like the rest of the site?

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
he he

It's easy to do - but your pages have to be setup to use CSS classes.

You're a client of mine - I'll send you an example.

Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
Josh will get ya in the right direction

I make my entire site look uniform by using the basic page and calling the headers and footers from Threads as well as the stylesheet. As Josh stated you then need to make sure the html you have gets added the CLASS variable instead of any COLOR variable you use now.

Right now you probally have something like this in your html

<table width="100" color="#00000">
<tr>
<td color=#FFFFFF">
BLAH
BLAH
BLAH
</td>
</tr>
</table>

To use the threads CLASS calls it needs to be something like this for instance

<table width="100" class="tableborders">
<tr>
<td class="darktable">
Content here
</td>
</tr>
</table>

Joined: Feb 2002
Posts: 2,286
Veteran
Veteran
Joined: Feb 2002
Posts: 2,286
[]janedoe said:
Thank you again.
Looks like this is a case of "can not get there from here"
I need to learn a few thing before...

What would be the best way to make the rest of a site look like UBBthreads?

Or is that silly? Should I just make the board look like the rest of the site? [/]

Not silly at all - in my site all the other applications used, have to blend into threads - rather than threads blending into them. This might be news, photos, chat etc.

Check out the modifications section for some useful mods to benefit you (including a template mod), and also look at the IIP & side bar pal, both to be found in the IIP section.


Fans Focus - Focusing on Fans of Sport

(Okay - mainly football (the British variety wink at the moment - but expanding all the time....)
Sponsored Links
Joined: Sep 1999
Posts: 76
Power User
Power User
Offline
Joined: Sep 1999
Posts: 76
I guess my request is similar to the original poster. I've been using a single stylesheet for the entire site/forum, and everything looks uniform throughout.

But I've recently been toying with the idea of creating or installing new stylesheets for the forum but I'd like these to be used throughout the entire site as well. If a user isn't logged in, then the default stylesheet should be used.

Is what I'm asking possible? Right now, all my site pages (i.e. non forum) have CSS references to the forum's default stylesheet.

Cheers.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
It's possible if you do 1 of two things...

a) Code all your HTML in the regular pages to use Threads classes (tdheader, lighttable, darktable etc....)

b) Add the classes you use in the rest of the site to your threads stylesheets.

Take a look at the generic page mod posted here.... you'll see how you can included the main.inc.php file and then authenticate the user to get the preferred stylesheet.

If these aren't PHP pages, then I'm not sure how it would know what stylesheet to use, and you'd have to hardcode the stylesheet you want into the header of the html pages.


Joined: Sep 1999
Posts: 76
Power User
Power User
Offline
Joined: Sep 1999
Posts: 76
All my pages currently are using the threads classes so that part is OK.

I'll look into the generic page mod, as that sounds like the kind of thing I need (authentication, looking up stylesheet preference, etc).

Cheers.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Basically, if it's a PHP page, you need this:

Code
<br />include("/path/to/your/threads/install/main.inc.php");<br /><br />$userob = new user;<br />$user = $userob -> authenticate("U_StyleSheet");<br /><br />$stylesheet = $user['U_StyleSheet'];<br />if ((!$stylesheet) || ($stylesheet == "usedefault")) {<br />    $stylesheet = $theme['stylesheet'];<br />}<br />


Then something like this in the <head></head> of your page.

<link rel="stylesheet" href="http://www.whatever.com/forum/stylesheets/$stylesheet.css" type="text/css" />

Joined: Sep 1999
Posts: 76
Power User
Power User
Offline
Joined: Sep 1999
Posts: 76
Thanks Josh! Just what I was needing


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Posts: 70
Joined: January 2007
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)