1
lajab
JS won't show
  • 2005/1/28 19:48

  • lajab

  • Just popping in

  • Posts: 47

  • Since: 2003/9/3 1


Hi all,

I'm using one of the 7 dana's themes, and can't get the JS that displays the date and time to show. It shows on my test server but not on my site. Could it be an issue with my hosting, if so, does anyone know of a mod that I can use to do this?

2
carnuke
Re: JS won't show
  • 2005/1/28 19:58

  • carnuke

  • Home away from home

  • Posts: 1955

  • Since: 2003/11/5


I doubt that your host denies javascript ?

It's an obvious thing to say, but double check that your JS is correct and that the call to the file is correct

ie if you are wanting this script to be available in all pages in your site, place this in your head of theme.html file

<script language="javascript" src="<{$xoops_imageurl}>myjavascript_file.js"></script>


Now put the .js file in the root directory of the theme you are using. xoops_image_url translates tohttp://yoursite.com/themes/your_theme/

Hope this helps some

3
lajab
Re: JS won't show
  • 2005/1/28 20:30

  • lajab

  • Just popping in

  • Posts: 47

  • Since: 2003/9/3 1


Thanks Nuke!

Still haven't gotten it to work yet, I'm quite sure I'm missing something, just don't know what.

4
Catzwolf
Re: JS won't show
  • 2005/1/28 20:33

  • Catzwolf

  • Home away from home

  • Posts: 1392

  • Since: 2007/9/30


You don't need to use js to display the time and date in your theme.

You can use <?php date(D d-M-Y, time()); ?> instead.

5
lajab
Re: JS won't show
  • 2005/1/28 20:35

  • lajab

  • Just popping in

  • Posts: 47

  • Since: 2003/9/3 1


Thank you sir! :)

6
Catzwolf
Re: JS won't show
  • 2005/1/28 20:36

  • Catzwolf

  • Home away from home

  • Posts: 1392

  • Since: 2007/9/30


ur welcome mam

7
lajab
Re: JS won't show
  • 2005/1/28 20:44

  • lajab

  • Just popping in

  • Posts: 47

  • Since: 2003/9/3 1


Well that didn't work, think if I take a crayon and just write it in on the screen it'll show up on the site? Magic Marker maybe?

8
Catzwolf
Re: JS won't show
  • 2005/1/28 20:53

  • Catzwolf

  • Home away from home

  • Posts: 1392

  • Since: 2007/9/30


To answer your question, nope it wont :-p

And correction on my last statement, try:

<?php date("D d-M-Y", time()); ?>

Instead

or you could use <?php formatTimestamp( time(), "D d-M-Y" ); ?>

9
lajab
Re: JS won't show
  • 2005/1/28 21:09

  • lajab

  • Just popping in

  • Posts: 47

  • Since: 2003/9/3 1


Bah! I give up..time to drink some tequila and move on, thanks though folks.

10
Catzwolf
Re: JS won't show
  • 2005/1/28 21:15

  • Catzwolf

  • Home away from home

  • Posts: 1392

  • Since: 2007/9/30


Show me the code that your using and lets take it from there.

Login

Who's Online

252 user(s) are online (165 user(s) are browsing Support Forums)


Members: 0


Guests: 252


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits