# Display time on web browser

**URL:** <https://forums.digi.com/t/display-time-on-web-browser/9145>\
**Category:** Rabbit\
**Created:** [January 12, 2009, 7:30am UTC](https://forums.digi.com/t/display-time-on-web-browser/9145 "2009-01-12T07:30:23Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![vtherock](https://avatars.discourse-cdn.com/v4/letter/v/82dd89/32.png) [@vtherock](https://forums.digi.com/u/vtherock)\
**Post date:** [January 12, 2009, 7:30am UTC](https://forums.digi.com/t/display-time-on-web-browser/9145/1 "2009-01-12T07:30:23Z")

</div>

Hey guys i need help to display time on web browser. when sensor senses a break in, it will trigger and take down of tat specific time and be printed out in a textfile den display on the web browser. Pls help me thx… I do not know how can i save the time to a textfile.

---

<div class="post-metadata">

**Author:** ![vtherock](https://avatars.discourse-cdn.com/v4/letter/v/82dd89/32.png) [@vtherock](https://forums.digi.com/u/vtherock)\
**Post date:** [January 12, 2009, 8:10am UTC](https://forums.digi.com/t/display-time-on-web-browser/9145/2 "2009-01-12T08:10:20Z")

</div>

Some Pros pls help me take a look which part of my coding went wrong\>\>\>\>

void update\_text()  
{  
auto struct tm time;  
char includes[512];

```
#GLOBAL_INIT { date_lock=0; }

if(date_lock) return;

tm_rd(&amp;time);

month=time.tm_mon;
day=time.tm_mday;
year=time.tm_year+1900;
hour=time.tm_hour;
minute=time.tm_min;
second=time.tm_sec;

root2xmem(includes_txt,includes,512);

     sprintf(includes,"%02d/%02d/%04d %02d:%02d:%02d",
     month,
     day,
     year,
     hour,
     minute,
     second);

```

}

---

<div class="post-metadata">

**Author:** ![Monalisa](https://avatars.discourse-cdn.com/v4/letter/m/4bbf92/32.png) [@Monalisa](https://forums.digi.com/u/Monalisa)\
**Post date:** [February 3, 2009, 9:24am UTC](https://forums.digi.com/t/display-time-on-web-browser/9145/3 "2009-02-03T09:24:24Z")

</div>

Your coding seems fine, let me check it on my PC only then i will be able to crack the error
