Possible To Obtain Script URL?
Dec 3, 2009Here's the scenario, website A wishes to include a JS file from website B. Is there anyway the script hosted on website B, can know its own url?
View 4 RepliesHere's the scenario, website A wishes to include a JS file from website B. Is there anyway the script hosted on website B, can know its own url?
View 4 RepliesI want to submit a form but it requires a code that is generated by every session (not the php session type). What i'm looking for is for a piece of code that fetch the session code and set it as a variable that can be called in JS.
I know that exists in PHP the cURL that it's able to retrieve the code and set it but i don't know how to start...
I have spent the better part of a day trying to figure this out, but cannot get it to work. What I am trying to do it reverse the background color of a cell with the font color and vise-versa. However for some reason I cannot get JavaScript to obtain the current assigned value of a CSS style. Code:
View 3 Replies View RelatedI am working on a firefox extension. The job is to sit in the status bar and as I type into any form on any webpage, listen for keyboard events, then modify the key pressed by mapping it to some foreign unicode character and then sending it to the form in focus.
As I see it, there are two ways I can achieve it.
1) Capture the event, modify it and then send it and not be concerned with the form in focus.
2) Capture the event, prevent default action., find a unicode mapping for the key pressed, find the form in focus and based on the type of form, call a method to explicitly insert the mapped character at the cursor position.
Right now I am not able to find a way to do either. Once I get the focused element, I can do something to it. But I am not yet able to get that. I even tried document.activeElement, but it doesnt seem to work in firefox.
I know this is possible to get data from a specific cell in a table on your site :
But is there any way to replace 'document' whit an external url so you can obtain data from a specific cell in a table on another webpage. Maybe like this (I know this isn't even close to be able to work...):
I'm actually not sure if this is even possible whit javascript. If not, do you know any php script whish does that job?
Is it possible to get the Server IP Address from Javascript
ie., when the user types "http://10.0.0.10/main.htm" in the web
browser, i need to retrive the value of the IP Address(10.0.0.10) from
my client side javascript.
I have a textfield and you of course you can select text...
When they hit the bold button I want it to obtain the selected text and
bold it, the hard part is trying to figure out if javascript can even
OBTAIN selected text?!?!
I can do this in java if I have to, I know java better than javascript,
it seems as that is the only way to do it from looking online.
I;m looking for a way to obtain key names from a JSON object:
eg
"options": [
{"Option1" : ["Value1", "Value2"]},
{"Option2" : ["Value3", "Value4"]},
{"Option3" : ["Value5", "Value6"]}
[Code].....
Prototype seems to have a keys method which would achieve what i'm looking for. There are also a few pages which attempt to address the issue with JQuery, such as: [URL] However i was only able to retrieve the numerical index of the array elements using these methods (vs their name).
How can to obtain length of string variable, for example if I have:
var msg = 'hello world!';
Does it exist a method to count string characters?
How can I obtain content of cascade style, using javascript? I know, there's a code
document.getElementById('id').style.border='5px solid blue';
For example, but I need to do reversed operation, not to change style, but obtain it.
I want obtain the path of an outlook message for save it into database.
View 1 Replies View RelatedIs there a way to obtain the DIV you are currently hovering over using Jscript?
Basically I have ten thumbnails that I'd like to change the borderColor for using onmouseover. Instead of having to specifically create a DIV for each thumbnail (#tmb1, #tmb2, etc.) and then having to attach a separate function to each one (document.getElementById("tmb1").style.borderColor = "#660000") I'd like to be able to detect the DIV the mouse is currently over and change the borderColor of that.
I have over thirty pages, each with 10-15 thumbnails, which is why I'm trying to come up with something more generic.
I need to chop up a string to obtain just the filename of an image. Lets say the image source is /images/thumbs/image.jpg. Using the DOM I have the source of the image in a variable called 'source'.
What I want to do is manipulate it so that it just returns the file name image.jpg. How can I achieve this? I tried split() to see if I could split it into an array using the / as a separator, but this didn't work.
I want the client to be able to obtain the http headers for a website I have. Mainly the WWW-Authenticate information (http digest). None of the scripts online have this. Someone said that on the server side I'd have to generate the code for the client, but how would I go about doing this?
View 1 Replies View RelatedIs there a way of doing this with java script?I have a homepage, that has to go to a certain directory, find the newer TXT file, get the first paragraph, get it formated with H1 tag, then read the rest format it with a P tag.So everytime a new TXT file is created in that directory the homepage (HTML/index.html) change.
View 1 Replies View RelatedIs there a way of doing this with javascript?
I have a homepage, that has to go to a certain directory, find the newer TXT file, get the first paragraph, get it formated with H1 tag, then read the rest format it with a P tag.
So everytime a new TXT file is created in that directory the homepage (HTML/index.html) change.
i have a dropdown. i want to check the value in 'i'th position. how can i find that? $("DropDownList1_ID").val() is not giving any value. its alerting [object object] .
[Code]...
I am using Ben Alman's JQuery resize plugin in order to obtain the varying computed width of an element when the window is resized (the element in question is a page wrapper that exhibits the expand-to-fit behavior of a block box, and it's computed width is obviously influenced by the resizing of the window. Essentially, what I need to be able to do, is to reference a variable that is defined in a .resize() function ('width_page') in a seperate .each() function.
[Code]...
I now understand that variables can't cross boundaries like in the example above, which leaves me a little stuck. I also understand that this is specific to the context of the .resize() function, and that it can't be taken out of it without using an element selector. Is there some way I can call the .resize() function in my .each() function?
I am trying to use Jquery to create an "add" button, upon which you click and then you obtain a new tab on your page. But it's hard for me to understand how to do that because the language seems complicated. I found this :
[Code]..
My understanding had been that $.css("width") would return the original user selected style, eg "100%" or "10em", and $.width() returned the computed width, always in "px". Not so, following the code through for .css(), it calls something called getComputedStyle and the only difference between the two functions turns out to be a post-fix of "px" on the .css() result - not very useful. I need to know whether my user has called me with a proportional dimension, or a fixed one. How to tell with jQuery?
View 1 Replies View RelatedI need to get the value of the cells in the xml file. I have managed to obtain the row id below.
xml file: