1
anurag
Help/Suggestion
  • 2004/2/2 8:09

  • anurag

  • Just popping in

  • Posts: 7

  • Since: 2004/2/2 8


hi,

I am new to XOOPS and have a question...i want to have a section on the front page of my website which displays a "daily fact(random facts on anything educational)"...does anyone know a module that is able to do this?....or is there any way in which i can post the "daily facts" there myself and have it archived so the users can view the previous ones too

Any help or suggestion would be really appreciated.Thank you and have a nice day.


2
carnuke
Re: Help/Suggestion
  • 2004/2/2 9:06

  • carnuke

  • Home away from home

  • Posts: 1955

  • Since: 2003/11/5


Hello, anurag and welcom to the XOOPS forums! As far as I know there is no module that rotates pages according to date in this way. The closest we have so far is the quotes modules. However, the content is random and you can't view the whole of the quotes. I do have a couple of html sripts that are intended for displaying a specific page per day. I don't think they show previous days though. These are not XOOPS scripts, so if you want to use them they will need integrating into a custom block, or an iframe. Post back if this sounds anywhere useful and I will dig them out and tell you how.

Richard

3
anurag
Re: Help/Suggestion
  • 2004/2/2 20:12

  • anurag

  • Just popping in

  • Posts: 7

  • Since: 2004/2/2 8


Hi Richard,

Thanks for replying..I would really appreciate it if you could give me the HTML scripts..

Thanks again.

Anurag

4
Mithrandir
Re: Help/Suggestion

Hmmm... such a module is part of PostNuke. Should be possible to port it to XOOPS (no time, sorry)

5
carnuke
Re: Help/Suggestion
  • 2004/2/2 23:02

  • carnuke

  • Home away from home

  • Posts: 1955

  • Since: 2003/11/5


Hi Richard
follow this link for rotation scripts HERE


Here's one I used myself


place the code below into a blank html page and call it "redirect.html"  place it in a directory  called /rotate/
-------------------------------------------------------

<
html>

<
head>
<
script language="JavaScript" type="text/javaScript">
<!-- 
Begin
// This will retrieve today's date from the visitors computer 
var today = new Date();

// This will extract the numeric value of what day of the month today is 
var dayOfMonth today.getDate();

// This will create the name of the HTML document to be retrieved 
var target dayOfMonth ".html";

// This will redirect the browser to the correct HTML document 
window.location target;
// End -->
</script></head>

<
body>

</
body>

</
html>

-----------------------------------------------------------
Now create 31 pages with different textimages etc to suit each day of the month

call page 1   
"1.html"
call page 2   "2.html" 

etc to 31

place them all in the same directory 
as "redirect.html

--------------------------------------------------------

to use the script simply call /rotate/"
redirect.html"


You could now create a custom block with an iframe and call "rotate/redirect.html" like this

<div align='center'>
<IFRAME align=center width=100% height=600 scrolling="auto" src="http://www.yoursite.com/.../rotate/redirect.html" ></IFRAME>
</div>

This would automatically load the correct page corresponding to todays' date as soon as the page with the iframe loaded. To view other pages other than todays date you could try making hyperlinks in another block to other day names and target the iframe. Add a link to redirect.html as well and call it 'today' This is all off the top of my head, so please experiment ok!

Richard

Login

Who's Online

170 user(s) are online (113 user(s) are browsing Support Forums)


Members: 0


Guests: 170


more...

Donat-O-Meter

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

Latest GitHub Commits