21
davidthomas1
Re: Please help, i have to finish this. about getting input from user

It's working for me...

Can you post the code you're using for your custom block?

post it in "["code"]" and "[/"code"]" tags to preserve it for the forum (remove the quote "" marks)

I'll have a look.

22
buffalo
Re: Please help, i have to finish this. about getting input from user
  • 2005/4/4 10:26

  • buffalo

  • Just popping in

  • Posts: 33

  • Since: 2005/3/26


sory i was on a vocation. now the code is here :
<script type="text/javascript">
<!--
function 
popup()
{
 var 
url=document.forms[0].elements['number'].value;
 if (
url!=""){
   
url="http://www.maykopelektronik.com/"+url+".html";
   
window.openurl"Window Title","status = 1, height = 300, width = 300, resizable = 0" )
   }
 else{
   
alert("Invalid number");
   }
}
//-->
</script>
<
form>
<
input type="text" name="number" size="20">
<
input type="button" onClick="popup()" value="Go!">
</
form>

23
buffalo
Re: Please help, i have to finish this. about getting input from user
  • 2005/4/5 10:25

  • buffalo

  • Just popping in

  • Posts: 33

  • Since: 2005/3/26


please someone help me, i couldnt make it in 2 weeks!

24
davidthomas1
Re: Please help, i have to finish this. about getting input from user

Try giving the form a name.

For example :

<script type="text/javascript">
<!--
function 
popup()
{
 var 
url=document.forms['info'].elements['number'].value;
 if (
url!=""){
   
url="http://www.maykopelektronik.com/"+url+".html";
   
window.openurl"Window Title","status = 1, height = 300, width = 300, resizable = 0" )
   }
 else{
   
alert("Invalid number");
   }
}
//-->
</script>
<
form name="info">
<
input type="text" name="number" size="20">
<
input type="button" onClick="popup()" value="Go!">
</
form>


If you have a file named 1.html in your XOOPS root directory, then if you type '1' in the textbox, it should popup in the window.

Make sure you save the custom block as HTML.

The code is working for me so I'm not sure what the problem is...

25
buffalo
Re: Please help, i have to finish this. about getting input from user
  • 2005/4/6 10:24

  • buffalo

  • Just popping in

  • Posts: 33

  • Since: 2005/3/26


the last code doesnt work :)

26
davidthomas1
Re: Please help, i have to finish this. about getting input from user

I'm sorry, I don't think I can help anymore, the code is working for me so I don't know what the problem is.

unless someone else can shed some light...

You may have to work it out yourself at your end.

good luck!

27
buffalo
Re: Please help, i have to finish this. about getting input from user
  • 2005/4/6 10:34

  • buffalo

  • Just popping in

  • Posts: 33

  • Since: 2005/3/26


i very thank to you, you tried to help but i coudnt do it. really thanks. Now i think i need a way to do it with php. Is here any body can solve the problem with php ?

Login

Who's Online

209 user(s) are online (128 user(s) are browsing Support Forums)


Members: 0


Guests: 209


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