Solved

JQuery Popup on links

Posted on 2011-09-19
2
375 Views
Last Modified: 2012-05-12
Hello Experts,

I am having a hard time with image popups over-lays on my site.

I am using this JQuery-based framework http://easyframework.com/
Around other features, if I assign a class of POPUP to a link that points to an image, that image is displayed in an overlay window.

Problem is that after upgrading to JQuery 1.6.1 the popups are not working anymore.

The error I am getting from FireBug is: $(this).attr("href") is undefined

Problem is that on my site there are a lot of links with a class of "popup" and it would take a lot of time to modify them all.
What I need is maybe a JQuery script that will work the same way: scan the page for links with a class of POPUP and make them open the content (image) in a popup.

Thanks so much!
0
Comment
Question by:daniel_spiri
2 Comments
 
LVL 40

Accepted Solution

by:
gurvinder372 earned 500 total points
ID: 36559843
$(".popup").each(function(){
  window.open($(this).attr("href"));
});

does this not work?
0
 

Author Closing Comment

by:daniel_spiri
ID: 36566408
Simple and working, great! thank you
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Generate Numbers in JQuery file 11 66
Multiflying 2 Input Text On a Table 7 31
Copying table data to one another 15 31
JavaScript Loan Calculator Error 3 17
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question