![]() |
javascript hide problem
i've made an ajax profileditor
http://www.ragtek.org/tutorials/editor.htm the fields are coded like this: HTML Code:
<div class="smallfont"><span id="usertitle">test</span></div>Einladungen: <span id="einladungen">200</span> but for usertitle im getting this error: Quote:
usertitle.style.display = 'none'; is working, usertitle.innerHTML = xml_sender.fetch_data(fetch_tags(xml_sender.handle r.responseXML, 'linkhtml')[0]); is also working, but usertitle.style.display = ''; isn't working the fields are updated, just the showpart isn't working :/ |
You can try
Code:
usertitle.style.display = 'inline'; |
hi
thx for answer i don't know as i said its the same function as my edit edit() is working edittitle() not http://www.ragtek.org/forum/clientscript/profilajax.js |
Could there be a problem with using the same global variable inputobj in both functions? Try declaring them as local variable in the functions with var inputobj = 'xxxx';
|
i changed it=> same error
i think i'm missing something |
Add some debugging stuff:
Code:
function savetitle(){ |
1. alert= my input
2,3 => undefined --------------- Added [DATE]1195581708[/DATE] at [TIME]1195581708[/TIME] --------------- problem solved i used a wrong variable so usertitle was the object + the input shame on me |
Good.
A suggestion also for you. You can make your edit, presave & save functions more generic, or even encapsulate them in an object, so you can reuse the same code for each of your fields Einladung, title etc. |
hi
thx 4 the tipp, (i wanted to make it with objects) but atm i don't realy understand the oop part :/ i can use it by copy & paste ( i'm doing it for my ajax prefix addon http://www.ragtek.org/tutorials/select.htm ) but one thing is just copy,paste and change the objects and the other thing is to realy understand it and to use it by own things:D |
All times are GMT. The time now is 02:26 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|