User Profile
Collapse
-
How do I make the counter work. sorry dont know.... -
Hi Acoder
Sorry didn't reply earlier, I got caught up with some work. So I tried as you said and it has half done the job. I have this html page which has
and in the html page, in the same page I have PHP function which calls results...Code:<style type="text/css"> .color1 { background-color: azure; } .color2 { background-color: grey; } </style>Leave a comment:
-
Hello
I have fixed the problem. Found a very useful post from cmdr_skywalker on http://www.sqlteam.com/forums/post.asp?method =Reply&TOPIC_ID =67997&FORUM_ID =5
So I am relieved of the problem of removing special characters. Works fine both in IE and Firefox using Ajax. It was nothing wrong with Ajax calls, the data in the database table is wrongly formatted.
Could you please help me with the issue...Leave a comment:
-
Thanks Acoder. No this is not in another language. The data field is nvarchar set to 255 but the data is less than that. In the database table itself, it shows boxes instead. Eg. the table data should show :
main meals
but it shows main meals���������� ��������� �����...Leave a comment:
-
Well I opened the table in SQL Server 2005 and the table itself has square boxes after the text and the column width is 255. So if the text is 30 characters, the rest is all boxes. Just right click the table and click Open.
But when I run the query in query analyzer
It does not show any squares. I could not find the value of � or the question in black diamond character...Code:select * from table
Leave a comment:
-
When I run it without Ajax - In Firefox, it still shows question mark in black diamond. IE works fine - no unwanted characters.
But when using Ajax, IE does not show the results and stops executing queries any further. On the other hand, Firefox displays diamond symbol and continues to run rest of the code.
The datatype in database is also set to nvarchar so that should also not be a problem. I am using UTF-8 for all...Leave a comment:
-
May be if the application has a command line interface, you can pass arguments using a wshshell object or a batch file. You will be able to return the output of the command if you need.
You can do this in javascript or PHP. Just search for Wshshell for javascript.
I am fairly new to this so please give it a try and if it works please let me know.
Good Luck!...Leave a comment:
-
Sorry Guys
I am deviating from the issue I initially raised but getting correct results is more important then colouring rows alternatively. Kindly help.
I have managed to resolve general special characters like apostrophe but could not fix symbols like question in a black diamond.
The code I found on the internet is as follows:
http://www.atwebresult s.com/forum/viewtopic.php?p =346&sid=01c0ea 06fcb13eca154fb 9bb0b535d90...Leave a comment:
-
I found some matching problems with encoding and replacing using strtr function in PHP. But unluckily I could not find the ascii value for the question mark inside a black square. I dont know but when I tried to copy paste it here, I get this character � instead. Any idea what could be its value for me to remove this special character please?...Leave a comment:
-
Hi Acoder
Thanks for explaining. Regarding client side code. since I am using Ajax, all I have on client side is the CSS for color1 and color2. The code to display the table is on server side only - in the php page that im calling. so what i am doing is passing values from client side to server side in PHP through Ajax Get method. and then in PHP page, i have written a sql server query which is passing results to printQuery function......Leave a comment:
-
Hi Acoder
When I call this function,it runs fine and I get the table with values but im just trying to color the alternate rows. When I tried to apply the CSS and javascript function above, the rows took the color from color2 CSS which made me think that its not calculating the no. of row properly. Sorry didn't get the meaning of alternating classes. Let me know if I am not understanding please. Check the source code for what?
...Leave a comment:
-
alternate table row color
Hi,
I am happy to say that with your help, I have been performing good in Ajax. Thanks for helping me to start with. I have a small problem now. I am pulling records from database and passing result of the query in a table. I would like some help with the code to colour the alternate rows please.
[PHP]
function printQuery($par am)
{
echo "<table width=100% valign=center>" ;... -
Thank you Acoder. Your help is much appreciated :-)
I had a feeling I was missing something very basic.
Cheers....Leave a comment:
-
I have correct my error in code but still can't figure to get the value for the radio button. Anyone can let me know please?...Leave a comment:
-
Pass value of radio button using GET method in Ajax
Hi,
I am having a form which has a text box and 3 radio buttons. I am using GET method in Ajax to pass the value. I can pass the value of the textbox fine but how to pass the value of radio button?
I searched a few things on Google but I find the javascript below most useful in my case but there is some problem that my code is not running:
[CODE=javascript]
var test = document.getEle mentsByName("me al");... -
-
Thank you Acoder. Its working again. However, could you please help me out with some good links with examples which are a bit complex or recommend some books.
Well, this was a specific problem and I thought Ajax will process the pinging code everytime. That is what I understood from the term Ajax and readystate but not sure if I am reading the right content. Because I would like to study into detail. Also, if I have to do web programming...Leave a comment:
-
Important: This happens even if I refresh the page.
Though I added some extra code to display an image while the ping results are back to the client and a Clear button to empty the div contents.
[HTML]
<html>
<head>
<script>
function clearForm() //new function to clear the ping result div
{
document.getEle mentById("ping" ).innerHTML="";...Leave a comment:
-
Hi Again,
Thank you for the help last time. I have another question please. The above code works fine except one thing. If I click on Ping button, the first time, it shows the ping results after properly pinging the machine but if I click on Ping again, the pinging does not happen - as in it does not go to the PHP page which pings the machine. However it does show the last ping results.
Is it because there is a browser...Leave a comment:
-
Sorry my bad. It happens sometimes that when I do so many edits to one file, it does not get refreshed at all and keeps on showing me same old errors. So I deleted that file and pasted the same code in a new file and it works!
Thank you for your quick reply. Hope I will be able to do some scripting in Ajax from now since now I have my first program running. Its something new to learn :)...Leave a comment:
No activity results to display
Show More
Leave a comment: