Jump to content

js code problem


dgnzcn

Recommended Posts

hi,

i combined two js code in one, gradient slider wroking and changed codes in  text area. this is ok. but gradient colors can not displaying in textarea and also horizontal and vertical menu can not changing colors and codes.

 

what is my wrong ?

lY4yQb.jpg





<div class="export"> <textarea name="baslikrengi_<?php echo $cnt1; ?>" cols="32" class="export" id="baslikrengi_<?php echo $cnt1; ?>"><?php echo KT_escapeAttribute($row_rskayan_icerikler['baslikrengi']); ?></textarea></div>




 

<select id="orientation" onchange="changeOrientation();">
<option value="horizontal">Horizontal</option>
<option value="vertical" selected="selected">Vertical</option>
</select>

<div class="gradient3"></div>
<script>


$(document).ready(function(){
    $('.gradient3').ClassyGradient({                                
        gradient: '#00ffff 0%,#008900 30%,#f00044 70%,#0042d2 100%',
        onChange: function(stringGradient,cssGradient) {
            $('.export').val(cssGradient);
        }
    }); 
});
$(document).ready(function() {
    $('.gradient3').ClassyGradient({
        gradient: '#ebf1f6 0%,#ff9cff 40%,#ff6aff 61%,#ff2db7 100%',
        target: '.export'
    }); 
});
function changeOrientation() {
    var orientation = $('#orientation :selected').val();
    $('.gradient3').data('ClassyGradient').setOrientation(orientation);
}
</script


<script>
$(document).ready(function() {
$('.gradient').ClassyGradient();
});
</script>
Link to comment
https://forums.phpfreaks.com/topic/288734-js-code-problem/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.