1
cmatt
javascript
  • 2005/5/31 0:02

  • cmatt

  • Just popping in

  • Posts: 31

  • Since: 2004/3/25


http://mtcyouth.websiteallies.com

there is a big white space, because my javascript is not working. I want to do a simple random image script there.

I tried to imitate the same one as it has in the header

this is what I did:

<script type="text/javascript">
<!--
<{$xoop2_js}>
//-->
</script>

is where the white space is

I put this in header.php
$xoopsTpl->assign('xoops2_js', '//--></script><script type="text/javascript" src="'.XOOPS_URL.'/include/xoops2.js"></script><script type="text/javascript"><!--');

Now should I have put that somewhere else? and did the same command...

I just need to get this random image to work :/

I tried putting the whole script for this cell as well but that didnt work either

2
Bassman
Re: javascript
  • 2005/5/31 0:23

  • Bassman

  • Friend of XOOPS

  • Posts: 1272

  • Since: 2003/5/23


If you're looking for a random image script for your header, why not use this php script? I've used it before, it's easy and it works.

3
cmatt
Re: javascript
  • 2005/5/31 3:26

  • cmatt

  • Just popping in

  • Posts: 31

  • Since: 2004/3/25


oh i didnt think of even looking for a php script...thanks i will try this!

4
Bassman
Re: javascript
  • 2005/5/31 5:51

  • Bassman

  • Friend of XOOPS

  • Posts: 1272

  • Since: 2003/5/23


I see from your site you got it working.... good.

The site looks great.
Shame you have those poker banner ads on a Christian site though.

5
cmatt
Re: javascript
  • 2005/5/31 6:02

  • cmatt

  • Just popping in

  • Posts: 31

  • Since: 2004/3/25


actually i had to find another script to get it to work :/ it was bring up broken images...I tried running the rotate.php page by itself, and it was giving me errors...like my pictures was encoded wrong or something..but i know its not true :P as u can see from the results

This hosting is just temp....Im using to do all my testing, rather keeping the original domain down....

The orginial domain is not on any CMS nor php....
this is all new for them.

6
Bassman
Re: javascript
  • 2005/5/31 6:10

  • Bassman

  • Friend of XOOPS

  • Posts: 1272

  • Since: 2003/5/23


Oh, that's OK then lol.

At least it works, anyhow. With the script I gave the link for, the idea would be to make a folder in your theme folder called "rotate" or something like that, and put the script and all your images into that folder. Then call your image as <img src="<{$xoops_imageurl}>/rotate/rotate.php">

7
cmatt
Re: javascript
  • 2005/5/31 6:32

  • cmatt

  • Just popping in

  • Posts: 31

  • Since: 2004/3/25


yeah i tried that....
I made a rotate folder and save the rotate.php in this folder

I then moved rotate.php, editied with full path to the rotate folders

But if u run the rotate.php , as i said before, it gave me some wierd encoding errors.

oh well:) I got another working...thanks for ur support here!

Login

Who's Online

200 user(s) are online (151 user(s) are browsing Support Forums)


Members: 0


Guests: 200


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