?
Solved

JavaScript not working in Chrome, works in FF

Posted on 2011-10-11
3
Medium Priority
?
195 Views
Last Modified: 2012-05-12
hi there,
i have a table and there is an element in each row that deletes from the database that row of the table.

<td><a href=""  onclick="javascript: if(confirmAction('Are you sure you wish to bin this lead?')) window.location.href = 'addtobin.php?id=3';">Bin Lead</a></td>

Open in new window


this is the code from that cell of the table, it redirects in firefox, but not in chrome.

how can i fix this please?
0
Comment
Question by:alexanderfoti
  • 2
3 Comments
 
LVL 15

Accepted Solution

by:
Eyal earned 2000 total points
ID: 36947622
<td><a href="#"  onclick="if(confirmAction('Are you sure you wish to bin this lead?')) window.location.href = 'addtobin.php?id=3';">Bin Lead</a></td>
0
 
LVL 13

Expert Comment

by:ansudhindra
ID: 36947650
try this..
 
<td><a href="#"  onclick="javascript: if(confirmAction('Are you sure you wish to bin this lead?')) { window.location.href = 'addtobin.php?id=3'; }">Bin Lead</a></td>

Open in new window

0
 
LVL 13

Expert Comment

by:ansudhindra
ID: 36947652
oh! sorry, I am bit late..
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

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

CTAs encourage people to do something specific to show interest in your company, product or service. Keep reading to learn why CTAs should always be thought of as extremely important, albeit small, sections of websites.
Measuring Server's processing rate with a simple powershell command. The differences in processing rate also was recorded in different use-cases, when a server in free and busy states.
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…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses

621 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