ID:891555
 
(See the best response by Nadrew.)
Code:
client/script = {"
<style type=\"text/css\">
.say{
font-size: 10px;
}
.ooc{
font-size: 8px;
}
.admin_chat{
font-size: 12px;
}
.admin_alerts{
font-size: 12px;
}
</style>
"}


Problem description:
Hello~ Running into another issue here. I'm trying to make use of client/script in the dms files to organize a bit, making use of CSS. However, this is throwing a compile error at me, here it is;

D:\Documents and Settings\blabla\Desktop\Dragon Compass\TextCSS.dms:1:error at '/': variable not defined


I don't feel like the reference explained very well how to really, set client scripts. So far, from what I've read of the Guide, it also doesn't really tell me anything about dms files, nor writing client/script related things.

If there are resources regarding it, I'd appreciate if I could be linked to them~

Client scripts (and client/script) are no longer really supported, you should be utilizing interfaces and their various style settings.

The issue you're having is escaping the double-quotes around "text/css" since the string is in a multi-line block surrounded by {" and "} you don't need to escape quotation marks.
I updated that, as you said, and the error still comes?

Also; What is the purpose of doing some complicated interface stuff, when I can just create a simple stylesheet and add the classes to html?

mob/verb

Say(t as text)
if(t != "")
view() << "<font class='say' color=\"[src.TextColor]\">[src.name] says, \"[html_encode(t)]\"</font>"


Giving it a class so I can manipulate the style without heaps of inline styling is a lot cleaner imo.

I don't really intend to use client/script for more than that as of now.


Edit: Oops, should be 'say', not '.say'
Best response
All you have to do in the interface is give the output control you're using's 'style' variable the CSS you want, now you can use classes properly.

client/script is obsolete because of this.

The CSS you posted works fine for me without the improperly escaped quotations.
I totally forgot about the styles section, lol. It's a lot easier to put the CSS there instead, so this is solved. Thanks Nadrew!