الشبكة العربية لمطوري الألعاب

مبتدئ  إياد طرابلسي مشاركة 1

Is the .CSS file specified with "only" the .HTM files, or we could use it in .ASPX files & it means with the WEB CONTROLES

Then is there anyway to creat the .CSS file from a page then editing it according to the needed purposes

محترف مشرف عبد اللطيف حاجي علي مشاركة 2

التعليق على مشاركة إياد طرابلسي في Dec 13, 2006 16:34 :
[eng:
> Is the .CSS file specified with "only" the
> .HTM files, or we could use it in .ASPX files & it
> means with the WEB CONTROLES
Yes, CSS "styles" (whether they were embedded in the page or in a separate .css file) can be used with ASP.NET Contorls. Lookup the CssClass property

> Then is there anyway
> to creat the .CSS file from a page then editing it
> according to the needed purposes
Why would you do so? I mean a .css *file* is designed to save bandwidth and to create a global style sheet for the whole site instead of making those CSS styles page-wise.
So if you want to change the CSS styles according to specific conditions, then this probably means that those styles won't be global to the whole website anymore, and you can use embedded style sheets instead of .css files. I mean something like:



[eng:
Or:
// In the code behind
HyperLink hyperSomeControl;
hyperSomeControl.Attributes["style"] = GetMyStyle();

One last "personal" note, I wish you can use more discriptive titles like: "CSS Styles in ASP.NET Controls". It's much nicer than "Stupid Question", don't you think?

عبد اللطيف حاجي علي
مبرمج
In|Framez

مبتدئ  إياد طرابلسي مشاركة 3

> Why would you do so?
> I mean a .css *file* is designed to save bandwidth
> and to create a global style sheet for the whole site
> instead of making those CSS styles page-wise.

I know that but....
If we could do it that means we can create the .CSS file by using graphic platform better than coding and then waiting for the result which could be not proper for your entire project's pages


>

خبير مدير وسام البهنسي مشاركة 4

على الأقل في Visual Studio يمكنك تحرير ملفات CSS بشكل "بصري". أي لست مضطراً لكتابة الألوان مثلاً بشكل يدوي، وإنما يمكنك انتقاء الألوان بشكل طبيعي من palette وما إلى ذلك. لرؤية التغييرات في الموقع بشكل مباشر فإن طريقة ملف الـ CSS الموحد عملياً أسرع. إذ يكفي أن تقوم بحفظ التغييرات في الملف قبل أن تقوم بعمل Refresh للصفحة في الـ browser لترى النتيجة...

وسام البهنسي
مبرمج في إنفيديا وإنفريمز

مبتدئ  إياد طرابلسي مشاركة 5

I Found two softwares which could be useful in encoding .CSS files
"TopStyle & StyleSpread" I don't know if they are realy usefull for Professionals but maybe we could have more facilities by using Style Sheet Designing softwares