|
|
#1 |
|
Prospect
Join Date: Mar 2004
Posts: 39
|
Can anyone help with some Javascript?
Sorry if this is the wrong forum to post this question in, but I couldn't see an obvious alternative, and it does, in a round about way relate to an application. (any browser)
Im trying to pop a window off of one of the pages on my site and I would like the window to be fullscreen, and as plain as possible ie; no nav, no scroll bars etc... I do not know any Javascript, but have managed to piece this together from various sites, it kind of works but is not full screen, can someone tell me what i'm doing wrong. Code:
var newwindow;
function popup(url)
{newwindow=window.open(url,'name','screen.availHeight,screen.availWidth');if (window.focus) {newwindow.focus()}}
</script>
Maybe there is a better way of doing this? Also Will I have problems with this in different browsers and on different platforms? Thankyou for any help +Daily PS: Its not for spamming purposes
__________________
When the going got wierd, I turned pro Last edited by Daily; 03-21-2005 at 12:33 PM. |
|
|
|
|
|
#2 |
|
League Commissioner
Join Date: Jan 2005
Posts: 8,475
|
Please, please, please: NO POP UPS!
|
|
|
|
|
|
#3 |
|
Triple-A Player
Join Date: Oct 2004
Posts: 68
|
Full screen windows are generally not very well received by many people unless they are specifically looking for a full screen window. Personally I hate it when somebody else controls the size of the window I am looking at. If you really have a reason for it, make sure that the visitor knows its going to pop up and that they have to click on a link to do it (not automatically). If it's automatic safari will block it anyways.
That said, I'm not very good with javascript but when I need help this site is: http://developer.irt.org/script/window.htm there are a couple different questions on that page about full screen windows, just do a search on the page. |
|
|
|
|
|
#4 |
|
Hall of Famer
Join Date: Sep 2003
Location: Old Europe
Posts: 4,969
|
I am afraid, your request might damage your reputation here more than you think.
Like cwtnospam said, you should probably even forget how you managed to want to do something like that in the first place. I am unable to stretch my imagination enough to come up with a legit use of such a function by a respectable website. Added: 2005-03-21 18:51 Uhr Well, I can see valid reasons to do so now. However, counting myself in on the net.police rant, I will refrain from contributing on the subject. Answers here are not due, but offered to those who ask in a way that encourages a reply. Last edited by voldenuit; 03-21-2005 at 11:54 AM. |
|
|
|
|
|
#5 |
|
Prospect
Join Date: Mar 2004
Posts: 39
|
Yeah thanks cwtnospam, thats just the kind of narrow minded response I need, Not that I should have to justify to YOU or anyone my purposes for the need to use a popup, I will in this case since I do need help and I do understand that people abuse Javascript in this way for bullshit advertising...
I am an art/graphic student and have sections on my site where I need the veiwer to open a new page, containing large format layouts and photography, the reason for "fullscreen" is that I want my work to be viewed in as near as I can get to a "controlled environment" which is extremely difficult to do in the world of the web. Here is an example page: http://trustyeight.com/trustyeight/i...p?idcatside=93 +Daily
__________________
When the going got wierd, I turned pro |
|
|
|
|
|
#6 |
|
Prospect
Join Date: Mar 2004
Posts: 39
|
Id also like to point out that my site is for prospective clients and people who need/would like to preview my work, these people will want to see my work, how I intend it to be seen, if that happens to be on a medium grey backround without any obtrusive nav/scroll bars then I feel that is legitimate, if people are that against it then they should switch off Javascript in their browser prefs and not look at my work, I do not appreciate the "Police the Web" Mentality, although I do understand that *if* you know how to do something you reserve the right to keep it to yourself if you feel it may be abused.
+daily www.trustyeight.com
__________________
When the going got wierd, I turned pro |
|
|
|
|
|
#7 |
|
League Commissioner
Join Date: Jan 2002
Posts: 7,963
|
Wouldn't 'fullscreen' to create a 'controlled environment' vary a lot depending on the local video capability? (Think 12" iBook, then a 30" LCD...)
|
|
|
|
|
|
#8 |
|
Prospect
Join Date: Mar 2004
Posts: 39
|
yes, I understand what you are saying, but im afraid you dont understand me, the "controlled environment" refers to covering up any lary / coloured background, and customised browser nav and scroll bars, I did say that a "controlled environment" is extremely difficult to reproduce accross the web, but it is allot better than nothing, with fullscreen I get to position my work in clear veiw, centered at the correct height etc... I could argue this all day, and am surprised at the agitated response I have insighted, but I do appreciate the discussion on the topic and appreciate people taking the time to reply to me.
thankyou +daily www.trustyeight.com PS: notice how I do not inflict my fullscreen preference anywhere other than where I feel it is required, in fact I even offer it as a "serving suggestion on the main page"
__________________
When the going got wierd, I turned pro |
|
|
|
|
|
#9 |
|
Prospect
Join Date: Mar 2004
Posts: 39
|
voldenuit, I understand and appreciate your response, I have somewhere in the region of 30ish posts here more often than not requesting some help with something, I do not feel that I have a problem asking for help in a way that encourages respose, I have never seen anyone here react to a help request like this, thats pretty patronising on your part, since it would seem that the error was on your part, instantly jumping to negative conclusions, perhaps there should be some guidelines on what exactly you can ask for help with and what you can't > many many requests and answers here can be used in a negative way, maybe most of the Unix section should be censored?
+nice one mate, you're right, I am unlikely to get any help, and proberly have "damaged my reputation here"
__________________
When the going got wierd, I turned pro |
|
|
|
|
|
#10 |
|
League Commissioner
Join Date: Jan 2005
Posts: 8,475
|
Daily,
You've got to understand that popups leave such a bad taste and are so overused and abused that even for legitimate uses they're not well received. Essentially, they've become bad design. A better method would be to use the html code used by this site (view source, search for links to your site) to create links that people could click. If the resulting page would best be viewed full screen, the user can easily choose to expand the window. Of course, it's your site, and you can do what you want, but if people believe that your site attempts to control their systems, they won't be back. |
|
|
|
|
|
#11 |
|
Prospect
Join Date: Mar 2004
Posts: 39
|
EDIT: [cwtnospam, have a look at this page, this is where the window pops off from, it is entirely of the users own accord, I will consider putting a note warning the visitor that a new window will open. http://trustyeight.com/trustyeight/i...p?idcatside=38
Is this really unreasonable?] That's right, I do understand. I myself have unsolicited pop-ups blocked, it's interesting that you mentioned bad design, because in this case it is in name of good design. Perhaps it's the term "pop-up" that has caused all the fuss, sure I could use HTML and just link and create a new page, but I require the ability to position that page and control how that page looks. I am definitely in agreement about not using "my system to control their system," but what I am doing is creating a NEW window on top of the existing site window, when a user chooses, in the specifications that suit both my work and most likely the viewers needs, it is the designers job to create a suitable environment for their work to be viewed in and know what is best for the end user, I also see it to be my right to show my work in any way I see fit. The problem here is the negative over reaction to a genuine post asking for help. I would say that the majority of posters here are very intelligent people, and yet not ONE single person bothered to ask what my need for resizing a browser window would be. Just because pop-ups are abused does not mean that those that need them for legitimate reasons should be put down. If that were the case then we should apply that logic everywhere and see how well it works... Hmm Cars, Alcohol, Guns, Governments, headache pills, knives... etc. etc., these are just a few random things I can think of off the top of my head, that get used and abused in a negative way and if you put your mind to it, almost everything is used in ways that are considered to be negative... No hard feelings anyone, this is certainly an interesting debate, the suggestion that all kinds of pop-ups used for any reason what so ever all over the entire planet on hundreds of thousands of web-sites, should be banned, strikes me as small minded, and I suspect that the people who seek this perspective exercise this control freakism over other facets of peoples lives. +daily
__________________
When the going got wierd, I turned pro Last edited by Daily; 03-21-2005 at 03:25 PM. |
|
|
|
|
|
#12 |
|
League Commissioner
Join Date: Jan 2005
Posts: 8,475
|
[QUOTE=Daily]EDIT: [cwtnospam, have a look at this page, this is where the window pops off from, it is entirely of the users own accord, I will consider putting a note warning the visitor that a new window will open. http://trustyeight.com/trustyeight/i...p?idcatside=38
Is this really unreasonable?] In a word, yes. It's bad enough that the page pops up full screen, but then it doesn't let the user adjust (at least on my work PC, maybe my Mac can?) the size! That's almost certain to be closed immediately. You're forgetting that beauty is in the eye of the beholder. It's the user who determines whether or not your web page looks better in full screen or not. You certainly can't, because you don't know what size screen they've got or what else they're using it for. If you force a full screen popup on them, they'll close the window and go away. The reason pop-ups are so hated is that EVERY web designer thinks that his/her page should be shown in front of all others and at full screen size. If you want to do something really good, try using frames. Make one within your web page where new "pages" appear. You can make the frame any size you like and then the user can decide if they want to see the entire frame or scroll through it. |
|
|
|
|
|
#13 |
|
Prospect
Join Date: Mar 2004
Posts: 39
|
This is unreasonable? My page IS opening full screen? The whole reason I was posting was that it wasn't... About the not being able to re-size the window, you can on a mac, I was unaware that you couldn't on a PC, yes that IS unreasonable and I will look into that. Frames are ugly even if you are careful to hide them, and cause all sorts of other problems, I hate frames proberly as much as you hate Pop-Ups, I don't care what other designers do (I am not a web designer) and consider nothing off limits just because others act like dicks. My point is: Know your target audience... and I do. My site is only designed for those that atually need/want to view my work... not for anyone that comes accross it through a bit of googling, this sounds pretentious I'm sure, but there is good reasoning behind this. Try not to look at all things with every day eyes.
Thankyou for taking the time to debate this, you have made some valid points, (despite whether I agree or not) my site is still in extremely early stages, and although I will not compromise on the javascript window, I will most likely not pursue full screen. +Daily Delight
__________________
When the going got wierd, I turned pro |
|
|
|
|
|
#14 |
|
MVP
Join Date: Oct 2003
Location: New York
Posts: 1,506
|
hey daily---FWIW, I posed this same question to a friend of mine when i was first learning web design...and the answer was the same. he basically didn't help me becuase he didn't agree with my methods. I think this is one of the rare cases where assilimation is good.
Resistance Is Futile
__________________
“If more police, more prisons and more prosecutors was a solution to safer streets, the United States and China would be the safest countries on the planet, and they’re not..." -Jane Sterk |
|
|
|
|
|
#15 | |||||||||||||||||||||||
|
Hall of Famer
Join Date: Sep 2003
Location: Old Europe
Posts: 4,969
|
I have indeed lacked imagination and what you are trying to do definitely is respectable. Whether it is a good design/human interface decision has been debated and my point of view on the subject does not need further development. As you turn out to be aware of the problem, asking your question in a way prominently showing your awareness of common abuse of that function would probably have helped to start a thoughtful debate immediately without three posts pointing out you were trying to do a Bad Thing first. Calling people narrow-minded, even if you think they are, will probably not further their willingness to maintain a conversation neither. My assumption was wrong, however you want useful answers, so looking out for ways to avoid this kind of misunderstanding is probably helpful. Questions are often asked in a how can I do A using program B rather than how do I solve problem C. Given the fact that the question that really needs to be solved is the second one, it is often a good idea to state what you're up to. That provides at least a bit of context to come up with the most helpful answer. Which is basically what this whole forum is all about. |
|||||||||||||||||||||||
|
|
|
|
|
#16 | |||||||||||||||||||||||
|
League Commissioner
Join Date: Jan 2005
Posts: 8,475
|
It opened full screen on the PC and full screen height on my Mac, not full width. You're right, it can resize on the Mac. As long as you don't care if people use the site, I guess you'll be happy with it your way. My personal feeling is that if it works well on the Mac, then who cares about PC users? They're used to things not working right anyway.
|
|||||||||||||||||||||||
|
|
|
|
|
#17 |
|
Prospect
Join Date: Mar 2004
Posts: 39
|
what can I say? Volenuit, I have no idea what your problem is, your argument over and over is that I was unreasonable with my request, go back and read my first post, then read it again. (and I did explain what I was trying to do, and placed it within a context, I admit though I didn't put my hand up and say that it was for good not evil) I was perfectly polite, did not demand an answer, and only asked if someone with a bit of javascript knowhow could POINT OUT WHERE I MAY HAVE GONE WRONG, not decide that what I choose to do on my site is un-ethical, the fact is you jumped to the wrong conclusion, you're the prat not me. Don't tell me how I should ask a question you mini-hitler, yeah I did not think think about ill-use issues when I posed the question, because I am an easy going person who rarely thinks on the negative, next time you want to take a few stabs at someone ask them a few questions first, here's a quote from Bill Hicks: "why don't you take a look at the world around you... and shut the hell up" it's only a god damn extra page opening up, it can be closed with a short cut in seconds! Take a leaf from cwtnospams book, engage in some intelligent conversation and move the subject forward instead of dictating to people what they should and should not do, answer me this, can ALLOT of the stuff in the unix forum be ill-used?? yes it can, so go and bark up that tree too.
Resistance is Not Futile, hoho +daily
__________________
When the going got wierd, I turned pro |
|
|
|
|
|
#18 |
|
League Commissioner
Join Date: Jan 2005
Posts: 8,475
|
I think you're over reacting to volenuit's point. Basically, volenuit is right in pointing out that anything you do involving people requires that you consider their point of view. That includes design of any type and especially asking for help.
The most important rule of design is that the users dictate what is good. Like it or not, they are the ones who know best. The fact that they don't know how to, or can't easily create it is what gives the designer a job. |
|
|
|
|
|
#19 |
|
All Star
Join Date: Apr 2003
Location: OH
Posts: 934
|
just a shout out to Daily ... i like your site. and, if i maximize it and want to make it smaller, i can hit the green 'dot' in Safari.
|
|
|
|
|
|
#20 |
|
Site Admin
Join Date: Jan 2002
Location: Montreal
Posts: 31,941
|
Daily:
The language and tone you have used in some of the above posts is verging on the unacceptable for these forums. I don't care how much you feel insulted or frustrated - you still need to keep it civil. And please try to break up your posts into smaller paragraphs - or at least use a few carriage returns for their visual effect! |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|