WAP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreWAP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old November 28th, 2000, 06:31 AM
starvinmarvin starvinmarvin is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2000
Posts: 15 starvinmarvin User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Hi there,

Just wondering if anyone could enlighten me on a couple of things?

Basically I just want to know can you integrate PHP and WML? If so how? I tried a bit of PHP and it told me it was HTML. It seems the browser doesnt like the PHP extension. Tried a known good page with .php extension and it ****ed up too.

And I dont think it processes the php if you give it the wml extension (or am I wrong there?). Basically I'm tearing my hair out!

Any ideas guys (and gals)?

Cheers,


Ryan

Reply With Quote
  #2  
Old December 6th, 2000, 10:17 PM
preethven preethven is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2000
Posts: 7 preethven User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Havent worked with PHP, but if it is more or less the same as ASP, JSP or Cold Fusion, I suppose you would be required to place some line like the following:

ASP
<%Response.ContentType = "text/wnd.wap.wml"%>

JSP
<%response.setContentType("text/vnd.wap.wml");%>

Cold Fusion
<CFCONTENT type="text/vnd.wap.wml">

I guess there is an equivalent of that in PHP that you ight be missing out on?!?!? And then again maybe not?!?

Preetham

Reply With Quote
  #3  
Old December 11th, 2000, 10:19 AM
peterg's Avatar
peterg peterg is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2000
Location: Alton,Hampshire,UK
Posts: 40 peterg User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 9
It's not a problem. For an example, have a look at "Phonelist" in the clipscripts section here. I have found that it's more of a problem testing the stuff rather than writing it. I'll be posting another example soon, so watch this space.

Reply With Quote
  #4  
Old January 6th, 2001, 04:25 AM
bamse bamse is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 2 bamse User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
The following code snippet is for PHP:

header("Content-type: text/vnd.wap.wmlnn");

Reply With Quote
  #5  
Old January 12th, 2001, 03:04 PM
rsal rsal is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2000
Location: Winnipeg, Canada
Posts: 10 rsal User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Hi there,

You can do it, but it requires some playing around with your Apache httpd.conf file. Add the following to serve wap enabled pages(That also use php):

# MIME Types for WAP

# For PHP 4.x, use this:
AddType application/x-httpd-php .wml
# This parses php scripts within a .wml page

# For PHP 3.x, use this:
AddType application/x-httpd-php3 .wml

# For normal WML pages.
AddType text/vnd.wap.wml .wml

# For WML embedded graphics.
AddType image/vnd.wap.wbmp .wbmp

# End MIME Types for WAP

At the top of all your pages write this php code:

<?php
// send wml headers
header("Content-type: text/vnd.wap.wml");
echo "<?xml version="1.0"?>";
echo "<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN""
. " "http://www.wapforum.org/DTD/wml_1.1.xml">";
?>

Here is a code example using php:

<wml>
<card id="card1" title="Hello World!">
<p>
<?php
// format and output date
$the_date = date("M d Y");
print $the_date;
print "<br/>Welcome to a PHP-enabled site!";
?>
</p>
</card>
</wml>


Hope this helps!


Reply With Quote
  #6  
Old January 16th, 2001, 07:38 PM
Philip Olson Philip Olson is offline
loves google.
Dev Shed Novice (500 - 999 posts)
 
Join Date: Jan 2001
Location: Pacific Northwest
Posts: 645 Philip Olson User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Building WML Applications Using PHP :
-------------------------------------------------
http://www.zend.com/zend/tut/wap.php

WAP-Enabling a Website with PHP3 :
-------------------------------------------------
http://www.devshed.com/Server_Side/PHP/PHP_WAP/

WAP In Perspective :
-------------------------------------------------
http://phpbuilder.com/columns/markaw20001204.php3

Reply With Quote
  #7  
Old January 23rd, 2001, 06:59 PM
Philip Olson Philip Olson is offline
loves google.
Dev Shed Novice (500 - 999 posts)
 
Join Date: Jan 2001
Location: Pacific Northwest
Posts: 645 Philip Olson User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Another php/wml tutorial has been born, it lives here :

Introduction to WML, Apache, and PHP :
http://phpbuilder.com/columns/mike20010118.php3

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreWAP Programming > WML and PHP combined.. possible?


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

 Free IT White Papers!
 
Accelerating Trading Partner Performance
One in five. That's how many partner transactions have at least one error. That is an amazing statistic, particularly given the extraordinary leaps in innovation across the global supply chain during the past two decades. Download this white paper to learn more.

 
Competing on Analytics
This Tech Analysis is designed to help identify characteristics shared by analytics competitors, and includes information about 32 organizations that have made a commitment to quantitative, fact-based analysis.

 
Cost Effective Scaling with Virtualization and Coyote Point Systems
An overview of the industry trend toward virtualization, how server consolidation has increased the importance of application uptime and the steps being taken to integrate load balancing technology with virtualized servers.

 
Five Checkpoints to Implementing IP Telephony
Implementation planning for IP PBX software and IP telephony has become vital as businesses replace discontinued legacy PBX phone systems. This informative whitepaper outlines five "checkpoints" for any implementation plan that will help make IP communications a successful proposition.

 
Hosted Email Security: Staying Ahead of New Threats
In the last two years, email has become a fierce battleground between the nefarious forces of spam and malware, and the heroes of messaging protection. The spam volumes increased alarmingly every month, bringing clever new forms of phishing and virus propagation attacks.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway