The Mother Board

Motherboards.org forums. Free tech support, motherboard ID, and more.
It is currently Sat Sep 22, 2018 8:46 pm

All times are UTC - 8 hours




Post new topic Reply to topic  [ 9 posts ] 
Author Message
PostPosted: Thu Feb 17, 2005 8:12 pm 
Offline
Initiate
Initiate

Joined: Fri Jan 23, 2004 11:13 pm
Posts: 79
Hi,

I am wondering how would i change all the values of a drop down list in html with another list of values???

Thanks


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Feb 17, 2005 8:20 pm 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
:?

Not quite sure what you are asking. Post the code that you are trying to change and I will see if I can help. Also if you can clearify more on exactly what you needed changed...

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
 Post subject: Here It Is
PostPosted: Thu Feb 17, 2005 8:39 pm 
Offline
Initiate
Initiate

Joined: Fri Jan 23, 2004 11:13 pm
Posts: 79
Basically I need to make it to change the list of days in the days when month changes.
All i really need to know is how to change the values in the drop down lists all at the same time, perhaps delete them first.
Thanks for the help, was having problems finding a solution




Code:
<html>
<head>

<script type="text/javascript">

function changeDayListValues()
{
}

</script>
</head>

<body>
<form>
Select a Month:
<select name="monthList" onchange="changeDayListValues()">
   <option>January</option>
   <option>February</option>
   <option>March</option>
   <option>April</option>
   <option>May</option>
   <option>June</option>
   <option>July</option>
   <option>August</option>
   <option>September</option>
   <option>October</option>
   <option>November</option>
   <option>December</option>
</select>

<br />

Select a day:
<select name="myList" onchange="put()">
   <option>1</option>
   <option>2</option>
   <option>3</option>
   <option>3</option>
   <option>4</option>
   <option>5</option>
   <option>6</option>
   <option>7</option>
   <option>8</option>
   <option>9</option>
   <option>10</option>
   <option>11</option>
   <option>12</option>
   <option>13</option>
   <option>14</option>
   <option>15</option>
   <option>16</option>
   <option>17</option>
   <option>18</option>
   <option>19</option>
   <option>20</option>
   <option>21</option>
   <option>22</option>
   <option>23</option>
   <option>24</option>
   <option>25</option>
   <option>26</option>
   <option>27</option>
   <option>28</option>
   <option>29</option>
   <option>30</option>
   <option>31</option>
</select>

</form>
</body>

</html>


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Feb 17, 2005 9:16 pm 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
Might have to wait til MoboCop gets back, but I will see what I can do in the meantime...

Does your webhost allow php?

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
 Post subject: Reply
PostPosted: Thu Feb 17, 2005 9:32 pm 
Offline
Initiate
Initiate

Joined: Fri Jan 23, 2004 11:13 pm
Posts: 79
No, there is no php, its basically for school not for web hosting.
thanks


Top
 Profile  
Reply with quote  
 Post subject: Re: Reply
PostPosted: Thu Feb 17, 2005 9:39 pm 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
chrisostomos wrote:
No, there is no php, its basically for school not for web hosting.
thanks


Well since it is a school project, I will only offer suggestions. And bear in mind javascript is not my strong point!

Look into if/else if statements. If I remember correctly javascript can handle those.

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Feb 17, 2005 9:45 pm 
Offline
Initiate
Initiate

Joined: Fri Jan 23, 2004 11:13 pm
Posts: 79
Bascially the problem i have is i dont know how to change the values in the drop down list. I need to delete them all and then put them in.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Feb 17, 2005 10:15 pm 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
chrisostomos wrote:
Bascially the problem i have is i dont know how to change the values in the drop down list. I need to delete them all and then put them in.


Figure out what months have x amount of days and setup a statement. Then proceed to the next group of months with x amount of days. And so on.

Basically you want to create a group association. A particular letter/number/symbol represents a certain number of days. And associate that particular character to an optin in the months menu. So when you select for example January you will see 31 days in the "days menu" and so on.

Since this is a school project I am assuming you must have or have access to text books for learning javascript. Not trying to be rude, but the best way to learn is by doing it. Trial and error often returns great results..

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Fri Feb 18, 2005 8:42 am 
Offline
Initiate
Initiate

Joined: Fri Jan 23, 2004 11:13 pm
Posts: 79
Its ok your not rude, but we dont have a textbook for this course. We are suppose to use the internet.

I know how to use if statements to do everything but i just dont know how to addElements or removeElements to the list

thats the one thing i dont know how to do. Or is there a way to remove all elements from the drop Down List or to add an array of strings to the list

Thanks !!!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC - 8 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group