I have a advertisement website with alot of records stored in a mysql db.
On my main page, I have a form where users may specify their search criteria.
Action is set to myPhp.php file.
myPhp.php contains NO HTML, only php code, and it is basically something like this:
1- get values from FORM and build a SQL query
2- query MYSQL db.
3...
I have some elements inside an iframe with an onclick event associated, something like:
<iframe>
...
<input type="text" onclick="somefunction(this)"/>
...
</iframe>
In the function called I try to change the value of the input, nothing special:
{
...
foo.value = "changed!"
...
}
At this point I can see in firebug that the va...
How can i acces an select element if it has been selected?
var select = document.getElementById("select");
if(select.selected == true)
doesnt work any idea?
...
Hi there,
I have a question about the accordion plugin for jQuery.
Basically, I've got it to work on my site nicely, there's just one thing that I'd have liked it to do and that is bottom-up opening in stead of top-down.
What I mean by that is that my 3 buttons just stand in the vertical menu (div) in the bottom. And when you click it, ...
Hello all.
I have two textboxes tbxProdAc & txtbxHowMany. I would like to write a bit of code in the code behind so that when I enter text in one, any text that may have been in the other is removed.
How would one go about achieving this and in which event should I place it?
I have tried to use
txtbxHowMany.Attributes.Add("onclick"...
I'm currently trying hard to get my jQuery to work in IE7, when I Lint the following:
$(".regflow").validate({
errorLabelContainer: $("#error-message"),
rules: {
txtTextOnly: {required: true,textOnly: true},
txtNumbersOnly: {required: true,numbersOnly: true},
txtPhoneOnly: {required: true,phoneOnly: true}...
Is this supported at all or do I need to build a custom control?
End goal is an XML file of javascript ads that the adrotator picks from.
<script type="text/javascript"><!--
google_ad_client = "pub-xxxxxxxxxxxxxxxxxxx";
google_ad_slot = "xxxxxxxxxx";
...
How do I reset an ASP.NET dropdown, on the click of a link, using Javascript? No JS Frameworks.
Edit: reset, as in set the selected value to the first one in the list, as it would be when the page first loads.
...
Dear All,
Is there a way to change the color of a button, or at least the color of the button label programmatically?
I can change the label itself with
document.getElementById("button").object.textElement.innerText = "newlabel";
But how to change the color?
Thanks,
Zsolt
...
My Application has a lot of calculation being done in JavaScript according to how and when the user acts on the application. The project prints out valuable information (through console calls) as to how this calculation is going on, and so we can easily spot any NaNs creeping in.
We are planning to integrate Selenium (RC with python) to...
I've written some scripts in Javascript under Rhino 1.7, one of them starts a minimal http server and accepts JS commands in input.
Now, if I call (from within Rhino):
engine = ScriptEngineManager().getEngineByName("JavaScript");
I get the builtin JS engine (from Java 1.6), that is an older version of Rhino, and lacks some functions ...
Just some short Q regarding javascript and websites.
1- By javascript enabled, does it mean to have 'sun java' installed and enabled in the browser settings? Or does every browser have javascript enabled always?
2- If javascript is disabled, my website for example wouldn't work at all, so what does major developers do in these situatio...
I am creating a customize combobox and want to use the default pulldown button used on <select> element. The combobox is composed of a textbox, a pulldown button and somewhat a table element containing the list. Everything is working except for displaying dropdown button.
Note that I want to refrain from using any background image for t...
the regexp
\<div class=g\>.*?\<a href=\"?(http:\/\/stackoverflow.com\/)\"?.*?\>.*?\<a href=\"?(.+?)\"?.*?\>.*?\<\/div\>
the target
<div class=g>
<link rel=prefetch href="http://stackoverflow.com/">
<h2 class=r>
<a href="http://stackoverflow.com/" class=l onmousedown="return rwt(this,'','','dres','1','AFQjCNERidL9Hb6OvGW93_Y...
Hi,
is there anyway for the title in option tag to be displayed always?
<select>
<option title="sometitle" value="">1</option>
</select>
any ideas please?
Thanks
...
Hi..am just getting used to regex..but am unsure of how to use javascript variables within the regular expressions..
For example...as it stands..my code reads..
if (window.location.hostname == 'localhost') {
var $sURLDomain = 'http://localhost/';
}
else {
var $sURLDomain = 'http://mysite.com';
}
$('#content a[href^=$sURLDom...
I started with 5 normal human-readable JavaScript files - they were around 10 KB in total.
After using YSlow, I decided to merge the 5 files and pack them using Dean Edwards' packer. Now I have 1 file that is 4.5 KB.
When I re-run YSlow, it is now showing the JavaScript file in the primed cache under 'statistics', where previously (whe...
I have some dynamic text contained in a div that is set to whatever a user enters in a textbox field. If the text doesn't fit in the div, right now it just gets cut off at the edge and all the text that extends past the border is not visible. I would like to truncate the text so that it fits inside the box and has an ellipsis (...) appen...
So, I've got this big project written in PHP and Javascript. The problem is that it's become so big and unmaintainable that changing some little portion of the code will upset and probably break a whole lot of other portions.
And I know for a fact that I'm really bad at testing my own code (as a matter of fact, others point this out dai...
Have no idea how to make it :( I think javascript should be used, any suggestions?
...