Pop-Up not showing

K

kiki

Hello,
I know this is a silly question! I have written some code that requires
a pop-up window to come up for the user to confirm that he/she does
want to purchase the goods they've ordered. The problem i have is that
if they have blocked pop-ups then that window won't show up and the
order will get confirmed without approval. Is there a command or a
work-around for this pop-up to be dispayed no matter the settings?

Thank you so much for this

K
 
E

Evertjan.

wrote on 01 mrt 2005 in comp.lang.javascript:
I know this is a silly question!
Yes?

I have written some code that requires
a pop-up window to come up for the user to confirm that he/she does
want to purchase the goods they've ordered.

<form
onsubmit='return confirm("Sure?")'>

The problem i have is that
if they have blocked pop-ups then that window won't show up and the
order will get confirmed without approval. Is there a command or a
work-around for this pop-up to be dispayed no matter the settings?

No, that is what is silly.
 
G

Grant Wagner

Hello,
I know this is a silly question! I have written some code that
requires
a pop-up window to come up for the user to confirm that he/she does
want to purchase the goods they've ordered.

Note the important parts of that sentence.

"I"
"requires"

So, YOU wrote it to REQUIRE a popup. Write it so it doesn't require a
popup, problem solved.
The problem i have is that
if they have blocked pop-ups then that window won't show up and the
order will get confirmed without approval. Is there a command or a
work-around for this pop-up to be dispayed no matter the settings?

Sure, the way you do it is window.open(url, target, DS3#%*);

Wow, good thing this post got corrupted while I was sending it to the
server, otherwise everyone would know how to do it and there would be
not point in having popup blocker software.


Anyway, why not fix your design. You don't "require" a popup, you wrote
it to use one. Re-write it to not use one. Use a "wizard-style"
interface where the user clicks "Next", "Next", "Next" at each step in
the process of ordering something. FutureShop.ca does this, checking out
is a 5 step process:

1) enter or select pre-stored Shipping Address, click Continue Checkout
2) choose Shipping Method, click Continue Checkout
3) enter or select pre-stored Billing Address, click Continue Checkout
4) Confirm Order, click Confirm Order
5) Thank You!

I'm sure other online retailers use a similar workflow, no popups
"required".
 
K

Kiki

Hey Grant.. Aren't you a lovely chap! And for future reference, when
someone asks a question that you
a) don't want to reply, DON'T! or
b) you have no answer to that question, keep your mouth shut!

"I" was asked to program this "requirement". I don't know how old you
are but if you're not some geek that sits at home playing games the
whole, you would know something about companies and "REQUIREMENTS"!!!

Ok, for the rest of you, I have moved all the javascript code from the
aspx page to a js file within the same project. I've referenced that
file in <HEAD>
(<script language="javascript" src="location of file"></script>)
and initialised it
(<script language=javascript> window.attachEvent("onload", name of
onload function in js file);</script>) in the aspx file.

It seems to be working ok (so far and until XP SP3 ruins everything).
I do agree with whats-his-face that pop-ups should be avoided though
but sometimes, some people like vintage front-end!!

Thanks
K
 
R

Randy Webb

Kiki said:
Hey Grant.. Aren't you a lovely chap! And for future reference, when
someone asks a question that you
a) don't want to reply, DON'T! or
b) you have no answer to that question, keep your mouth shut!

Welcome to Usenet.

In the future, if you have a question and there is a possibility of an
answer you don't want to hear, don't ask it because odds are you will
get the answer you don't want. Deal with it. This is not a help-desk,
its a discussion group. If you happen to get the answer you want in that
discussion, fine. If not, lump it.
"I" was asked to program this "requirement". I don't know how old you
are but if you're not some geek that sits at home playing games the
whole, you would know something about companies and "REQUIREMENTS"!!!

Oh geez. Does your mommy know you are on her computer? Besides, if you
are stupid enough to try to implement a stupid idea, then you deserve
what you get.
Ok, for the rest of you, I have moved all the javascript code from the
aspx page to a js file within the same project. I've referenced that
file in <HEAD>
(<script language="javascript" src="location of file"></script>)
and initialised it
(<script language=javascript> window.attachEvent("onload", name of
onload function in js file);</script>) in the aspx file.

Ummmm, ok. If you say so. But it doesn't "work". I will leave it up to
you and your "requirements" to figure out why.
It seems to be working ok (so far and until XP SP3 ruins everything).

Yeah, and I bet your survey suggesting popups are acceptable is in a
popup huh?
I do agree with whats-his-face that pop-ups should be avoided though
but sometimes, some people like vintage front-end!!

I am one that doesn't, and I will never see a popup that I didn't want.
If you can't handle that, then my money is just as well spent somewhere
else.

Now, if you have made it this far, you should read this group's FAQ,
thoroughly. It will raise your IQ a minimum of 10 points.
 
K

Kiki

This is a comp.lang.javascript discussion group and I haven't seen
your two pence buddy! That was my issue with the guy before. What's
the point in judging someone's coding decision and question without
offering a suggestion to the solution or discuss possible solutions. I
know what a major hassle the pop-ups are but I wasn't asked to remove
them, I was asked to make this work!

And when I said about the vintage code, I wasn't referring to you or
to most of you. I was referring to my 50-year-old MD that all she
likes is pop-ups with all the essential info!!!

I just don't see the point of calling someone you don't know, stupid,
especially when the previous email was not addressed to you. The only
suggestion that you've made was that my solution won't work! That's
not really a "discussion", is it? Did you think it was because you're
stupid?? Bless!!

If you have made it this far, you should find yourself some friends
and a girlfriend (or boyfriend). It will raise your social skills a
minimum of 10 points.
 
L

Lee

Kiki said:
This is a comp.lang.javascript discussion group and I haven't seen
your two pence buddy! That was my issue with the guy before. What's
the point in judging someone's coding decision and question without
offering a suggestion to the solution or discuss possible solutions. I
know what a major hassle the pop-ups are but I wasn't asked to remove
them, I was asked to make this work!

You're in the wrong here. If you're not convinced of that
yet, you can keep arguing and hear it from any number of
regular posters to this newsgroup.

If you're a professional, one of your responsibilities
is to push back when your requirements are unreasonable.
I just don't see the point of calling someone you don't know, stupid,
especially when the previous email was not addressed to you. The only
suggestion that you've made was that my solution won't work! That's
not really a "discussion", is it? Did you think it was because you're
stupid?? Bless!!

You asked for a setting to work around popup blockers.
If you think about that calmly for a moment, you'll probably
see for yourself that it's a silly request. If there was
such a setting, there would be no point to popup blockers.

This isn't email. Nothing that you write is addressed to one
person. There have already been two suggestions posted that
would allow confirmation without popups. No further discussion
of those methods seems to be necessary. At this point we're
just trying to correct your misconception about how newsgroups
work.
 
M

Mark Preston

Kiki said:
[snip]
I know what a major hassle the pop-ups are but I wasn't asked to remove
them, I was asked to make this work!
You can't - **I** choose what to display on my PC, not you. The same
goes for your boss - whatever he may or may not like, it is ultimately
my choice, not his. I'm afraid people here have been as helpful as they
can and have politely tried to disuade you from going down this road.

What it comes down to is that, as a professional, it is your job to tell
your boss the truth and to show him why he needs to change his mind.
 
R

Randy Webb

Kiki said:
This is a comp.lang.javascript discussion group and I haven't seen
your two pence buddy!

Then you need to learn to read plain English.
That was my issue with the guy before.

Huh? What "guy"? If you had bothered to read what I typed, and followed
the advice to read this groups FAQ then you would be quoting what it is
you are babbling in response to.
What's the point in judging someone's coding decision and question without
offering a suggestion to the solution or discuss possible solutions. I
know what a major hassle the pop-ups are but I wasn't asked to remove
them, I was asked to make this work!

Let me quote you what I said about this stupid popup idea you have:

<quote>
Besides, if you are stupid enough to try to implement a stupid idea,
then you deserve what you get.
</quote>

And what you probably deserve the most is an award and a termination
check for not being professional enough to explain the bad idea your
"boss" came up with.

But you also asked "How do I stop a popup blocker from blocking my
popup?" That is a question that you, and every porn/spammer on the web,
would love the answer to. But all it takes is a little common sense to
ask yourself "Why do they use a popup blocker?" and you get the answer:
"They don't want popups". And then you wonder "Why am I trying to force
something on my users that they explicitly don't want?"
And when I said about the vintage code, I wasn't referring to you or
to most of you. I was referring to my 50-year-old MD that all she
likes is pop-ups with all the essential info!!!

I can find no reference by you to "vintage code". I did see where you
said it was "required", when it isn't. But if you want confirmation on
an order, use a confirm() and popup blocker's will have *NO* impact on it.
I just don't see the point of calling someone you don't know, stupid,
especially when the previous email was not addressed to you.

1) I never called you stupid, I called your idea stupid.
2) This is Usenet, not email. Learn the difference.

The only suggestion that you've made was that my solution won't work!

It wasn't a "suggestion", it was a statement of fact. And before you
question it, search the c.l.j archives for "attachEvent cross browser".
 
K

Kiki

Thank you all for your suggestions and the facts stated in discussion.
I have shown them to my boss and she blushed with shame - she didn't
take my word for it so that served her right. I'm sorry if some of you
got annoyed (and you can tell i just came back from holiday!). K
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,059
Latest member
cryptoseoagencies

Latest Threads

Top