Date Input Calendar - Week Starting on Sunday

0

Is there a way to change the Date Selection calendar weeks to start on Sunday instead of Monday? My current WordPress settings have the calendar starting on Sunday. Thanks.

asked Mar 30 '10 at 6:40

ckpicker

20

add comment
enter at least 15 characters

8 Answers

1

Have you looked into using another Date Calendar script? You can use any one you'd like by creating an Input Helper with the related code and assigning it to the Date column of your choice.

You can find out more about Input Helpers here: http://podscms.org/codex/input_helpers

answered Mar 30 '10 at 6:40

sc0ttkclark

2936

add comment
enter at least 15 characters
0

sc0tt, I´d like to do that, but I have no idea about the code to use on the input helper...

For exemple, to use this script: http://docs.jquery.com/UI/Datepicker

I put this code on head:

<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
  <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
  <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>

  <script>
  $(document).ready(function() {
    $("#datepicker").datepicker();
  });
  </script>

And what code on the input helper?? Thanks again!!

answered Jan 18 '11 at 1:37

iCristiano

11

add comment
enter at least 15 characters
0

Hey iCristiano,

You could use the following code as an input helper. Also instead of using #datepicker in your javascript you should assign the actual ID of the field that you'll be setting this to. For instance if your field is simply named "date" then the ID will be "pods_form1_date"

answered Jan 18 '11 at 3:01

hsatterwhite

211

add comment
enter at least 15 characters
0

Thanks hsatter!

I did what you said, but nothing happened... Do I need to change the ID like that:

<script>
  $(document).ready(function() {
    $("#pods_form1_date").datepicker();
  });
</script>

answered Jan 18 '11 at 3:01

iCristiano

11

The example I gave was for a field with a machine name of "date". Be sure to check what you are naming your field and I would also use either Firebug or an web inspector (like the one built in to Chrome/Safari) to validate the actual ID of the form field. Once you have them matched correctly that should work. – hsatterwhite Jan 18 '11 at 3:27
strange... using firebug i realized that the field don´t have an id: <input type="text" value="" pods_form1_data="" class="form date data pods_field pods_field_data pods_coltype_dateid="> – iCristiano Jan 18 '11 at 4:31
add comment
enter at least 15 characters
0

strange... using firebug i realized that the field don´t have an id:

<input type="text" value="" pods_form1_data="" class="form date data pods_field pods_field_data pods_coltype_dateid=">

answered Jan 18 '11 at 5:13

iCristiano

11

Interesting, did you use the input helper code I supplied? That's setup for a single text field and to use the CSS classes and ID as defined by PodsCMS. I can't check it now, but later today I'll double check what I sent you, so we can get you on track. :) – hsatterwhite Jan 19 '11 at 1:09
ICristiano, what I sent should print the css classes and ID as defined by Pods for whatever field that input helper is assigned to. Any chance you could post a screen shot or some code, so we can check it out? – hsatterwhite Jan 20 '11 at 12:54
add comment
enter at least 15 characters
0

@hsatterwhite I realized there was a problem with your code (I think so)... take a look there

Now, when I see it on Firebug, this is the result:

<input type="text" value="" id="pods_form1_date" class="form date inicio pods_field pods_field_inicio pods_coltype_date">

But it still doesn´t get the JQuery Data Picker... its just a blank field.

answered Feb 10 '11 at 12:44

iCristiano

11

Apologies if they're any bugs! Are you selecting input#pods_form1_date in your jQuery when trying to assign the date picker to it? – hsatterwhite Feb 10 '11 at 1:00
add comment
enter at least 15 characters
0

In fact, I don´t know if I´m using the JQuery correctly... I don´t know if I´m puting the right codes in the right place... It´s my first experience with it...

Do I just need to put all this code on header.php ?

  <link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
  <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
  <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>

  <script>
  $(document).ready(function() {
    $("#pods_form1_date").datepicker();
  });
  </script>

answered Feb 10 '11 at 1:30

iCristiano

11

edited Feb 10 '11 at 1:32

Are you looking to use this on the front-end of your site or in the backend? You can include the <script type="text/javascript"> $(document).ready(function() { $("#pods_form1_date").datepicker(); }); </script> in your nput helper code. Are you getting any kind of JavaScript errors in FireBug or do you have a link you could shoot my way so I can take a better look at this? – hsatterwhite Feb 10 '11 at 4:21
add comment
enter at least 15 characters
0

No, I don´t get any error in Firebug... I want to use it on backend, substituing the defaul pod´s datapicker.

I tryed to do what you said, changing place of the script from header.php to the input helpper, and the field is still blank...

I don´t know what to send you... if you give me some email, I can send you a password of the admin area... Thanks again @hsatterwhite!

answered Feb 10 '11 at 4:57

iCristiano

11

That works for me! whsatterwhite@gmail.com - Fire away :) – hsatterwhite Feb 10 '11 at 6:10
I sent you the email! Thanks! – iCristiano Feb 11 '11 at 1:08
add comment
enter at least 15 characters