Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6778229
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T16:14:32+00:00 2026-05-26T16:14:32+00:00

I have the following code and I have problem with jQuery UI Slider. What

  • 0

I have the following code and I have problem with jQuery UI Slider. What is my problem:

While the slider is rendered correctly, it acting very strange. What do I mean? Instead of rendering to handlers it is rendering only one, and the slider can slide only until the value 70 witch is the second value into my array. Any idea please on how to solve that problem ?

Here is my code:

HTML:

<td valign="top">
    <input 
        class="slider_hidden" 
        type="hidden"
        name="field_name" 
        value="10,70" 
        id="slider_hidden" 
        data-disabled="0"
        data-min="0"
        data-max="100"
        data-orientation="horizontal"
        data-step="1"
        data-range="1"
    />
    <div class="slider"></div>
    <br />
    <span class="description"><?php echo $description; ?></span>
</td>

JavaScript

$(document).ready(
    function()
    {
        $(".slider").each(
            function()
            {
                var val = $(this).prev('input.slider_hidden').val();
                var min = $(this).prev('input.slider_hidden').data('min');
                var max = $(this).prev('input.slider_hidden').data('max');
                var step = $(this).prev('input.slider_hidden').data('step');
                var slide_disabled = ($(this).prev('input.slider_hidden').data('disabled') == "1" ? true : false);
                var orientation = $(this).prev('input.slider_hidden').data('orientation');
                var range = ($(this).prev('input.slider_hidden').data('range') == "1" ? true : false);

                $(this).slider(
                    {
                        min: min,
                    max: max,
                        step: step,
                        disabled: slide_disabled,
                        orientation: orientation,
                        slide: function(e, ui)
                        {
                            console.log(ui);
                            $(this).prev('input.slider_hidden').val(ui.value);
                        }
                    }
                );

                $(this).slider('option', 'range', range);

                if(range == true)
                {
                    var s = val.split(',');
                    $(this).slider("option", "values", s);
                }
                else
                {
                    $(this).slider("option", "value", val);
                }
            }
        );
    }
);

Note that all values are retrived correctly from hidden field.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T16:14:33+00:00Added an answer on May 26, 2026 at 4:14 pm

    After a long investigation, it seems you can set values or value once it has been initialized !

    So I’ve found no others solutions than doing this : http://jsfiddle.net/7YVVY/1/

    It works, but it is not elegant 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a strange problem with Jquery Ajax with the following code. Situation 1:
I have a problem with JQuery Toggle. I have the following code: var $_
I have problems with the following bit of javascript/jquery code: this.droppable = function(){ $('.imageWindow
I have the following code: The actual problem is the non-quoted code. I want
I have the following code I want to run, but the problem is $this->type
The following code summarizes the problem I have at the moment. My current execution
I have problems with following code: http://lisper.ru/apps/format/96 The problem is in normalize function, which
The following code demonstrates a weird problem I have in a Turbo C++ Explorer
I have following problem, Code: String a=Yeahh, I have no a idea what's happening
I have a problem with the following code: for(i = 0;(i - 1)< n;i++)

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.