How to detect ctrl+v ,Ctrl+c using Javascript?
i need to restrict pasting in my textareas,end user should not copy and paste the content,
user should only type text in text area.
how to achive this.
Thanks in advance.
...
Is it possible to extract the ratings (i.e. 5 stars), views and comments of a Youtube video and use it within your own site?
In other words I have a youtube video embeded on my site but i want to include the rating, views and comments of the video. Then use that information to display below video on my own website?
Hope that makes sen...
I have a text box called txtName on my form.
In my page I know I need to place the code in my HEAD tag like so......
<script type='text/javascript' language="javascript">
document.FormName.txtName.value = "Robert";
</script>
But I cant seem to set a value to my textbox txtName with the above code......
...
I having a website developed in .net and need to get a HTML to PDF converter.
Are there any open source or alternatives to http://www.html-to-pdf.net as it is quiet expensive.
...
I am trying to pass the parameter called value in the hidden input type to my servlet.
It is like that:
retour.append("<input type=\"hidden\" id=\"id_" + nomTab + "_" + compteur + "\" value=\"" + object.getIdDailyTimeSheet() + "\"/>");
retour.append("<button id=edit name=edit type=submit onClick= editarow()>");
retour.append("<img src=...
The following html snippet
<div dir="rtl">
test (test)
</div>
shows
(test (test
in all browsers.
Why?
...
I'm using latex commands in my html code. When I validate the at w3c validator, it is giving me inavlid markup message.
Line 105, Column 31: non SGML character number 12
\begin{equation}(x^{2})^{4+(frac{1}{5})}\end{equation}
Is there a way to pass validation? Can I ignore this error?
...
Im trying to implement the search feature in my website.
when the search keyword is entered in the textbox, and the category combo is selected, the form will be Posted and the result will be shown on the same page.
what i want is to keep the selected category of the combo by default in the form after posted
For eg., If i select the c...
What is the practice to pass arguments from HTML to jQuery events function.
For example getting id of row from db:
<tr class="jq_killMe" id="thisItemId-id">
...
</tr>
and jQuery:
$(".jq_killMe").click(function () {
var tmp = $(this).attr('id).split("-");
var id = tmp[0]
// ...
}
What's the best practise, if I want ...
I know how to write/create cookies in JavaScript.........................................................
//Create the cookies
document.cookie = "Name=" + Name + ";expires=Friday, 31-Dec-2011 12:00:00 GMT; path=/";
document.cookie = "Surname=" + Surname + ";expires=Friday, 31-Dec-2011 12:00:00 GMT; path=/";
document.cookie = "Number=" +...
I have a Table containing some information that I need. All these rows also contains a column with a radio button in it so that the user is suppose to be able to check one of the rows as default.
When I'm bringing the data back from the DB and want to select the one that's currentlly the default one.
<% foreach (var item in (IEnumerab...
this is the code i m using to play songs
<a href="http://southgreenvillecoc1.org/BeEncouragedByWhatYouKnow4-25-2010am.wma"
style=" text-decoration:none; color:#404040;" target="_blank">
“Be Encouraged by What You Know”</a>
what do i need to do to play the song??? the link gets redirected to a different server....anything...
in a html table i construct in each row an edit button like the following:
retour.append("<input type=\"hidden\" id=\"id_"+nomTab+"_"+compteur+"\" value=\""+object.getIdDailyTimeSheet()+"\" name=\"hd_"+compteur+"\" />");
this is the hidden type then i do the following:
retour.append("<button id=edit name=edit type=button onClick...
I'm building a password box that holds three text areas.
Each text area has one character.
After I type the first character of the password, I have to press tab or use the mouse to get to the second text area to type the second character of the password.
I would like to make this happen automatically (cursor movement) just right after I ...
Hi!
I've been reading about XSS and I made a simple form with a text and submit input, but when I execute <script>alert();</script> on it, nothing happens, the server gets that string and that's all.
What do I have to do for make it vulnerable?? (then I'll learn what I shouldn't do hehe)
Cheers.
...
I'm trying to add anchors to all h2's in my html, using python. This code will add those anchors, but I need to fill the name of the anchors too.
Any idea if the name can be the number of the match in the loop or a slugified version of the text between the h2 tags?
Here's the code so far:
regex = '(?P<name><h2>.*?</h2>)'
text = re.su...
Try out this code in Chrome, Firefox and IE:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Textarea problem</title>
<style type="text/css">
html, body {
position: absolute;
top: 0; left: 0; right: 0; bottom: 0;
border: 0; padding: 0; margin: 0;
}
#co...
If you use dynamic pages like JSP or asp.net, you can have your page template included, and then content added. But what if you have no server-side component and all pages are just HTML/JS? You can of course create a template then copy it for each page, but then if you want to change something you risk having to modify every page, even i...
Our company is making a mobile version of our website. We have several product videos we want to show on the mobile version.
When I try to use
<a href="video.wmv">video</a>
I get sound playing but a black screen on my htc incredible android os phone.
I'm thinking that the video is playing but in a different browser window. I need ...
Uncompressed, jQuery is 160KB in size. I did not see a way to exclude seldomly used parts of it like with jQuery UI. How can I reduce the (compressed and minified) file size of jQuery? I am quite concerned because dial-up lines and slow machines/browsers are very common among users of my site.
My main concern is parsing duration of the ...