PDA

View Full Version : Prefix url if storing CSS as a files


Zachery
01 Oct 2005, 19:57
Update to my original by use of a plugin.

http://www.vbulletin.org/forum/showthread.php?t=63520

THE FILE IS A PLUGIN NOT A PRODUCT!

Dan
01 Oct 2005, 20:02
Nice one ;)

kall
01 Oct 2005, 23:01
Nice one ;)

I've been using this since you released the 3.0.x version Zach.. I am most pleased to see that my 'port' was exactly the same as this. :)

Zachery
01 Oct 2005, 23:21
I've been using this since you released the 3.0.x version Zach.. I am most pleased to see that my 'port' was exactly the same as this. :)

Its not exactly any huge code changes, just some small varible updates and some {} around one of them :)

Boofo
02 Oct 2005, 01:55
What does this do exactly?

kall
02 Oct 2005, 02:42
What does this do exactly?

If you store your css in a file, by default you will have difficulties getting the style to be called when not in your /forums directory.

If you apply Zachs plugin, it will prefix the output of $[css] with $vboptions[bburl]. :)

Boofo
11 Oct 2005, 15:31
If you store your css in a file, by default you will have difficulties getting the style to be called when not in your /forums directory.

If you apply Zachs plugin, it will prefix the output of $[css] with $vboptions[bburl]. :)

Ok, either this didn't work for me or I am missing something. :(

Zachery
11 Oct 2005, 18:35
Ok, either this didn't work for me or I am missing something. :(

Are you already storing CSS as files bob?

monstergamer
11 Oct 2005, 18:45
nice work :)

Boofo
11 Oct 2005, 18:56
Are you already storing CSS as files bob?

Yes, I are? ;)

Zachery
12 Oct 2005, 18:25
Yes, I are? ;)

It should add a full url infront of path then...

Are you sure its not working?

Boofo
12 Oct 2005, 19:11
It should add a full url infront of path then...

Are you sure its not working?

Where would I see that at?

Zachery
12 Oct 2005, 19:38
Where would I see that at?

View the source bob

the path to the css file should be prefixed with your domain name.

Give me a link to your site so I can take a look :

Neutral Singh
13 Oct 2005, 07:15
mine is also not working.
http://www.sikhphilosophy.net/sikhphilosophy/blog/

Boofo
13 Oct 2005, 07:20
View the source bob

the path to the css file should be prefixed with your domain name.

Give me a link to your site so I can take a look :

Ahhh, ok, then it's working right. I just checked the View Source and the full path to the css file is there. I was thinking it was supposed to be a part of the file name which didn't make sense to me. Sorry about that. ;)

Oreamnos
13 Oct 2005, 09:33
Simple & extremely useful! Thanks! :)

bangthebook
13 Oct 2005, 18:24
I think this is what I am looking for but I am not sure how to use it.

If you visit my site www.bangthebook.com the homepage header uses the css file for the background etc. How do I get this to happen in the forum as well. If I understand right this plugin does it yet I cant get it to work. What am I missing.

Sorry if I am way off here
Thanks
Ryan

Oreamnos
13 Oct 2005, 23:51
it looks like you have at least 2 style sheets, one for your index.php page and one for your forum. if that's ok with with you then you don't need this plugin.

this plugin is useful if you have pages outside of your forum/ directory and you wantto apply your vb styles to them. this plugin allows any page outside of your forum/ directory to access the css file.

for example, notice on expatbars.com that the index page has the same style as expatbars.com/forums/ and expatbars.com/gallery/ and if you view the source you can see that the css file is linked with the complete URL, not just "clientscript/vbulletin_css/123.css

hope that helps
eric

bangthebook
14 Oct 2005, 00:52
yes it does. Thanks. Any ideas how I can get the reverse of this for my header? Its driving me nuts to have two different ones

Zachery
14 Oct 2005, 02:17
mine is also not working.
http://www.sikhphilosophy.net/sikhphilosophy/blog/

You are not storing CSS as files.

Oreamnos
14 Oct 2005, 02:20
yes it does. Thanks. Any ideas how I can get the reverse of this for my header? Its driving me nuts to have two different ones
i'm not sure i understand what you want to do?

Do you want to have only one css file?

Logikos
06 Apr 2006, 05:57
Thank you for this Zach. I didn't know you released untill I requested that Jelsoft put the option back in the admincp. :)

http://www.vbulletin.com/forum/showthread.php?t=181076

/me clicks install ;)

Cky47
01 May 2006, 11:42
Does anyone know what the heck is wrong with my site? I have it set to store as files, and I have this plugin installed. But when I lookedat my source, it isnt showing it as a file. I would really like some help, becasue I hate seeing the css in the code.

Zachery
01 May 2006, 18:21
vbulletin can't write the css files to the directory, ensure that it has the proper permissions and disable/reneable the option.

Cky47
01 May 2006, 21:02
Which directory? I thougth I did that...

Cky47
01 May 2006, 22:54
I didnt know what permissions to give it, but I gave it to them, and now its working.

What number should I have set?

Zachery
02 May 2006, 08:10
777 ;) just like the instructions say

imranbaig
23 Jun 2006, 21:17
its really nice Thanks, reduces page size :)

Zachery
21 Aug 2006, 18:48
Still working in 3.6

Gastongr
26 Aug 2006, 09:00
Awesome!.
thanks Zachery

abenoking
14 Jan 2007, 21:29
This appears to be exactly what I am looking for, but excuse my niavety: how do you actually call this URL in an integrated non-vb page?

lostgirl815
21 Mar 2007, 20:34
Forgive my ignorance, but is this what you'd use to be able to have your normal non-forum web pages be the same CSS style as your forum's style? Or is this something else?

blindMoe
31 Aug 2007, 00:53
First off, this is an awesome plug in.. I installed the Groups Commune package and it pointed me here as this is a required plug in if you are using the "store css as files" option and you want the Groups Commune to work.

I love this plug in and now I am wondering if the same could be done for <img> tags. Some components that reside in subdirectories have issues with templates that don't link to their images correctly. I am having a problem where the author of a template did not put in a leading '/' in the src='' statements ( ie: src="TemplateName/whatever.png" ). So the result is all my images are dead when I am in a subdirectory. ( ie: http://www.example.com/groups/ )

This is just an idea I had, I figured I may try writing it but seeing as I don't have much experience with VB plug ins I though I would leave it to the pro's. Time for me to go fix templates :(

Thanks again for helping out the community with this great plug in!

Jay-MOB
19 Sep 2007, 22:52
how do you use this?

I don't get it.

I installed it, what then?

Zachery
11 Dec 2007, 18:25
Then nothing, it works or you're not storing CSS as a file.

ekool
09 Dec 2009, 20:56
Anyone tested this with 3.8?

Zachery
10 Dec 2009, 23:40
Works just fine.

webmastersitesi
24 Feb 2011, 16:57
i tested works fine 3.8.6.1

yahooooh
13 Mar 2011, 12:28
it is not work for 4.1.2
could you update it plz

Zachery
14 Mar 2011, 18:58
vB4 does this by default with the base url option.