JQuery :: Open Link In New Tab With .click?
Jan 12, 2011
I have the following:
$(".buy_icon").click(function () {
window.location = "http://www.theuntappedsource.com/results.php?category=422"
});
Which opens the url in the current window when the icon is clicked.How would I open the url in a new tab?I should mention that I can't simply use an anchor tag.
View 2 Replies
ADVERTISEMENT
Oct 23, 2011
I have a member search component that I've built that uses AJAX to update results on search filter change.Each result has a link with it to add that member as a friend, when you click the link it fires a modal window (colorbox) with the member data and add and cancel buttons.
Everything seems to work ok, except you have to click the link twice for the modal to fire. Is there something I can do to prevent having to click this twice to load?
View 10 Replies
View Related
Feb 17, 2009
I want to make one link and If I click twice him (how to open in desktop my computer or my documents) do something and if i click him once do other something
View 2 Replies
View Related
Jun 9, 2009
I have 3 links that are clickable... And what I want to do, is when 1 anchor tag is open and the user clicks on a different link, it closes the previous link and opens the clicked one. Here's a link to the working page to see my example: Example Site on Temp server The green buttons on the right hand image are the clickable links and these are the ones I want to add the final animation to. Click on one link, then click on another.
[Code]...
View 4 Replies
View Related
Aug 24, 2009
How to Make a Html Form Shows Up when Visitor Click a Link.. I have seen Site where you want to add Message u click Link then the Form under the Link Shows Up .. it stays Hidden unless Visitor Click Link 'Send Message'. It seems done by Java but How ..
View 10 Replies
View Related
Sep 24, 2007
Basically I want some of the links in my page to open in new tabs (I'm
using Firefox) or windows if the user has their options configured
that way. And I want my page to remain intact as it involves some AJAX
and takes a while to load.
But ...and this seems to be a big "but"... I don't want the focus to
move away from the page I'm on. So techniques such as <a
target="_blank"or <a onclick="window.open(...)"aren't working for
this requirement. I even tried using a separate function and
attempting to return to the original window straight after using the
following function: Code:
View 7 Replies
View Related
Jul 13, 2009
I cant really figure this out, the only thing i could see messing it up is the javascript:void(0) inside the anchor link but since there is a double click function and a click, it should only be one click.I put autoOpen which i think is also causing it, but i did that so theuser can open it, close it, and open it again so the delay "double click" is saying for the first time initialize and then the second click is opening?? if so how do i get around this?
HERE IS MY JQUERY
$(document).ready(function(){
$("#pro_edit_profile").hide();[code]....
HERE IS MY HTML FOR THE LINK
<a href="javascript:void(0);" id="pro_edit_pic_link" name="Change
Profile Picture">Change Profile Picture</a>
View 1 Replies
View Related
Oct 17, 2010
Clicking on the menu buttons, a box with some info opens, ad under that, a div that makes the body of the site black. the problem is when i click a different button, to open a different box, the "div#black" should stay open and not toggle. i tried this
var black = $("div#black").toggle() ;
if (black == false { $("div#black).fadeIn("slow"); };
and this was the javascript for the button (with the toggle function, when i didn't use the if/else):
[Code]....
I don't know which is the correct way to write the if statement, i used easier ones but this one is to complex for me :D i think the main problem is the "var"
View 4 Replies
View Related
Nov 16, 2009
I'm using an <A> tag with an onclick event to open a window with JS (window.open)... In FIREFOX, if I click very quickly, multiple windows open. Not a problem in IE.
View 8 Replies
View Related
May 31, 2010
How can I give a click on a link when it is just created and added to DOM?
None of this works:
function openProfilePage(profile){
$('#profile-link').remove();
var link = $('<a/>').attr({'href':'profile.php?user='+profile, 'target':'_blank', 'id':'profile-link'}).css({'top':'-200px','left':'-300px', 'position':'absolute'}).html(profile);
[Code]...
View 7 Replies
View Related
Aug 5, 2010
I have used jquery modal window JS for creating Modal box. By clicking respective link modal Box opens in all the browser. But in Ie6 that behaves differently. In My webpage I have some Form controls, like( Input field, checkbox, Dropdownlist etc.) When I click the mentioned hyperlink the modal box opens in ie6 correctly but the Form controls operlaps the Modal box. Please check the attached screen. How to fix such issue for IE6.
View 1 Replies
View Related
Dec 16, 2010
i have made a small accordion on a sub page on my site, when you come to the site all areas are closed (as the shud bee.on my frontpage i have some links to the accordion, that when clickd takes you to the page with the accordion and shud oppen the coresponding accordion area. I can get it to work for all the links except for the one to the first accordion area.
i link to the accordion page like this<a href="news.html#0" title="News 1">
<a href="news.html#1" title="News 2">
<a href="news.html#2" title="News 3">
link 2 and 3 opens the accordion as the shud but link it wont open the accordion the script for the accordion looks like this
$('#scrollbar1').tinyscrollbar({ sizethumb: 10 });
var newsNum = parseInt(window.location.hash.slice(1));
$("#newsfolders").accordion({ autoHeight: false, collapsible: true}).accordion('activate', newsNum );
How do i get the first link to open the accordions first area?
View 1 Replies
View Related
Nov 2, 2011
I am using Jquery Tools Tabs andI want to be able to link from an external page to an open state on tab 2.(External Link to tab 2 --> tab 2 open)Here is my html:
<ul class="tabs">
<li><a href="#tab1" id="tab1">tab1</a></li>
<li><a href="#tab2" id="tab2">tab2</a></li>
[code].....
View 4 Replies
View Related
Aug 29, 2011
i know it sounds like a simple thing to do, but for the life of me
View 12 Replies
View Related
Jan 27, 2011
How to open a specific tab via an external link?
View 3 Replies
View Related
Dec 14, 2010
Im trying to get a link one one page to activate/open a specifik accordian but i cant get i to work
my accordion looks like this
<div id="newsfolders">
<h1><a href="#">NEWS 1</a><span class="newsdate">21/10/1969</span></h1>
<div>
<p>Curabitur massa mauris, feugiat ut consectetur eu ullamcorper eget quam.</p>
[Code].....
View 2 Replies
View Related
Dec 12, 2011
I made a table and I would like that once you press a table row that it will pop open. I know this is pretty easy but I am missing something. Right now it will open up all divs named test. I want the individual div .test to toggle open which belongs to the right table row.
HTML:
<tr>
<td>7.8</td>
[code]....
View 1 Replies
View Related
Jan 24, 2011
I want to call the click event of the link (anchor tag) on the click of the button. I used this code below in the click event of button to call links click event and it works fine in IE.
document.getElementById('linktag').click();
But, this doesn't work in Firefox. I googled a bit and found that in firefox, you have to do something more to achieve this behaviour. So, I ended up doing this on button click to work in firefox:
var link=document.getElementById('linktag');
var e = document.createEvent('MouseEvents');
e.initEvent(
[code]....
The above code does the click on link when I click on the button. But my problem now is that I have defined a link as
<a href="mailto:abc@xyz.com?subject=abc&body=email body">email </a>
and when click is called and mailto links opens my email client, it somehow ignores the subject and body parameters of the link. It works properly when i actually click a link element. but it doesn't work when i simulate the click event by code written above. above dispatching event code somehow ignores the link parameters?
View 3 Replies
View Related
Jun 4, 2007
Below is an example of a synthetic click in Firefox. The browser does
not follow the link. Is that the just the way synthetic clicks work of
am I doing something wrong? I know the synthetic click occurs because
if I add an onclick attribute to the link the handler runs. Any ideas? Code:
View 2 Replies
View Related
Jun 30, 2009
I was guessing if it was possible, using jQuery, to have a link that, when clicked, opens the relative url and sends to it a post request. I'm trying to do this with the $.post function, but i found the problem that the request is sent, but the page isn't opened.
This is my code:
<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
[Code]....
View 1 Replies
View Related
Jul 20, 2011
I have an image that has been resized via CSS to show as 100x100px on an HTML page. When clicked, I want to open the image in a colorbox - so the user can see the non resized/squashed version as it will normally appear. I've worked out how to set the path of the href to itself (so this doesn't have to be changed every time) (see below), although not sure how to get the colorbox part working - I tried changing 'each' to 'colorbox' - as per how you would normally assign the colorbox, and it opens, it just doesn't load the image in it.
<div class="logoImage"><img src="../tym_img_shared/background-2.jpg" alt="Your company logo" /></div>
$(document).ready(function(){
$('div.logoImage img').each(function(){
var $this = $(this);
$this.wrap('<a href="' + $this.attr('src') + '"></a>');
});
});
Thinking about it, perhaps it would be easier to also set the 're' attribute of the link whist setting the source?
$(document).ready(function(){
$('div.logoImage img').each(function(){
var $this = $(this);
$this.wrap('<a rel="gallery" href="' + $this.attr('src') + '"></a>');
});
});
Doesn't work for some reason - but it does if I hardcode the URL and rel?
View 6 Replies
View Related
Nov 17, 2010
Having a bit of trouble with this. I'm not a JQuery novice, but can't seem to understand why the Triggerhandler isn't working for this particular PHP site I'm working on. I've used the same type of code in a Drupal site successfully.
I can't seem to find a plugin that can help with either.
View 2 Replies
View Related
Feb 17, 2011
i have a website where i have on the left side a button menu and on the right side an accordion menu. how can i get it to work, that when a user clicks on a button in the left menu, the associated entry in the accordion menu will open?
View 1 Replies
View Related
Apr 27, 2010
I have the following code, however, I need to click twice on Change password for the dialog to open. I want the dialog to open when on a single click. I can`t understand why the dialog doesn`t open on a single click.
<td><a href="#" id="password_link" onclick="$(ChangeAttribute('<%= item.Name %>', '<%=item.ID %>'));">Change Password</a> </td>
function ChangeAttribute(name, Id) {
$(
[Code]....
View 3 Replies
View Related
Jan 13, 2011
I have the following code:
Code:
$(".buy_icon").click(function () {
window.location = "[URL]"
});
Which loads the URL in the current browser window when the div (buy_icon) is clicked. How can I load the URL in a new tab or window?
View 2 Replies
View Related
Apr 23, 2009
I'm trying to open a div that holds several images when the user clicks on a link. Each clicked link will open the div and display a specific pic. Plus each time a link is clicked the div should close before opening the div with the appropriate pic. Since I'm new to jquery I'm a bit lost on this one.
[Code]...
View 1 Replies
View Related