Support » Fixing WordPress » pop ups in php

  • Resolved jamesgraham2k1


    i was told before using java try and find a PHP alternative. well I want to make a pop up window for certain links so i can control the size etc. is this possible with php? if not how can I empliment the java so it works with word press? any help is apreciated thx.

Viewing 10 replies - 1 through 10 (of 10 total)
  • anyone?

    Can someone please help me?

    1. Your question isn’t clear. I for one am not at all clear what you are trying to achieve.

    2. When you “bump” your request with an “anyone” it shows that your question has already been replied to.

    3. Patience. No one is paid to answer your questions here.

    Generally speaking for popups, you would not use Java, you would use Javascript. PHP can output the content of the Javascript for you, but you have to have some way to tell the browser at the other end to open a new window. PHP doesn’t run on the client (the browser) it runs on the server. Javascript runs on the client side, so it can do things like opening a new window. PHP can produce the code that will go in the new window, but something has to happen on the client side to tell the browser to open the new window.

    “well I want to make a pop up window for certain links so i can control the size etc.”

    This is considered a rude thing to do these days. It has been proven time and time again that popups are a very bad idea on public websites.

    the pop ups are when a “lyrics” link is clicked so the lyrics are in a seperate window. I dont find this rude. right now im using target="_blank" but it fills the entire screen I want it just big enough for the Lyrics to fit.

    While you may not find it rude, your users probably do: target=”_blank” was a mistake to begin with and is depreciated for exactly this reason. In fact it’s already invalid, if you’re using XTHML strict, and it’s days are obviously numbered.

    See for more.

    well what is a better alternative so the page with the song isnt left when the lyrics are viewed? Im open to sujestions?

    Who decided that forcing the user to stay on one particular page is a good thing? It’s not. Just forget about controlling the user experience. The only people who want do that don’t understand what the web is about, so be one of the other people:

    Leave the user of your website in charge.

    jamesgraham2k1, I disagree with pizdin_dim. There are lots of situations (help files, for example) where something like you are describing is exactly the right solution. The problem you will run into is not that people are inherently hostile to having a small window popup for additional information when it’s expected and appropriate. Most of us won’t be offended as it is MUCH more convenient than navigating back and forth from page to page. But you will have a problemt because the prevalence of popup advertising has many people using popup blockers and the less technically inclined will simply assume that your links aren’t working.

    Regardless, whoever told you “java” was a bad solution either a) thought you really meant a Java class which really would be a hideous solution and not a javascript which is a completely different thing or b) they were off their rockers. Javascript is the simplest and best way to achieve what you want to achieve.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘pop ups in php’ is closed to new replies.