私の jquery/java スキルは存在しません....ちょっとした助けが必要です:
私の上司は、顧客がレビューを書き、ディスカウントの星を付けてから送信ボタンを押すフォームを作りたいと考えています。3 つ以上の星を選択すると、星の少ないレビューを送信したユーザーとは別のページに移動します。
選択した星に応じてその場でリンクを変更する j クエリ ボタンを使用することは可能ですか?
j query Star-rating プラグインを使用しています。
<script type="text/javascript" src="../src/rating.js"></script>
<link rel="stylesheet" href="../src/rating.css" type="text/css" media="screen" title="Rating CSS">
<script type="text/javascript">
$(function(){
$('.container').rating();
});
</script>
</head>
<body>
<h1><a title="Full Documentation" href="http://irfandurmus.com/projects/jquery-star-rating-plugin/">jQuery Star Rating Plugin</a></h1>
<section class="container">
<input type="radio" name="example" class="rating" value="1" />
<input type="radio" name="example" class="rating" value="2" />
<input type="radio" name="example" class="rating" value="3" />
<input type="radio" name="example" class="rating" value="4" />
<input type="radio" name="example" class="rating" value="5" />
</section>
<script type="text/javascript">
if $('.container').rating(4,5) {
echo "<a href="eventual link> Click here to receive your discount code</a>" ;
}
else $('.container').rating(1,2,3) {
echo "<a href="eventual link>Click here to recieve your discount code</a>";
}
</script>