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

  • SEARCH
  • Home
  • 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 7863557
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T23:31:19+00:00 2026-06-02T23:31:19+00:00

I am using the following snippet to display my chart : xaxis: { min:

  • 0

I am using the following snippet to display my chart :

     xaxis: {
        min: '2012-01-01 00:00:00.0',
        max: '2012-04-01 00:00:00.0',
        renderer : "$.jqplot.DateAxisRenderer",
        rendererOptions : {
           "tickRenderer" : "$.jqplot.CanvasAxisTickRenderer"
        },
        numberTicks: 4,
        showTickMarks : false,
        tickOptions:{
           angle:0,
           formatString:'%b %Y'
        }
    },

    Data :[
          ['2012-01-01 00:00:00.0', 0]
        , ['2012-02-01 00:00:00.0', 0]
        , ['2012-03-01 00:00:00.0', 0]
        , ['2012-04-01 00:00:00.0', 0]
    ]

Instead of displaying : Jan 2012, Feb 2012, Mar 2012, Apr 2012
it displays :
Jan 2012, Jan 2012, Mar 2012, Apr 2012.

On debugging further I found that second point is actually 31-Jan-2012, which on applying format displays as Jan 2012.

How can I ensure that it shows the months properly.

Thanks in advance.

  • 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-06-02T23:31:20+00:00Added an answer on June 2, 2026 at 11:31 pm

    I have noticed that you have some ‘disorder’ in your code.
    The tickRenderer should be outside the rendererOptions parameter.
    Also the quotes around it and around the classes of renderers are not necessary.

    I am quessing that you want to have ticks each showing interval of one month?
    Therefore, use tickInterval parameter instead. For example: tickInterval: "1 months"

    Just like I showed in my other answer.

    EDIT:
    I got it sorted. Apparently there is no point of limiting the number of ticks as then they are wrongly counted. Since to benefit from tickInterval you are forced to use min and max parameters, therefore, it is only right to let the script figure out the number of ticks, right? 🙂

    So to have it working the way you want just remove the line with numberTicks. It is shown here.

    NOTE:
    I realised why the numberTicks behaves this way. It is so because it is making the distance between the ticks equal.

    We have 122 days from 1st Jan to 1st May of 2012.
    If we divide the number of days by numberTicks – 1 (i.e. 4) we get 30.5. Therefore, we have 1st Jan, 31st Jan, 1st March, 31st March and 1st May.

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

Sidebar

Related Questions

I am using the following jquery snippet to display an image on my upload
I am using following snippet to build a 32 bit integer to use with
I am using the following code snippet to calculate a total price. This works
I'm using the following code-snippet extensively in my model templates. <div class=control-group> @Html.LabelFor(model =>
From the book Groovy and Grails recipes I'm using the following code snippet: String
I have the following snippet of code (I'm using jQuery 1.4.2): $.post('/Ads/GetAdStatsRow/', { 'ad_id':
I'm using Bootstrap to style my website. I have the following snippet in my
I could build a sip profile using SipProfile.Builder class. I used following snippet of
I have the following code snippet: using (SPSite site = new SPSite(this.ListAddress)) { using
Here is the following code-snippet I'm using in my Google Spreadsheet onEdit() function: else

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.