Quantcast
Channel: PHP Freaks: PHP Help
Viewing all articles
Browse latest Browse all 13200

Date, timezone problems after upgrading server to PHP 5.3.27

$
0
0

Hi all !

 

I need some help.

I'm not a programer but I would like to solve problem with my website by myself.

After upgrading PHP on server where is my web page ( www.osmrtnica.net ), i'm getting a lot of errors in my CMS.

I hope that someone will have a few minutes to give a look. I have bolded text in code at line 380.

And i know that is a lot of text, but what can i do.

Thanks in advance. 

 

 

here are the errors:

 

<br /><b>Warning</b>:  main() [<a href='function.main'>function.main</a>]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Berlin' for 'CEST/2.0/DST' instead in <b>/home2/smiztita/public_html/cms/required/pozdravi_form.php</b> on line <b>380</b><br /><br /><b>Notice</b>:  Use of undefined constant date - assumed 'date' in <b>/home2/smiztita/public_html/cms/required/pozdravi_form.php</b> on line <b>380</b><br /><br /><b>Warning</b>:  strtotime() [<a href='function.strtotime'>function.strtotime</a>]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Berlin' for 'CEST/2.0/DST' instead in <b>/home2/smiztita/public_html/cms/required/pozdravi_form.php</b> on line <b>380</b><br /><br /><b>Warning</b>:  strtotime() [<a href='function.strtotime'>function.strtotime</a>]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Berlin' for 'CEST/2.0/DST' instead in <b>/home2/smiztita/public_html/cms/required/pozdravi_form.php</b> on line <b>380</b><br /><br /><b>Warning</b>:  date() [<a href='function.date'>function.date</a>]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Berlin' for 'CEST/2.0/DST' instead in <b>/home2/smiztita/public_html/cms/required/pozdravi_form.php</b> on line <b>380</b><br /><br /><b>Warning</b>:  date() expects parameter 2 to be long, string given in <b>/home2/smiztita/public_html/cms/required/pozdravi_form.php</b> on line <b>380</b><br />  

And here is a part of code where error ocurs:

 

 <div class="h3" style="height:1px;"> </div>
            <div style="width:450px; float:left; "> 
            <label for="odobreno">odobreno:</label>
            <input type="checkbox" class="chk" name="odobreno" id="odobreno" value="1"<?php if ($row['odobreno'] == 't') { ?> checked="checked"<?php } ?> /> 
            <label for="datum">datum:</label>
            <input type="text" name="datum" id="datum" class="tekst srednji" value="<?php if ($row['datum'] != '') print date('d.m.Y', date.strtotime($row['datum'])); else print date('d.m.Y'); ?>" />
<script type="text/javascript">
                <!--
                    $(document).ready(function(){
                        $('#datum').datepicker({ 
                            mandatory: true,
                            navigationAsDateFormat: true, prevText: '<M', nextText: 'M>',
                            changeMonth: false, 
                            monthNames: ['siječanj ','veljača ','ožujak ','travanj ','svibanj ','lipanj ', 'srpanj ','kolovoz ','rujan ', 'listopad ','studeni ','prosinac '],
                            monthNamesShort: ['sij','velj','ožu','tra','svi','lip','srp','kol','ruj','lis','stu','pro'],
                            changeYear: false,
                            weekHeader: '', showWeeks: true,  
                            dayNames: ['nedjelja', 'ponedjeljak', 'utorak', 'srijeda', 'četvrtak', 'petak', 'subota'],
                            dayNamesShort: ['ned', 'pon', 'uto', 'srij', 'čet', 'pet', 'sub'],
                            dayNamesMin: ['N', 'P', 'U', 'S','Č', 'P', 'S'],
                            showOtherMonths: true,
                            numberOfMonths: 1,
                            defaultDate: Date(<?= date('Y, m, d', strtotime($row['datum'])); ?>), // default date - Date(yyyy, mm - 1, dd), 
                            dateFormat: 'dd.mm.yy', 
                            showWeeks: true, firstDay: 1, changeFirstDay: false,  
                            closeText: 'X', 
                            prevText: '<', 
                            nextText: '>',  
                            currentText: ''
                        });
                    });
                //-->
                </script>   
 
 
 

Viewing all articles
Browse latest Browse all 13200

Trending Articles