Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Community Member

How to retrieve user input and display on Cisco IPPhone ???

I recently try to modify the code of push2phone. I want the user to be able to not only type in the message but also type in the detail of the message. Once the user type I use Request.Form to retrieve that information. but how can I display that info on an IP phone using Cisco XML?? Help please

7 REPLIES

Re: How to retrieve user input and display on Cisco IPPhone ???

What do you mean by "detail of the message"? The title (the line on top)? The prompt (the line at the bottom above the softkeys)?

so you want to enter the title as well. So you modify push2phone to show you an additional textfield where you can plug in the title (keep in mind it needs to be 32 or less characters). Then when the push message is constructed:

var alertXML = "00";

alertXML += "133652";

alertXML += "" + cipmergedata(alertCIP, mergemode) + "";

alertXML += "Detail" + thiswebdir + "alertdetail.xml";

alertXML += "1";

alertXML += "ExitSoftKey:Exit";

alertXML += "3";

alertXML += "";

after

You'll add

" + yourTitleVariable + "

Community Member

Re: How to retrieve user input and display on Cisco IPPhone ???

In your code, the fourth line, u see alertdetail.xml. This file contain the detail of the message. I dont want the user have to open up the file and change the contain every time they want to send out a message. I want more user interface where user can type the message and there is another box with the user can write the detail of that message instead of going into the file alertdetail.xml and change the contain of it

Community Member

Re: How to retrieve user input and display on Cisco IPPhone ???

In your code, the fourth line, u see alertdetail.xml. This file contain the detail of the message. I dont want the user have to open up the file and change the contain every time they want to send out a message. I want more user interface where user can type the message and there is another box with the user can write the detail of that message instead of going into the file alertdetail.xml and change the contain of it

Re: How to retrieve user input and display on Cisco IPPhone ???

So create another ASP page which returns the desired CiscoIPPhoneText instead of linking to the static XML file.

XML on the phone is not really different from HTML on your webbrowser.. you query an URL and the server generates a response. That response can be a static html page (or an xml file for IP phones), or something dynamically generated (e.g. an ASP page).. and just like HTML pages, XML documents for IP phones can contain links to other dynamically generated pages.

Community Member

Re: How to retrieve user input and display on Cisco IPPhone ???

Hey Stephane. Thank you so much for all your response. It help a lot. Here is what I got sofar. I was thinking that if I write code to modify the file alertdetail.xml then that would fix all the problems. But JavaScript does not support write file so I have to look in VB. It mean that I have to redirect into a different ASP file that now write in VB. Found a piece of VB code that do that, but the problem is I lost all the info that the user types in from the previous page like the message and the host name of the device(Start with "SEP"). So wasnt a good idea. Now go back to your advice, I think it really cool but have no idea where to start. U might point out some direction for me to go. I am very new in script language. Once again. Thank you very much

Community Member

Re: How to retrieve user input and display on Cisco IPPhone ???

Intuitively, wouldn't it make more sense to just send a object with a prompt variable for your message instead of sending the alertdetail.xml within a ciscoipphoneimage object? This way you do not need to call an extra xml file (or create one for that matter) and can get your message across. This is provided the ciscoipphonemenu object can be used in place of the other. I have not tried this, but seems feasible.

Re: How to retrieve user input and display on Cisco IPPhone ???

I honestly don't know a lot about ASP pages since my work primarily consists of writing Java and C# code. But I'd search in google for something like "ASP primer" or "VBScript primer" or replace primer with getting started. It is really important that you're fluent in the programming language you're going to use before you delve into IP phone apps - you see a lot of people here who lack the proper background and that leads to awkward situations where those of us here who know how to program would like to run away screaming looking at the kinds of questions being asked.

Once you do get started with your chose language (and it mustn't be a language that you can use on an ASP page - if you know any kind of programming language I'd go into that direction, especially considering that you can forget about running your apps on the Callmanager itself in the future.. CCM 5 did away with that and I have my suspicious that Cisco will lock down even the Windows based CCM 6.x once its out.. and they most definitely will not run IIS anymore as there's no IIS on Linux)

Once you do get started with the language of your chosing, you'll quickly learn about such concepts as query strings, cookies and session variables which can be used to transfer information (like the name of the phone calling a page - SEP....) from one page to another.

133
Views
0
Helpful
7
Replies
CreatePlease to create content