|
JonCox wrote: sqlInsert="INSERT INTO tblMessages(date,time,message) VALUES(newDate,newTime,newMessage)"
I think this is wrong
Why do you keep on adding this & "" in Response.Write??
The best way is that you should wait until you get the IIS back..
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
"Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
|
|
|
|
|
thanks for the reply.....
i will revist the code, but i will get iis back on friday, so maybe this will help
|
|
|
|
|
hello i am using this
[code]
function counttxt()
{
var txtarea = document.getElementsByTagName("textarea")[0];
var len = txtarea.length;
if(len>500)
{
textarea.value = textarea.value.substring(0,500);
}
}
[/code]
sanjeev
|
|
|
|
|
function textCounter(maxlimit)
{
var field = document.getElementById(fieldId);
if (field.value.length >= maxlimit) // if too long...trim it!
{
field.value = field.value.substring(0, maxlimit);
event.keyCode = 0;
}
event.cancelBubble = true;
}
Hardik Panchal
|
|
|
|
|
I am working on online Dictionary project. Authorized people will work on it to submit word data. The data will be posted by filling a form for one word at a time.
The architecture that I designed for it based on AJAX. Submitter will submit the form then he will get update information about his progress.
Any how, the main problem is to submit a form. So I found the technique as under:
var params = getParam();
xmlHttp.open("POST", "scripts/insertwords.php", true);<br />
http.setRequestHeader("Content-type", "application/x-www-form-urlencoded");<br />
http.setRequestHeader("Content-length", params.length);<br />
http.setRequestHeader("Connection", "close");<br />
xmlHttp.send(params);
Now I have to implement getParam() function. How can I extract form elements along with their name and their values in such manner as ?word=apple&meaning=a fruit&example=I ate apple .
OR
Tell me any alternate way to do the same thing.
Thanks in advance....
Shoaib Nawaz
|
|
|
|
|
Try like that..
function getParam(){<br />
var querystring = "?";<br />
<br />
querystring += "word=" + document.getElementById('txtWord').value;<br />
querystring += "&";<br />
querystring += "meaning=" + document.getElementById('txtMeaning').value;<br />
querystring += "&";<br />
querystring += "example=" + document.getElementById('txtExample').value;<br />
<br />
return querystring;<br />
}<br />
Hope it helps..
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
"Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
|
|
|
|
|
He should also pass the values through encodeURIComponent() before appending them to the querystring.
---- ...the wind blows over it and it is gone, and its place remembers it no more...
|
|
|
|
|
Yeah. I forget that. thanks.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
"Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
|
|
|
|
|
can I do it as?
A word can have more than one meanings. So I insert elements dynamically according to the user.
I want to access them using like this
function getParam()<br />
{<br />
var querystring = "?";<br />
for(element in document.formname.elements)<br />
{<br />
querystring = querystring + element.name + "=" + element.value + "&";<br />
}<br />
return querystring;<br />
<br />
}
Shoaib Nawaz
|
|
|
|
|
As I don't know how many HTML elements exist in your page, I can't say that..
If you are sure that you want all values from all elements of your page then you can do it.. but if you do like my example, you won't miss anything....
So, I recommend you to do that.. you can try at your own risk.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
"Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
|
|
|
|
|
|
I have a question regarding calling web services from client side. You see the company I work for hosts sites in every version of asp - asp.net, and we have to work on a just about all of them. This makes something simple like sending form data to an email address a little bit of a pain. For /Net 2.0 I always use the System.Net.Mail Namespace, for 1.0/1.1 we have some 3rd party dll, and for classic asp we have some dinosaur code that is creating a COM object that seems to break all the time.
Now that I have used them all great, but for newer developers here it’s a pain... I won’t lie... It’s a pain for me too.
That’s when I thought, hey, why not build a web service and call it with JavaScript, then we could call it from any site with the same script. There is one problem with that though. It seems you have to use an XmlHTTPRequest which will not work cross domain. The thing is, in this case I really don’t care if it’s all, asynchronous and fancy. I just want it to work reliably.
Does anyone know a better cross platform solution?
Thanks,
-Adam N. Thompson
|
|
|
|
|
AdamNThompson wrote: Does anyone know a better cross platform solution?
Well, here's what i've done: code up a simple app that'll accept POST requests and do something useful with them. Then POST to it from whatever needs it. And FWIW, even classic ASP can use ServerXMLHTTPRequest to do cross-domain requests server-side.
---- ...the wind blows over it and it is gone, and its place remembers it no more...
|
|
|
|
|
Hi,
I have a problem for 2 days already when accessing my asp.net page that has an image(jpg). Why is it when I access one of the pages that I made the image(jpg) doesn't show up? But when accessing it thru another pc the image will display. I only have Avast anti-virus which I know this doesn't affect the image problem, unlike in Symantec Anti virus it has so many things to block and unblock.
What do you think is the problem why does the image(jpg) in of my pages doesn't show up in some of the pc using IE, Firefox, Safari and Opera. Or is there a need to add somewhere in my asp.net source code?
Thanks
hifiger2004
|
|
|
|
|
Do you have an adblocker running on some of the browsers?
|
|
|
|
|
I temporarily removed my anti-virus and turning off the browser's pop-up blocker, but still no luck
hifiger2004
|
|
|
|
|
Hi Johnny,
I solved it already. It's a very basic thing and my mind fly so high already hehe. You know what is the problem, it is because of the Image folder restriction.
Anyway thanks for the suggestion about the adblocker. I actually looking on that issue also as well as my anti-virus.
Thanks
hifiger2004
|
|
|
|
|
i hope that the problem is with ur browser expecially with ur pop-up.When pop-up get blocked possibility of images being displayed is less.Try changing the setting in the browser and proceed.Good LUck
|
|
|
|
|
Hi,
How i can do for stying in same page whem an user click in forward button in him browser.
Tanks
|
|
|
|
|
Don't cache any of your page.. then, there won't be no "back" button or "forward" button.. This is the easiest way to do.. If you are good in Javascript, you can take a look at Javascript Library about how to trick the "Back" button or "Forward" button..
Hope it helps.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
"Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
|
|
|
|
|
Follow these three steps (in order!):
- Write your own browser (complete with a forward button).
- Don't attach the button to any code that would actually do anything.
- Force all potential users of your website to use your browser.
...or, you know, try one of those dodgy javascript hacks. You know, the ones that have turned The Web into a minefield of unusable sites? If you like being responsible for unusable sites, that is...
---- ...the wind blows over it and it is gone, and its place remembers it no more...
|
|
|
|
|
After publishing my website, when I am trying to run my published application from IIS I am getting the following error..
"unrecognized configuration section 'connection strings'"
in web.config file.
how to resolve this problem ? plzzz I need ur help in this regard.
thank u all,
kiran
|
|
|
|
|
It is most likely that the virtual directory in which the website is contained is configured for ASP.NET 1.1. Try changing it to 2.0 .
|
|
|
|
|
Can anyone recommend a good, brief, introduction to OO in JS available on the web? I'm asking here instead of Google because I'd like to know that somebody has read and benefited from a resouce before dedicating precious time to it.
Calling all South African developers! Your participation in this local dev community will be mutually beneficial, to you and us.
|
|
|
|
|