I would like to select a text, in my HTML page. Is that possible? About the page [URL], it seems to be not allowed by jQuery... For exemple if my document is:
<html>
Hello word!
</html>
I would like to select each "l" letter and replace by L [URL]. But I don't know how to select just a text.
I have some auto-generated code in a similar format to this:
<li class="item"> <a class="link1" href="#">Post Title</a> Text I want to remove <div class="content">
[Code].....
I want to select the line of text ("Text I want to remove" - with no HTML tags around it) and hide it using CSS (or remove it all together, if I can). I have tried using insertAfter to put a start <span> tag at the start of the line, and insertBefore to close the </span> tag at the end of the line (so I can apply CSS display:none; to it), but clearly JQuery doesn't work like that.
Is there another way to get rid of this line of text?
I'm trying to select a line a text and format it, only problem is there are no tags around it other than a closing </p> tag and a <br /> tag after it. Please see below the line in bold text which I'm trying to surround with <h3></h3> tags. [code]...
I've seen a variety of implementations around that enable selecting all or no checkboxes by using a checkbox to toggle that choice. However, I'm trying to find a way like this: I have two text links on my page: Select All, and Select None. How can I get those links to call a jquery function to select all or select no checkboxes in my form? As a little food for thought:
<head> $(function() { //function for selecting all or none...is there a way to make a single function that passes in a parameter to differentiate between selecting all or selecting none, or do I need a separate function for both?[code]....
suppose i have a html page with text, links and what ever else a page contains. On selection of Text on the html page i want to raise some event that will do something. But what that event is known as? By text selection i mean placing mouse pointer to some text and left clicking and moving the mouse either to left or right. Now when user selects some portion of text and releases the mouse's left click button a event should be raised. Obviously that event should know what was the selected text. So is it possible ?
If I open a new page with very little text on it such as a bugmenot results page is there a way to select some of the text there and assign it to variables?
Selecting all and copying to the clipboard can be done with:
I've got a requirment to copy some content from an HTML page. It is a failry lengthy page and we want to give the user/reader the ability to click a button and have a section of the page copied to the clipboard, or at the very least selected so they can just right click and copy it. The issue is that text/content to be selected/copied is not in a textarea.
I've got it in a div right now and can get the innerHTML of the div and set a text area to that but it comes in with all of the HTML tags and so when I copy it to notepad I get all of the tags which is what I dont want.
Has anyone done this before? I've tried numerous things to get it to work and have had no luck.
First, with AJAX I will get a remote web page into a string. Thus, a string will contain HTML tags and such. I will need to extract text from one <span> for which I know the ID the inner text.
Is it possible to access in this way "string variable".getElementByID() somehow?
PS: Just thinking of a proper/efficient way to extract the information from such a string. I am open to other ideas. I could load that page in IFRAME and get my access to DOM that way, yet probably it is not an eligant solution.
I want to create a body on html page , i want to add all the functionalities , like change of font size and color when i create the document. and when i read the document in view mode it will show the field in the entered format.
I wanted to know how can I check for a specific HTML tag or user defined TEXT and delete it when the page loads
Whenver the IE loads the page my company add its COMPANY NAME in my office on any page so what I want to do is to check for my company name b4 the page loads and remove the company name and then load the page.
what i'm trying to do without sucess , can't find anything on google.. Is trying to arrange a button to do a "CTRL+T" (Select all) effect in the HTML i'm currently viewing. Is this possible in Javascript?
I dont want to select the text in a textbox ! I want it in the whole .html i'm currently viewing.
I have this normal HTML page, starts with <!DOCTYPE ...... and end with </html>, nothing special, what I need is to get every character from the beginning to the end.I've tried $("html").html(), but this cannot get the <!DOCTYPE line and also the <html> line, but only the codes inside the <html> tag, how can I get all ?
i am trying to pass text from one select box to another select box. The logic is if 10 are added, no more passing must happen. Also if an item is already added, it mustn't be added again.I am using the for loop to check the existence of an item but it is not working: what am i doing wrong?
Code: function PassSelectValues(){ //pass values from select boxes to select boxes var counter;[code]....
why isn't counter incrementing at all? The alert message box does appear saying item exists but the item gets added anyway.
I'm trying to get a select box to display text from a database in a div tag from the select box populated by a while loop that also pulls from the database. The only way I can do this is from a javascript written by sending it over to a second page and I need it on just one page. Here is my code below:
I have a problem with html select. i will be selecting an element from the select drop down, then i will click a button which will result in changing the position of this element with the element just above it. Is it possible, I am getting the element id, I thought of using replaceWith method, but its giving some error. "uncaught exception: Syntax error, unrecognized expression: # ". I also wanted to know if this thing is possible in jquery or not..
I am working on a page that will load in other pages using AJAX and the .html method. Something like this :
<span id = "edit">Edit</span> <div id = "cont"> </div> //the click edit script
[Code]....
Unfortunately this does not seem to work, entirely. It does trigger the click event but it messes up the post for some reason. I have played around with it for the last 45 minutes or so and it seems like the click event trigger is what is messing things up, if I comment it out it works fine. Could anyone tell me why they think this is? note this is an over simplified version of my actual code, but the structure is the same.
I am trying to add select items via jquery to a select control. The following code works perfectly in IE, Opera. Chrome and Safari, but for the life of me I cant get it working in firefox. I really don't think its a bug but I must be missing something obvious.