I have a menu like this:
<ul id="menu" class="undecorated">
<li id="menuHome"><a href="/">Home</a> </li>
<li id="menuAbout"><a href="/Usergroup/About">About</a> </li>
<li id="menuArchives"><a href="/Usergroup/Archives">Archives</a> </li>
<li id="menuLinks"><a href="/Usergroup/Links">Links</a> </li...
hi guys, currently i am in browser game project, quite similar to mafia wars or restaurant city(in facebook)
we are using php jquery and CI to build this game
my question is how to make secure dynamic update via ajax(e.g in mafia wars, it is stamina that if you spent some, the game will show you "more in 04:00" and if you wait 4 minut...
I have to create a data table simmiliar to the http://www.chartle.net/ have.
The most importang feature is :
Row can be added/remove dynamically (done)
Column can be added/remove dynamically (how can i do this ?)
The changed colModel can be saved in database for feature modification ..
Is this possible ?
...
Markup:
<tr>
<td colspan="3" rowspan="4">1</td>
<td>2</td>
<td>3</td>
</tr>
jQuery:
$("table tr td:first").addClass("first-col-cell");
$("table tr td:last-child").addClass("last-col-cell");
...according to jQuery documentation :first selector should only select the first td (1) but it also selects other 2.
Thanks
...
Is there any better way to rewrite this:
$('element').removeClass('class1').removeClass('class2');
Can't use removeClass(); as it would remove ALL classes, which I don't want.
Thanks
...
Is it possible to get event data from an HTML drop down list (i.e. the list that drops down, when you click on a drop down list) using jQuery / plain jscript? I am looking to capture:
the number of times a user hovers over <option> before selecting the item they require.
the duration of the hover before making a selection.
At present...
I'm trying to figure out how to store external variable values in the functions created during jQuery's click() event. Here's a sample of the code I'm working with now.
for(var i=0; i<3; i++){
$('#tmpid'+i).click(function(){
var gid = i;
alert(gid);
});
}
<div id="tmpid0">1al</div>
<div id="tmpid1">asd</div>
<div id="tmpid2">qwe<...
Could anyone please tell me how to find if a variable is undefined. I currently have:
var page_name = $("#pageToEdit :selected").text();
var table_name = $("#pageToEdit :selected").val();
var optionResult = $("#pageToEditOptions :selected").val();
var string = "?z=z";
if ( page_name != 'undefined' ) { string += "&page_name=" + page_nam...
Is there simple JavaScript or jQuery script to navigate around form fields, similar to what phpMyAdmin does with dynamic fields. When you click CTRL+LEFT or CTRL+DOWN it "tabs" to the next field.
This is extending from the default TAB (go to next) and SHIFT+TAB (go to previous). I want the navigation to be a bit more extensive by adding...
Hi i have the following:
if( $(this).val() == "Next Step »" )
and HTML:
<input type="submit" name="pageToEditButton" id="pageToEditButton" class="submitButton" rel="getChosenPage" value="Next Step »" />
this does not return TRUE anyone know how to fix?
regards
...
im using jquery tools.
im trying to put tooltips on the inputs of the form which is in the a tab.
this is my script:
<script>
// perform JavaScript after the document is scriptable.
$(function() {
// initialize tooltips
$("#UserContactPerson").tooltip({
// place tooltip on the right edge
position: "center right",
// ...
I want to add the class 'second-col' to all second TD's in each row, but this isn't working:
$('table.tst3 tbody td:eq(1)').addClass('second-col');
Thanks!
...
gridview has 20 pages. The user is see first gridview page . He decide to apply highlite style using jquery on few row . Now he move to second page . He apply style this page too. Now when he go back to first page, he cannot see row with style he apply before he move to page 2.
How to store state of the rows style when user moving on pa...
Hi,
I have this simple html markup generated from classic asp:
<table>
<tr class="trClass">
<td>Hello </td>
</tr>
<tr class ="trClass">
<td>World!</td>
</tr>
</table>
If i set the tr belonging to Hello to hide() using Jquery it hides. Good!
But, when i use this $('.trClass:visible').each(function() { alert('visible'...
Hi friends,
here is my code about jquery post. I can't make it work somehow. I spent hours :( what I miss here?! when I run the code, It loads same page :(
I want it to run the php code under
query.php and hide the contact form
and give "thanks!" message at send
submit button click. (with no page
loading)
appreciate helps...
Hi,
I am having an issue with a jquery function. It works in FF but not in IE 6. I want the function to be triggered when any option inside a select drop down is clicked. Here is the start of my funcation:
$('#titleSelect option').click( function() {
alert("title clicked");
......
});
Here is my drop down list:
<selec...
Hi, i have the following (which obviously i cant do!)
function dropBox() {
$("#reportWrapper a").bind("click", function(){
$("#reportWrapper a").each(function(i){
$(this).animate({
height: '20px'
}, 1000);
});
$(this).parents("div:eq(0)").animate({
height: '100px'
}, 1000);
});
}
What i want is to open...
Hi,
I'm using the jQuery TOOLS - The missing UI library.
For tooltip on all input fields I do
$("#univers :input").tooltip({
effect: 'slide',
position: "center right",
offset: [-2, 10],
effect: "fade",
opacity: 0.5,
tip: '.tooltip'
});
But I would like to show tooltip only if input field is empty. So I did
...
I'm looking to expand on a recent script i've coded using jquery.
I have this following code
<script type='text/javascript'>
added_departments = new Array();
$("#departments_submit").click(function(){
var depo = $("#depo_list").val();
if(jQuery.inArray(depo, added_departments) != -1)
{
return false;
}
else
...
Hi friends,
I have 2 different scripts, one is jquery post for form, and second is jquery form validation.
I run post script at submit button click action, so it takes effect before validation :/ and i could not change validation to run before post script :( so now it form submitting without validating.
How can make it? Appreciate hel...