473,399 Members | 2,278 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

monthly frames

I am using frames - yes frames - I do not know how to do anything but and I
know that there is better out there......but........
I am trying to set a frame so that it automatically puts a page
corresponding to the month in that frame (a calendar)

I know this is way off (sleep should have happened hours ago)

can anyone help????

Thank you

script language="JavaScript"><!-- function tresmonth() {
var mydate=new Date()
var month=mydate.getMonth()
var display=new Array("jan.html",
"feb.html",
"march.html",
"april.html",
"may.html",
"june.html",
"july.html",
"aug.html",
"sept.html"
"oct.html",
"nov.html",
"dec.html")

<frame name="right" src="displayarray[month]>}

// --</script>
Sep 19 '06 #1
6 1106
prophet wrote on 19 sep 2006 in comp.lang.javascript:
I am using frames - yes frames - I do not know how to do anything but
and I know that there is better out there......but........
I am trying to set a frame so that it automatically puts a page
corresponding to the month in that frame (a calendar)

I know this is way off (sleep should have happened hours ago)

can anyone help????

Thank you

script language="JavaScript"><!-- function tresmonth() {
var mydate=new Date()
var month=mydate.getMonth()
var display=new Array("jan.html",
"feb.html",
"march.html",
"april.html",
"may.html",
"june.html",
"july.html",
"aug.html",
"sept.html"
"oct.html",
"nov.html",
"dec.html")

<frame name="right" src="displayarray[month]>}

// --</script>
No need for any varable declarations ;-)
<frame name='right' src='' id='right'>

<script type='text/javascript'>
document.getElementById('right').src =
'jan/feb/march/april/may/june/july/aug/sept/oct/nov/dec/'.
split('/')[new Date().getMonth()]+'.html'
</script>

NOT TESTED

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Sep 19 '06 #2
JRS: In article <YULPg.551874$Mn5.422149@pd7tw3no>, dated Tue, 19 Sep
2006 06:14:16 remote, seen in news:comp.lang.javascript, prophet
<M_*****@hotmail.composted :
>I am using frames - yes frames - I do not know how to do anything but and I
know that there is better out there......but........
Then read the newsgroup FAQ, and find them in js-date6.htm.
>I am trying to set a frame so that it automatically puts a page
corresponding to the month in that frame (a calendar)
By your way, you will need up to 91 different files; 12 month names (one
with two lengths) times 7 start-days.

Far better to get a year and month, or a Date Object, and compute
everything.

It's a good idea to read the newsgroup and its FAQ.
--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.com/faq/>? JL/RC: FAQ of news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htmjscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/TP/BP/Delphi/jscr/&c, FAQ items, links.
Sep 19 '06 #3

"Evertjan." <ex**************@interxnl.netwrote in message
news:Xn*******************@194.109.133.242...
prophet wrote on 19 sep 2006 in comp.lang.javascript:
>I am using frames - yes frames - I do not know how to do anything but
and I know that there is better out there......but........
I am trying to set a frame so that it automatically puts a page
corresponding to the month in that frame (a calendar)

I know this is way off (sleep should have happened hours ago)

can anyone help????

Thank you

script language="JavaScript"><!-- function tresmonth() {
var mydate=new Date()
var month=mydate.getMonth()
var display=new Array("jan.html",
"feb.html",
"march.html",
"april.html",
"may.html",
"june.html",
"july.html",
"aug.html",
"sept.html"
"oct.html",
"nov.html",
"dec.html")

<frame name="right" src="displayarray[month]>}

// --</script>

No need for any varable declarations ;-)
<frame name='right' src='' id='right'>

<script type='text/javascript'>
document.getElementById('right').src =
'jan/feb/march/april/may/june/july/aug/sept/oct/nov/dec/'.
split('/')[new Date().getMonth()]+'.html'
</script>

NOT TESTED

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Thank you, but did not work.

Sep 20 '06 #4
prophet wrote on 20 sep 2006 in comp.lang.javascript:
><script type='text/javascript'>
document.getElementById('right').src =
'jan/feb/march/april/may/june/july/aug/sept/oct/nov/dec/'.
split('/')[new Date().getMonth()]+'.html'
</script>

NOT TESTED
>
Thank you, but did not work.
You off all people should know a prophed on his home turf ...

How do you program?
Just using an example as-is?
Or examening, debugging and using the method?

What do you men by "not work"?

did you try:

<script type='text/javascript'>
var s =
'jan/feb/march/april/may/june/july/aug/sept/oct/nov/dec/'.
split('/')[new Date().getMonth()]+'.html'

alert(s)

// document.getElementById('right').src = s
// the above line only works if the id is already defined.

</script>

to narrow down the problem?

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Sep 20 '06 #5

"Evertjan." <ex**************@interxnl.netwrote in message
news:Xn********************@194.109.133.242...
prophet wrote on 20 sep 2006 in comp.lang.javascript:
>><script type='text/javascript'>
document.getElementById('right').src =
'jan/feb/march/april/may/june/july/aug/sept/oct/nov/dec/'.
split('/')[new Date().getMonth()]+'.html'
</script>

NOT TESTED
>>
Thank you, but did not work.

You off all people should know a prophed on his home turf ...

How do you program?
Just using an example as-is?
Or examening, debugging and using the method?

What do you men by "not work"?

did you try:

<script type='text/javascript'>
var s =
'jan/feb/march/april/may/june/july/aug/sept/oct/nov/dec/'.
split('/')[new Date().getMonth()]+'.html'

alert(s)

// document.getElementById('right').src = s
// the above line only works if the id is already defined.

</script>

to narrow down the problem?

I am new to this so I try it as written and then play with it to figure it
out. Sometimes I get it right away - sometimes it takes a bit of work to
figure it out.

The code comes up with an empty frame.
Sep 21 '06 #6
prophet wrote on 21 sep 2006 in comp.lang.javascript:
>did you try:

<script type='text/javascript'>
var s =
'jan/feb/march/april/may/june/july/aug/sept/oct/nov/dec/'.
split('/')[new Date().getMonth()]+'.html'

alert(s)

// document.getElementById('right').src = s
// the above line only works if the id is already defined.
Or perhaps it does not.
>>
</script>

to narrow down the problem?


I am new to this so I try it as written and then play with it to
figure it out. Sometimes I get it right away - sometimes it takes a
bit of work to figure it out.

The code comes up with an empty frame.
Did you ask yourself why?

It seems, as you do not try to undersand coe and to learn, but only want
ready made solutions, you better hire a payed programmer.

I will give you another code, try it out as test.html:

=================
<script type='text/javascript'>
setTimeout(
'window.frames["b"].location = "http://cnn.com"',
800)
</script>

<frameset cols="50,50">
<frame src="" name='t'>
<frame src="" name='b'>
</frameset>
=================
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Sep 21 '06 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Ray in HK | last post by:
I have 2 tables, they are daily and monthly tables. I want to update the monthly table with the max and min value of the daily table with the corresponding month. I figure out the following...
7
by: David Hayes | last post by:
I tried finding an answer on http://www.quirksmode.org/ without success. I am attempting a complicated Frames structure. I have made it work in IE, but not Netscape. I begin with three...
25
by: Steal | last post by:
Hi at all I try to validate this page using the link: http://validator.w3.org/ but it return that this is not a valid HTML 4.01 page please where is it error? Steil <!DOCTYPE HTML PUBLIC...
18
by: Jeremy Weiss | last post by:
I'm trying to build a database that will handle the monthly billing needs of a small company. I'm charting everything out and here's what I see: table for customers sub table to track payments...
3
by: cameron | last post by:
Hi I am new here in this forum: I am writing a C++ program to calculate a Montly Mortgage Payment where the loan amount is 200,000.00 with a 5.75% interest rate with a term of 30 years. My program...
1
by: Paul H | last post by:
Can anyone give me some pointers as to how to construct a form or forms that will allow me to see a schedule of meeting rooms Booked or Available as a nice visual display. The Query that holds the...
1
by: azimid | last post by:
Hello everyone, I need your help with a query. Currently I display the data in a daily format. I have a form that the users submits the date range (from say 20061224 to 20070530) and the...
7
by: Lucas_london via AccessMonster.com | last post by:
Hi I have set up a database/tables in Access based on daily timeseries data. However I would like to create two additional columns in the table as a basis to pull the data on a weekly and...
1
by: Jiwei06xie | last post by:
I'm interested in tracking monthly utility bills....monthly charges, units/volumes, costs per unit and so on, by monthly date. The data source would be mainly from an Excel Spreadsheet (or sometimes...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.