Solved

WAP & Oracle database

Posted on 2004-09-05
10
609 Views
Last Modified: 2013-12-27
So here's the problem, I'm on a project where we're about to create a Java application which is going to use a Oracle database. We also want the database to be accessible through WAP.

We've been able to make ourselves a Login page.
<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">

<wml>
<card title="Login">

<p>
Username: <input name="Username" size="15"/><br/>
Password:  <input name="Password" size="15"/><br/>
</p>

</card>
</wml>

Now we want this is where the database comes in. Checking username and password up against previously added records.
How do we do that?

Any help appreciated,
eX.
0
Comment
Question by:Gaute Rønningen
10 Comments
 

Author Comment

by:Gaute Rønningen
ID: 11989472
Did a little research. We gotta use WMLScript, but neither of us know the WMLScript language and how it operates. Any tutorials on how one is to check input values up against an oracle database?
0
 
LVL 23

Expert Comment

by:rama_krishna580
ID: 12072557
Hi,

look at here..
http://doug.burns.tripod.com/wap.html
http://nds1.forum.nokia.com/nnds/ ForumDownloadServlet?id=4016&name=Oracle_mobile_WP_en.pdf

i hope it may help you//

R.K
0
 
LVL 6

Expert Comment

by:cwkhang
ID: 12255745
0
 
LVL 2

Expert Comment

by:virtue79
ID: 12457284
> Did a little research. We gotta use WMLScript, but neither of us know the WMLScript language and how it operates.

Some WMLScript tutorials can be found at:
http://www.developershome.com/wap/wmlscript/
http://www.w3schools.com/wmlscript/default.asp


It should be noted that WMLScript is a client-side scripting language. To check the username and password against the records in a database, I think you need to send the data back to the server first (Have a look here http://www.developershome.com/wap/wml/wmlSendingData.asp). Then use a server-side language like JSP to retrieve the record in the database and compare it with the user data.
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 2

Accepted Solution

by:
tomgallo earned 250 total points
ID: 12575103
WAP is like ordinary HTML

Here you got a Login example using JSP and WML:

<%
      response.setContentType("text/vnd.wap.wml");
      response.setIntHeader("Expire",-1);
      response.setHeader("Pragma","no-cache");
      response.setHeader("CacheControl","no-cache, must-revalidate");
%>
<%String sUrl=(String)request.getAttribute("wmsUrl");%>
<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">
<wml>
      <head>
            <meta forua="true" http-equiv="Cache-Control" content="max-age=0"/>
      </head>

      <card id="UserLogin">
            <onevent type="onenterforward">
                  <refresh>
                        <setvar name="user" value=""/>
                        <setvar name="password" value=""/>
                  </refresh>
            </onevent>
            
            <do type="accept" label="Sgte.">
                  <go href="#PasswordLogin"/>
            </do>
            <p align="left">
                  User: <input type="text" name="user" value="" format="N*" maxlength="10" emptyok="false"/>
            </p>
      </card>

      <card id="PasswordLogin">
            <do type="accept" label="Sgte.">
                  <go href="<%=sUrl%>" method="post">
                        <postfield name="event" value="makelogin"/>
                        <postfield name="user" value="$(user)"/>
                        <postfield name="password" value="$(password)"/>
                  </go>
            </do>

            <p align="left">
                  Password: <input name="password" type="password" value="" format="N*" maxlength="10" emptyok="false"/>
            </p>
      </card>
</wml>
0
 
LVL 2

Expert Comment

by:tomgallo
ID: 12575105
Another example here using only the cellphone number to login (always using JSP and WAP):

<%
      response.setContentType("text/vnd.wap.wml");
      response.setIntHeader("Expire",-1);
      response.setHeader("Pragma","no-cache");
      response.setHeader("CacheControl","no-cache, must-revalidate");
%>
<%String sUrl=(String)request.getAttribute("wmsUrl");%>
<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">
<wml>
      <head>
            <meta forua="true" http-equiv="Cache-Control" content="max-age=0"/>
      </head>
      <card id="PhoneLogin">
            <do type="accept" label="Sgte.">
                  <go href="<%=sUrl%>" method="post">
                        <postfield name="event" value="makeloginphone"/>
                        <postfield name="phone" value="$(phone)"/>
                  </go>
            </do>
            <p align="left">
                  Telefono: <input type="text" name="phone" value="" format="N*" maxlength="15" emptyok="false"/>
            </p>
      </card>
</wml>

Hope it helps.
-tom
0
 
LVL 2

Expert Comment

by:tomgallo
ID: 12575112
Sorry a correction on my first answer...
When I said: WAP is like ordinary HTML
I mean: WML is like ordinary HTML

WAP is a protocol (wireless application protocol).

-tom
0
 
LVL 2

Expert Comment

by:tomgallo
ID: 12822290
Vernabili,

I do not think that all answers have the same value this time...
I don't see that a split as the correct closing method in this question.

My answers are more specific and to the point that the others.

That is my point of view,
-tom

0
 

Author Comment

by:Gaute Rønningen
ID: 12827851
Sorry, didn't check EE for awhile...
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

MAC Filtering: MAC filtering is like handing a list of names to a doorman. If someone comes to the door and mentions a name, this name is checked by the doorman on his list and granted or denied access by this. This means that if someone menti…
In this article I will describe how to setup a Cisco WLC 5508 to work with Apple's Bonjour protocol across VLANs.  I will also discuss using screen mirroring and Airplay on an AppleTV v3.  This article covers the wireless network only and requires m…
This Micro Tutorial will show you how to maximize your wireless card to its maximum capability. This will be demonstrated using Intel(R) Centrino(R) Wireless-N 2230 wireless card on Windows 8 operating system.
Viewers will learn how to connect to a wireless network using the network security key. They will also learn how to access the IP address and DNS server for connections that must be done manually. After setting up a router, find the network security…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now