[jQuery] Deserialize array

2006-10-19 Thread TJ

I have some serialized data

stories[]={'link':'http://digg.com/videos_gaming/Just_how_different_IS_Wii_Madden_%28answer%3A_very%29','title':'Just
 how different IS Wii Madden? (answer: very)','date':'19 Oct 
2006','description':'I knew Wii Madden allowed for juking, passing, etc with 
the Wii remote, but this new video is the first one that really shows how 
sports games will be revolutionized. Includes interviews/demonstrations with 
the developers  
producers.'}stories[]={'link':'http://digg.com/general_sciences/Gravity_Measurements_Confirm_Greenland_s_Glaciers_Precipitous_Meltdown','title':'Gravity
 Measurements Confirm Greenland's Glaciers Precipitous Meltdown','date':'19 Oct 
2006','description':'Of late, the enormous glaciers that flowdown to the sea 
from the interior of Greenland have been picking up speed. In the last few 
years, enough ice has come off the northern landmass to sustain the average 
flow of the Colorado River for six years or fill Lake Mead three times over or 
cover the state of Maryland in 10 feet of water.'}

I have serialized data like this. How can I loop through this and deserialize 
it putting it into forms using jQuery Form Deserialization Plugin  

http://www.reach1to1.com/sandbox/jquery/testform.html

-TJ



___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Ajax login

2006-10-08 Thread TJ

Hi I am really having trouble using ajax function to make a login form. Here is 
what I have so far.

Any ideas?

script type=text/javascript language=JavaScript
$(document).ready(function(){
$('form').submit(function(){
$.ajax({
url: process.php,
type: POST,
data: $.param( $(#login).formdata()),
success: function(msg){ alert( Logged in:  + 
msg ); } });
});
 });
  });
  /script
form 
Username:input type=text name=user maxlength=30
br/ Password:input type=password name=pass maxlength=30
input type=submit value=Login
/form


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Ajax login

2006-10-08 Thread TJ

I added the login, sorry about that
When I execute I get the vars in the address bar
http://www.tjshafer.com/baintown/main.php?user=testpass=testsublogin=1

script type=text/javascript language=JavaScript
$(document).ready(function(){
$('form').submit(function(){
$.ajax({
url: process.php,
type: POST,
data: $.param( $(#login).formdata()),
success: function(msg){ alert( Data Saved:  + 
msg ); } });
});
 });
  });
  /script
form id=login
Username:input type=text name=user maxlength=30
br/ Password:input type=password name=pass maxlength=30
input type=checkbox name=remember
!--font size=2Remember me next time nbsp;nbsp;nbsp;nbsp;--
input type=hidden name=sublogin value=1
input type=submit value=Login
!--brfont size=2[a href=forgotpass.phpForgot Password?/a]/font
brNot registered? a href=register.phpSign-Up!/a--
/form


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] ajax login

2006-10-08 Thread TJ

I have updated to this with the return false. I am still getting the same error.

Any suggestions?

Thanks!

script type=text/javascript language=JavaScript
$(document).ready(function(){
$('form').submit(function(){
element = $('[EMAIL PROTECTED]').get(0);
myusername   = element.value;
mypassword = $('[EMAIL PROTECTED]').get(0).value;
$.post('process.php', {username: myusername, name: mypassword});
element.value = '';
return false;

});
  });
  /script
form
Username:input type=text name=user maxlength=30
br/ Password:input type=password name=pass maxlength=30
input type=checkbox name=remember
!--font size=2Remember me next time nbsp;nbsp;nbsp;nbsp;--
input type=hidden name=sublogin value=1
input type=submit value=Login
!--brfont size=2[a href=forgotpass.phpForgot Password?/a]/font
brNot registered? a href=register.phpSign-Up!/a--
/form


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Drop down menu

2006-10-07 Thread TJ

Hi, I am trying to make a drop down menu. I have half of it but I need a sub 
menu off to the left. I am using this jquery code.

 $(document).ready(function(){
$(#nav-one li).hover(
function(){ $(ul, this).fadeIn(slow); }, 
function() { } 
);
if (document.all) {
$(#nav-one li).hoverClass (sfHover);
}

$(#subnav li).hover(
function(){ $(ul, this).fadeIn(slow); }, 
function() { } 
);
if (document.all) {
$(#subnav li).hoverClass (sfHover);
}
  });
  
$.fn.hoverClass = function(c) {
return this.each(function(){
$(this).hover( 
function() { $(this).addClass(c);  },
function() { $(this).removeClass(c); }
);
});
};

Here is the page it is one.
http://www.tjshafer.com/cortek/

Any ideas?
Thanks, TJ



http://www.tjshafer.com/cortek/


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] jq corner.js

2006-10-03 Thread TJ

Hi I am using the jq-corner.js written by Dave Methvin. I was wondering how I 
could add a option for color when calling the corner.

$(#content).corner(round tl 10px color);

Heres the script

//
// jq-corner.js - JQuery method for creating corner effects
//
// If this works, it was written by Dave Methvin ([EMAIL PROTECTED]).
// If its broken, please fix it and send me a working copy.
//

$.fn.corner = function(o)
{
function hex2(s) {
var s = parseInt(s).toString(16);
if ( s.length  2 ) s = 0+s;
return s;
}
function gpc(node) {
for ( ; node  node.nodeName.toLowerCase() != html; node = 
node.parentNode  ) {
var v = $.css(node,backgroundColor);
if ( v.indexOf(rgb) = 0 ) { 
rgb = v.match(/\d+/g); 
return #+ hex2(rgb[0]) + hex2(rgb[1]) + 
hex2(rgb[2]);
}
if ( v  v != transparent )
return v;
}
return #ff;
};
o = o || ;
var width = parseInt((o.match(/(\d+)px/)||[])[1]) || 10;
var fx = (o.match(/round|bevel|fold|notch/)||[round])[0];
var opts = {
TL: /top|tl/i.test(o),  TR: 
/top|tr/i.test(o),
BL: /bottom|bl/i.test(o),   BR: 
/bottom|br/i.test(o)//,
};
if ( !opts.TL  !opts.TR  !opts.BL  !opts.BR )
opts = { TL:1, TR:1, BL:1, BR:1 };
var strip = document.createElement(div);
strip.style.overflow = hidden;
strip.style.height = 1px;
strip.style.backgroundColor = transparent;
strip.style.borderStyle = solid;
return this.each(function(){
var pad = {
T: parseInt($.css(this,paddingTop))||0,
R: parseInt($.css(this,paddingRight))||0,
B: parseInt($.css(this,paddingBottom))||0,
L: parseInt($.css(this,paddingLeft))||0
};
strip.style.borderColor = gpc(this.parentNode);
if ( opts.TL || opts.TR ) {
strip.style.borderStyle = none 
+(opts.TR?solid:none)+ none +(opts.TL?solid:none);
var t=document.createElement(div);
t.style.margin = -+pad.T+px -+pad.R+px 
+(pad.T-width)+px -+pad.L+px;
t.style.backgroundColor = transparent;
for ( var i=0; i  width; i++ ) {
var w = fx==round ? 
Math.round(width*(1-Math.cos(Math.asin(i/width : i+1;
var e = strip.cloneNode(false);
e.style.borderWidth = 0 +(opts.TR?w:0)+px 0 
+(opts.TL?w:0)+px;
t.insertBefore(e, t.firstChild);
}
this.insertBefore(t, this.firstChild);
}
if ( opts.BL || opts.BR ) {
strip.style.borderStyle = none 
+(opts.BR?solid:none)+ none +(opts.BL?solid:none);
var b=document.createElement(div);
b.style.margin = (pad.B-width)+px -+pad.R+px 
-+pad.B+px -+pad.L+px;
b.style.backgroundColor = transparent;
for ( var i=0; i  width; i++ ) {
var w = fx==round ? 
Math.round(width*(1-Math.cos(Math.asin(i/width : i+1;
var e = strip.cloneNode(false);
e.style.borderWidth = 0 +(opts.BR?w:0)+px 0 
+(opts.BL?w:0)+px;
b.appendChild(e);
}
this.appendChild(b);
}
});
};


Thanks for any help


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Rollover

2006-09-29 Thread TJ

Hi, I am trying to add a image rollover. I am applying it to a div before a li.

div id=navcontainer
ul
div id=roll/divlia href=index.phpHome/A/li
div id=roll/divlia href=news.phpNews/a/li
div id=roll/divlia href=news.php?mode=editEdit News/a/li
div id=roll/divlia href=index.php?page=newsorderNews Order/a/li
div id=roll/divlia href=frontpage_articles.phpFront Page 
Articles/a/li
div id=roll/divlia href=minutes.phpMinutes  Agendas/a/li
div id=roll/divlia href=forms.phpGeneral Forms/a/li
div id=roll/divlia href=special.phpSpecial Reports/a/li
div id=roll/divlia href=resource.php?mode=addLocal 
Resources/a/li
div id=roll/divlia href=calendar.phpCalendar/a/li
div id=roll/divlia href=emaillist.phpEmail List/a/li
div id=roll/divlia href=siteoffline.phpTake Site Offline/a/li
div id=roll/divlia href=dbbackup.phpBack Up Database/a/li
/ul
/div

Here is the jquery I am trying.

script type=text/javascript

$(document).ready(function() {
$(a).hover(function(){ 
$(div#roll).addClass(over); 
},
function(){ 
$(div#roll).addClass(out); 
});
});
/script
Would this be right?

-TJ


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Jquery.com

2006-09-29 Thread TJ

What happened to the jquery.com site?


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Suckerfish

2006-09-24 Thread TJ

Hi, I am using the suckerfish plugin. How can I make it so I can have a drop 
down menu from a drop down menu.


-Menu
   |
-menu 1
-menu 2
   |
- menu 2.1
- menu 2.2
 -menu 3
 -menu 4

Thanks

-TJ


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/