I have started looking into scripts for screen size detect with the
intention of using them to pick from a number of CSS style sheets tailored
to the size.
Is there a good reason why this is not so commonly done? IE am I wasting my
time?
---dE|_--- 24 3005
dE|_ wrote on 07 nov 2007 in comp.lang.javas cript:
I have started looking into scripts for screen size detect with the
intention of using them to pick from a number of CSS style sheets
tailored to the size.
Is there a good reason why this is not so commonly done?
screen size != window size != window display size.
IE am I wasting my time?
Also FF [fery futile].
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
dE|_ wrote:
I have started looking into scripts for screen size detect with the
intention of using them to pick from a number of CSS style sheets tailored
to the size.
Is there a good reason why this is not so commonly done? IE am I wasting my
time?
---dE|_---
Bad idea. I once found a website I needed to get information from which
appeared totally blank. Eventually looked at the source, and found that
the designer had selected (Javascript) different layouts and image sizes
for a range of different viewport sizes, and none matched my 1920x1620
screen. Hence, a blank page.
Instead, google for "fluid css layout".
Phil, London
"Randy Webb" wrote
>>>Is there a good reason why this is not so commonly done? IE am I wasting my time?
Yes, you are wasting your time. Disable scripting and let us all know how
well it works then.
Correct me if I'm wrong but can't you have a 'no script' alternative?
---dE|_---
dE|_ wrote in
<KQ************ ***@newsfe7-gui.ntli.net>
"Randy Webb" wrote
>>>>Is there a good reason why this is not so commonly done? IE am I wasting my time?
Yes, you are wasting your time. Disable scripting and let us all know how well it works then.
Correct me if I'm wrong but can't you have a 'no script' alternative?
This isn't intended to sound as sarcastic as it might at first read but, if
you have a satisfactory 'no script' alternative, why don't you use that
instead?
--
PeterMcC
If you feel that any of the above is incorrect,
inappropriate or offensive in any way,
please ignore it and accept my apologies.
"PeterMcC" <pe***@mccourt. org.ukwrote in message
news:fg******** **@energise.ent a.net...
dE|_ wrote in
<KQ************ ***@newsfe7-gui.ntli.net>
>"Randy Webb" wrote
>>>>>Is there a good reason why this is not so commonly done? IE am I >wasting my time?
Yes, you are wasting your time. Disable scripting and let us all know how well it works then.
Correct me if I'm wrong but can't you have a 'no script' alternative?
This isn't intended to sound as sarcastic as it might at first read but,
if
you have a satisfactory 'no script' alternative, why don't you use that
instead?
It wouldn't be what I'm trying to achieve, it would just be better than the
blank screen I have been told I'll get if JS was disabled etc.
No insult taken my friend.
---dE|_---
"Chaddy2222 "
You can solve this issue with CSS alone... Google the
"background-repeat" CSS property.
Well I've found codes on forums I was not aware of for;
background-repeat:stretch and even background-repeat: expand stretch-left stretch-middle stretch-right;
W3c give background-size examples for body and div but I can't get anything from forums or W3c working on IE7 or FF2.
Anybody got a proven CSS method?
I am aware of X, Y, and no-repeats but they do not /Fill/ the page.
Just set your BG image to a width of 100% in your CSS. That should
work.
This is what's doing my bloody head in. W3c say;
body {
background-size: auto;
background-image: url(atwork.jpg) }
I tried that with auto and various % but got nothing but the usual repeats.
I replaced with
background-width: 100% but still getting nothing on either browser. Does
anybody actually _use_ this styling?
Sick of this, hanging up the mouse for the afternoon- got some strumming to
do.
---dE|_---
"PeterMcC" <pe***@mccourt. org.ukwrote in message
news:fg******** **@energise.ent a.net...
dE|_ wrote in
<KQ************ ***@newsfe7-gui.ntli.net>
>"Randy Webb" wrote
>>>>>Is there a good reason why this is not so commonly done? IE am I >wasting my time?
Yes, you are wasting your time. Disable scripting and let us all know how well it works then.
Correct me if I'm wrong but can't you have a 'no script' alternative?
This isn't intended to sound as sarcastic as it might at first read but,
if
you have a satisfactory 'no script' alternative, why don't you use that
instead?
The browser's elasticy stretching of the image wouldn't be as sharp as
photoshop and I'd rather it was cast iron once determined what viewpoint it
was in.
---dE|_---
Chaddy2222 wrote on 07 nov 2007 in comp.lang.javas cript:
Just set your BG image to a width of 100% in your CSS. That should
work.
How would you do that? Have you ever done that?
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
dE|_ said the following on 11/7/2007 9:20 AM:
"Randy Webb" wrote
>>>>Is there a good reason why this is not so commonly done? IE am I wasting my time?
Yes, you are wasting your time. Disable scripting and let us all know how well it works then.
Correct me if I'm wrong but can't you have a 'no script' alternative?
If you have a non-script solution then a script solution becomes redundant.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javas cript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/ This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Michael Hill |
last post by:
I have a perl script that i use to render a html page. In that page i
call out a stylesheet. If the user has a 800x600 display the fonts are
really too big.
Since screen resolution is a function of the client and I have this
javascript ot detect the srecc size:
function ck_res()
{
if ( (screen.width != 1024) && (screen.height != 768) )
{
|
by: Marti |
last post by:
Dear everyone,
Its my understanding that IE6 now uses a default text-size of "Small"
rather than IE5's "Medium".
Since I have used relative font-sizes (usually in ems) on all my
sites, I am now getting reports of "your fonts are too tiny" from
various users. Of course, the sites still look fine if those users set
their text-size to medium, but face it -- most people don't even know
thats an option.
|
by: Chris |
last post by:
After exhausting my search on the MS website, I can't find a straight answer.
I fin dit hard to believe that MS left our something so useful in ASP.NET as
screen resolution detection.
Problem:
I would like to detect, get values for, the screen resolution in px but in a
code behind. Is this possible?
There is a System.Windows.Forms.Screen class for the Windows client side,
why are there none for browser/ASP.NET client?
|
by: BillZondlo |
last post by:
Can someone look at this and tell me why, when I call this from my main app,
it displays fine (fades form in and out) but then before my main app
displays, I see other dialog boxes flash monentarily on the screen and this
delays the main app display?
Here is the fade which I compile to a dll and call from my main app:
using System;
using System.Threading;
using System.Timers;
|
by: Robert Bull |
last post by:
I have created an asp.net app on my machine where the resolution is
set to 1280 x 1024. When my users view the form on their screen, some
of the controls display differently than on my screen. One solution I
have is to use some javascript to determine the resolution of their
screen and redirect them to a duplicate form suited better for their
resolution but I would have to maintain multiple forms. Anybody know
of a better way to handle...
| |
by: Chris |
last post by:
I think I placed this in the wrong news group so I'm moving it here.
Suggestion to Microsoft make the categories more clear and make better
sense. ASP.NET should be its own group, why bury under Framework. And I see
others doing the same mis-posting to dotnet.general which appears to be
gearded more towards windows applications. What are General and Framework for
options under .NET Development!
After exhausting my search on the MS...
|
by: What-a-Tool |
last post by:
I recently created an application on my 19" monitor - looked good.
Tried running it on a 17 inch monitor - didn't look so good anymore.
Is there a way that monitor resolution/screen size can be detected, so that
I could keep my controls and form displayed and centered without resorting
to scroll bars?
Same problem with running a form Maximised or minimised.
Is there a way to detect if a form is in it's maximised or minimised state,
and...
|
by: Maxi |
last post by:
I have a 30X16 cells table in my html page. Table height and width are
set to 100%. I have set size of every cell inside the table to 24
pixel.
When I open the html page in maximize state in either resolution 800 X
600 or 1152 X 864 it takes up the entire explorer size.
In screen resolution 800 X 600, if I insert a pictures of 24 X 24 pixel
in the cells it takes up the entire cell size (ideally it should as the
cell size is also 24 X...
|
by: ultraviolet2006 |
last post by:
Hi folks!
I have a question: I am Designing a Wap Site Using XHTML-MP Language,CSS and ASP (Active Server Page), the Problem is how to detect the Screen Size of the Mobile Visiting the site, so as to assure to redirect him to the proper page for viewing the proper image size.
I have read articles about UAPROF and iam been able to extract the x-wap-profile Header by ASP, UAPROF is a URL that points to XML document that contains information...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |