Author Topic: Nitpick...  (Read 3198 times)

0 Members and 1 Guest are viewing this topic.

Offline Sandwich

  • Got Screen?
  • 213
    • Skype
    • Steam
    • Twitter
    • Brainzipper
Quote
Originally posted by an0n
CSS can be used to define parameters for the page. And you could get it to change the links for specific forums.

You could quite easily (albeit extremely tediously) make either the php of the boards or the css files reference some other parameter and get the boards to change the header link.


Ok, you've got me curious. Getting off the question of actually changing things, how does one use CSS to change a link on a page?
SERIOUSLY...! | {The Sandvich Bar} - Rhino-FS2 Tutorial | CapShip Turret Upgrade | The Complete FS2 Ship List | System Background Package

"...The quintessential quality of our age is that of dreams coming true. Just think of it. For centuries we have dreamt of flying; recently we made that come true: we have always hankered for speed; now we have speeds greater than we can stand: we wanted to speak to far parts of the Earth; we can: we wanted to explore the sea bottom; we have: and so  on, and so on: and, too, we wanted the power to smash our enemies utterly; we have it. If we had truly wanted peace, we should have had that as well. But true peace has never been one of the genuine dreams - we have got little further than preaching against war in order to appease our consciences. The truly wishful dreams, the many-minded dreams are now irresistible - they become facts." - 'The Outward Urge' by John Wyndham

"The very essence of tolerance rests on the fact that we have to be intolerant of intolerance. Stretching right back to Kant, through the Frankfurt School and up to today, liberalism means that we can do anything we like as long as we don't hurt others. This means that if we are tolerant of others' intolerance - especially when that intolerance is a call for genocide - then all we are doing is allowing that intolerance to flourish, and allowing the violence that will spring from that intolerance to continue unabated." - Bren Carlill

 

Offline an0n

  • Banned again
  • 211
  • Emo Hunter
    • http://nodewar.penguinbomb.com/forum
Quote
Originally posted by Sandwich
Ok, you've got me curious. Getting off the question of actually changing things, how does one use CSS to change a link on a page?

You get it to point to some arbitrary file full of definitions and have it reference something based on a constant in the file, such as it's forum number or some ****. Then you just change the definition within the list file thingy. You change 40 files in a one-off and afterwards only need to change and access one file to change something instead of trawling through it's own style sheet.
"I.....don't.....CARE!!!!!" ---- an0n
"an0n's right. He's crazy, an asshole, not to be trusted, rarely to be taken seriously, and never to be allowed near your mother. But, he's got a knack for being right. In the worst possible way he can find." ---- Yuppygoat
~-=~!@!~=-~ : Nodewar.com

 

Offline an0n

  • Banned again
  • 211
  • Emo Hunter
    • http://nodewar.penguinbomb.com/forum
And actually, you could probably get the php of the board to do it, by having the php looks for the constant and referencing the stuff for the right html to insert/generate.

The php uses the forumid= thingy to set the style used so you could probably put in a ton of IF thingies for the id number to set which header thingy to use. Or just edit the code so it sends it to the campaigns forum thingy instead of the main index.
« Last Edit: August 20, 2002, 11:37:09 am by 397 »
"I.....don't.....CARE!!!!!" ---- an0n
"an0n's right. He's crazy, an asshole, not to be trusted, rarely to be taken seriously, and never to be allowed near your mother. But, he's got a knack for being right. In the worst possible way he can find." ---- Yuppygoat
~-=~!@!~=-~ : Nodewar.com

 

Offline Sandwich

  • Got Screen?
  • 213
    • Skype
    • Steam
    • Twitter
    • Brainzipper
Quote
Originally posted by an0n

You get it to point to some arbitrary file...


That's the part I'm having problems with. AFAIK, CSS can't be used in this manner. If you know otherwise, let's see some CODE. :D
SERIOUSLY...! | {The Sandvich Bar} - Rhino-FS2 Tutorial | CapShip Turret Upgrade | The Complete FS2 Ship List | System Background Package

"...The quintessential quality of our age is that of dreams coming true. Just think of it. For centuries we have dreamt of flying; recently we made that come true: we have always hankered for speed; now we have speeds greater than we can stand: we wanted to speak to far parts of the Earth; we can: we wanted to explore the sea bottom; we have: and so  on, and so on: and, too, we wanted the power to smash our enemies utterly; we have it. If we had truly wanted peace, we should have had that as well. But true peace has never been one of the genuine dreams - we have got little further than preaching against war in order to appease our consciences. The truly wishful dreams, the many-minded dreams are now irresistible - they become facts." - 'The Outward Urge' by John Wyndham

"The very essence of tolerance rests on the fact that we have to be intolerant of intolerance. Stretching right back to Kant, through the Frankfurt School and up to today, liberalism means that we can do anything we like as long as we don't hurt others. This means that if we are tolerant of others' intolerance - especially when that intolerance is a call for genocide - then all we are doing is allowing that intolerance to flourish, and allowing the violence that will spring from that intolerance to continue unabated." - Bren Carlill

 

Offline Stealth

  • Braiiins...
  • 211
Quote
Originally posted by an0n
And actually, you could probably get the php of the board to do it, by having the php looks for the constant and referencing the stuff for the right html to insert/generate.
 


you could definately get the PHP to do it, because it's the PHP that has the links for the banners, it's a question of whether you could get the CSS to do it, like you said you could

i'm not sure about CSS... you might be able to, you probably know more about it than me, all i've ever used CSS for is an easier way to set colors, design, etc. of pages


Yes Sandwich, you did beat me :)  but only this time!!! :p

 

Offline an0n

  • Banned again
  • 211
  • Emo Hunter
    • http://nodewar.penguinbomb.com/forum
Tomorrow.

*is busy installing Apache, PHP, FTP and lots of other abbreviated junk on his computer*
"I.....don't.....CARE!!!!!" ---- an0n
"an0n's right. He's crazy, an asshole, not to be trusted, rarely to be taken seriously, and never to be allowed near your mother. But, he's got a knack for being right. In the worst possible way he can find." ---- Yuppygoat
~-=~!@!~=-~ : Nodewar.com

 

Offline Sandwich

  • Got Screen?
  • 213
    • Skype
    • Steam
    • Twitter
    • Brainzipper
Quote
Originally posted by Stealth


you could definately get the PHP to do it, because it's the PHP that has the links for the banners, it's a question of whether you could get the CSS to do it, like you said you could


Actually, in order to have PHP do it automatically, it would require an extra field in one of the vB MySQL databases that would store the homepage link of each sub-forum. Only then could vB assign the correct link, as the subforum pages are automatically generated by forumdislay.php and showthread.php.
SERIOUSLY...! | {The Sandvich Bar} - Rhino-FS2 Tutorial | CapShip Turret Upgrade | The Complete FS2 Ship List | System Background Package

"...The quintessential quality of our age is that of dreams coming true. Just think of it. For centuries we have dreamt of flying; recently we made that come true: we have always hankered for speed; now we have speeds greater than we can stand: we wanted to speak to far parts of the Earth; we can: we wanted to explore the sea bottom; we have: and so  on, and so on: and, too, we wanted the power to smash our enemies utterly; we have it. If we had truly wanted peace, we should have had that as well. But true peace has never been one of the genuine dreams - we have got little further than preaching against war in order to appease our consciences. The truly wishful dreams, the many-minded dreams are now irresistible - they become facts." - 'The Outward Urge' by John Wyndham

"The very essence of tolerance rests on the fact that we have to be intolerant of intolerance. Stretching right back to Kant, through the Frankfurt School and up to today, liberalism means that we can do anything we like as long as we don't hurt others. This means that if we are tolerant of others' intolerance - especially when that intolerance is a call for genocide - then all we are doing is allowing that intolerance to flourish, and allowing the violence that will spring from that intolerance to continue unabated." - Bren Carlill

 

Offline an0n

  • Banned again
  • 211
  • Emo Hunter
    • http://nodewar.penguinbomb.com/forum
Quote
Originally posted by Sandwich
Actually, in order to have PHP do it automatically, it would require an extra field in one of the vB MySQL databases that would store the homepage link of each sub-forum. Only then could vB assign the correct link, as the subforum pages are automatically generated by forumdislay.php and showthread.php.

Maybe. But I think you could do it with the existing fields and just change them all from like
.../aob/aobheadr.jpg
to
< a href = WHATEVER >< img src = ...aob/aobheadr.jpg >< /a >

And remove the PHP coding from forumdisplay that automatically links it to the main index.
"I.....don't.....CARE!!!!!" ---- an0n
"an0n's right. He's crazy, an asshole, not to be trusted, rarely to be taken seriously, and never to be allowed near your mother. But, he's got a knack for being right. In the worst possible way he can find." ---- Yuppygoat
~-=~!@!~=-~ : Nodewar.com

 

Offline Stealth

  • Braiiins...
  • 211
i agree with an0n... that should be the easiest and fastest way to do it

 

Offline an0n

  • Banned again
  • 211
  • Emo Hunter
    • http://nodewar.penguinbomb.com/forum
DISCLAIMER: an0n in no way endorses the changing of the forums from their current basic layouts and will kick and scream like a small, upset child should any changes be made to the layout or the methodology behind the links generated by the php of the boards
"I.....don't.....CARE!!!!!" ---- an0n
"an0n's right. He's crazy, an asshole, not to be trusted, rarely to be taken seriously, and never to be allowed near your mother. But, he's got a knack for being right. In the worst possible way he can find." ---- Yuppygoat
~-=~!@!~=-~ : Nodewar.com

 

Offline Stealth

  • Braiiins...
  • 211
Quote
Originally posted by an0n
DISCLAIMER: an0n in no way endorses the changing of the forums from their current basic layouts and will kick and scream like a small, upset child should any changes be made to the layout or the methodology behind the links generated by the php of the boards


they probably won't change it either... it's not serious ;0

  

Offline WMCoolmon

  • Purveyor of space crack
  • 213
The header should be stored in a single file somewhere, it doesn't make sense to have it in several different files instead of just using an include.
With that said, you should be able to use if-else statements to control the link for the header image.
Code: [Select]

if($forumid==8) {
print("< A HREF=\"sitelink\">");
} elseif($forumid==19) {
print("< A HREF=\"othersitelink\">");
}
-C