RAYMOON
چهارشنبه 10 خرداد 1391, 14:04 عصر
با سلام به همگی دوستان من یک تمپلیت آماده دارم که می خوام از اون در برنامه خودم استفاده کنم
این فایل آماده از نوع ای جکس است
ساختار ایندکسش اینجوریه من می خوام مقادیر name و email فرم رو به تابع های به همین اسم به load.php بفرسته
ممنون میشم کمک کنید:قلب::قلب:
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript" src="js/jquery-1.3.1.min.js"></script>
<script type="text/javascript">
/*<![CDATA[*/
$(document).ready(function () {
var value = $('#button input').val();
var name = $('#button input').attr('name');
$('#button input').remove();
$('#button').html('<a href="#" class="cssSubmitButton" rel=' + name + '>' + value + '</a>');
$('#button a').live('click', function () {
//You can use default form submission or with the ajax call below
//In this example, I'm using a dummy php call so that you can see the loading animation
//$('form[name=' + $(this).attr('rel') + ']').submit();
var link = $(this);
$.ajax({
url : 'load.php',
data: '',
type: 'GET',
cache: 'false',
beforeSend: function () {
link.addClass('loading');
},
success: function () {
link.removeClass('loading');
alert('Submitted');
}
});
});
});
/*]]>*/
</script>
<style type="text/css"> </head>
<body>
<form method="post" action="" name="subscribeForm">
<fieldset>
<label>Name: </label><input type="text" class="effect" name="name">
</fieldset>
<fieldset>
<label>Email: </label><input type="text" class="effect" name="email">
</fieldset>
<div id="button">
<input type="submit" value="Subscribe" name="subscribeForm"/>
</div>
</form>
</body>
</html>
این فایل آماده از نوع ای جکس است
ساختار ایندکسش اینجوریه من می خوام مقادیر name و email فرم رو به تابع های به همین اسم به load.php بفرسته
ممنون میشم کمک کنید:قلب::قلب:
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script type="text/javascript" src="js/jquery-1.3.1.min.js"></script>
<script type="text/javascript">
/*<![CDATA[*/
$(document).ready(function () {
var value = $('#button input').val();
var name = $('#button input').attr('name');
$('#button input').remove();
$('#button').html('<a href="#" class="cssSubmitButton" rel=' + name + '>' + value + '</a>');
$('#button a').live('click', function () {
//You can use default form submission or with the ajax call below
//In this example, I'm using a dummy php call so that you can see the loading animation
//$('form[name=' + $(this).attr('rel') + ']').submit();
var link = $(this);
$.ajax({
url : 'load.php',
data: '',
type: 'GET',
cache: 'false',
beforeSend: function () {
link.addClass('loading');
},
success: function () {
link.removeClass('loading');
alert('Submitted');
}
});
});
});
/*]]>*/
</script>
<style type="text/css"> </head>
<body>
<form method="post" action="" name="subscribeForm">
<fieldset>
<label>Name: </label><input type="text" class="effect" name="name">
</fieldset>
<fieldset>
<label>Email: </label><input type="text" class="effect" name="email">
</fieldset>
<div id="button">
<input type="submit" value="Subscribe" name="subscribeForm"/>
</div>
</form>
</body>
</html>