SunQuest
           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

Closed Thread
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:
1200+ fellow developers rate and compare features of the top IDEs, like Visual Studio, Eclipse, RAD, Delphi and others, across 13 categories. Enjoy this FREE Download of the IDE User Satisfaction Study by Evans Data Corporation. Download Now!
  #1  
Old January 25th, 2006, 09:29 PM
soultaker's Avatar
soultaker soultaker is offline
Permanently Banned
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2005
Posts: 54 soultaker User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 5 h 33 m 46 sec
Warnings Level: 20
Number of bans: 1
Reputation Power: 0
Exclamation MODERATOR ATTENTION PLEASE READ(Was: HELP!! with this code please?)

ok this is the script(s) for a forum i downloaded, it works fine on web but the wap side comes to a dead end as soon as i hit the post msg page. can you tell me what is wrong with these codes?

PHP Code:
<?php
include "config.php";
include 
"incl/wml.inc";
include 
"incl/ban.inc";

if(isset(
$name)||isset($title)||isset($text)){

$name=abc_only($name,0);
$title=abc_only($title,0);
$text=abc_only($text,0);

$name=remove_bad_words($name);
$title=remove_bad_words($title);
$text=remove_bad_words($text);

if(
strlen($name)<$flood[1]&&strlen($title)<$flood[2]&&strlen($text)<500&&$name!=''&&$title!=''&&$text!=''){

$desc=substr($text,0,90).'...';
include(
"incl/flood.inc");

$topic_id=date('YmdHis');
$entry="$current_time:|:$title:|:<img src=\"pics/w8.gif\" $size_img[1] alt=\"\" border=\"0\" hspace=\"2\" />$name:|:$text:|::|:$REMOTE_ADDR";
$file="$data/$topic_id";
save_file($file,$entry,0);
$fs=open_file($log);

if(isset(
$admin_mail)&&$admin_mail!='not_set_yet'){
$name=strip_tags($name);
$text=strip_tags($text);
$message="Subject: $title\nAuthor: $name\n\n$text";
mail($admin_mail,"Forum Notification",$message,"From: admin@$SERVER_NAME");}

$entry="$topic_id:|:$current_time:|:$title:|:$desc:|:<img src=\"pics/w8.gif\" $size_img[1] alt=\"\" border=\"0\" hspace=\"2\" />$name:|:1:|:0\n$fs";
save_file($log,$entry,0);

die(
"<card id=\"ok\" title=\"ok\"><onevent type=\"onenterforward\"><go href=\"wnd.php?f=$f&u=$random\" /></onevent><p><a href=\"wnd.php?f=$f&u=$random\">Forward...</a></p></card></wml>");
}}

print 
'<card id="new" title="New Topic">';
include 
"incl/wedt.inc";
?></card></wml>


and the incl file it startes is:
PHP Code:
<?php if(isset($members_only)&&$members_only==1){die('<p>forbidden...</p></card></wml>');}?>

<p>
Name: <input name="name" size="10" max="20" />
Subject: <input name="title" size"10" max="50" />
Message: <input name="text" size="10" max="500" />
</p>

<p>
<anchor>SEND
<go method="get" href="<?php print $PHP_SELF;?>">
<postfield name="name" value="$(name)" />
<postfield name="title" value="$(title)" />
<postfield name="text" value="$(text)" />
<postfield name="f" value="<?php print $f?>" />
<postfield name="u" value="<?php print $random?>" />
<?php if(isset($t)){print "<postfield name=\"t\" value=\"$t\" />";}?>
</go>
</anchor>
</p>

i viewed the source in winwap browser and the link is coming up with a blank address like href"" can you tell me why?


i thought this may help as i mentioned the view source earlier so here it is. please excuse the header i know its miles long.

Code:
HTTP/1.1 200 OKDate: Fri, 27 Jan 2006 00:12:59 GMTServer: Apache/2.0.55 (Win32) PHP/5.1.1X-Powered-By: PHP/5.1.1Expires: Mon, 26 Jul 1997 05:00:00 GMTLast-Modified: Fri, 27 Jan 2006 00:12:59 GMTCache-Control: no-cache, must-revalidatePragma: no-cacheContent-Length: 606Connection: closeContent-Type: text/vnd.wap.wml--[ HEADER END ]------
<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">
<wml>
  <card id="new" title="New Topic">
    <p>
      Name:
      <input name="name" size="10" max="20" />
      Subject:
      <input name="title" size"10" max="50" />
      Message:
      <input name="text" size="10" max="500" />
    </p>
    <p>
      <anchor>
        SEND
        <go method="get" href="" >
          <postfield name="name" value="$(name)" />
          <postfield name="title" value="$(title)" />
          <postfield name="text" value="$(text)" />
          <postfield name="f" value="0" />
          <postfield name="u" value="83479" />
        </go>
      </anchor>
    </p>
  </card>
</wml>

Last edited by soultaker : January 28th, 2006 at 09:25 PM. Reason: needs deleting

Reply With Quote
  #2  
Old January 27th, 2006, 07:40 AM
soultaker's Avatar
soultaker soultaker is offline
Permanently Banned
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2005
Posts: 54 soultaker User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 5 h 33 m 46 sec
Warnings Level: 20
Number of bans: 1
Reputation Power: 0
thanks jabba i tried to put the code in tags but with the dialog box it opened i could only paste one line at a time.

Reply With Quote
  #3  
Old January 28th, 2006, 09:24 PM
soultaker's Avatar
soultaker soultaker is offline
Permanently Banned
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2005
Posts: 54 soultaker User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 5 h 33 m 46 sec
Warnings Level: 20
Number of bans: 1
Reputation Power: 0
MODERATORS............ can you delete this post please...

the code is working fine, i had somebody test it on their server and it works fine its a problem with my setup and i cant figure it so this is no longer needed sorry for wasting
peoples time.

regards

Reply With Quote
  #4  
Old January 29th, 2006, 12:56 AM
jabba_29's Avatar
jabba_29 jabba_29 is offline
Back in HEL
Dev Shed God 8th Plane (8500 - 8999 posts)
 
Join Date: Feb 2002
Location: Finland
Posts: 8,670 jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)  Folding Points: 57777 Folding Title: Beginner FolderFolding Points: 57777 Folding Title: Beginner FolderFolding Points: 57777 Folding Title: Beginner Folder
Time spent in forums: 3 Months 3 Weeks 4 Days 6 h 10 m 50 sec
Reputation Power: 1618
Send a message via ICQ to jabba_29 Send a message via AIM to jabba_29 Send a message via MSN to jabba_29 Send a message via Yahoo to jabba_29 Send a message via Google Talk to jabba_29 Send a message via Skype to jabba_29
Facebook
We are not supposed to "delete" posts, but you or a I can lock this thread if you desire. If you want to post your solution with regards to your server settings, then feel free - may help people in the future.

Jamie
__________________
Cheers,

Jamie


# skiFFie | Home of the 'accessibility module' for Drupal
# Jamie Burns [me] Accessibility Module [drupal]
# guidelines | search | wap resources | not getting help | fold to cure

# Any form of employment is strictly prohibited ......


__________________

Let the might of your compassion arise to bring a quick end
to the flowing stream of the blood and tears .....
Please hear my anguished words of truth.

__________________

Reply With Quote
  #5  
Old January 31st, 2006, 07:21 AM
soultaker's Avatar
soultaker soultaker is offline
Permanently Banned
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2005
Posts: 54 soultaker User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 Day 5 h 33 m 46 sec
Warnings Level: 20
Number of bans: 1
Reputation Power: 0
Quote:
Originally Posted by jabba_29
We are not supposed to "delete" posts, but you or a I can lock this thread if you desire. If you want to post your solution with regards to your server settings, then feel free - may help people in the future.

Jamie


sadly i have not sorted my own server, im unsure as to why this forum does not work on my server, it was tested by a friend who got it working with no modifications to any scripts, the only thing that was dofferent between my own settings and my friends settings was in the php settings.

register_long_array in the php.ini needs to be set to on also also
register_globals needs to be on,

this forum is called eforum25 and is a very good forum on web and from what ive seen by viewing some online forums it isnt bad on wap either,

but other than that i cant give any more help on this.

Reply With Quote
  #6  
Old January 31st, 2006, 07:26 AM
jabba_29's Avatar
jabba_29 jabba_29 is offline
Back in HEL
Dev Shed God 8th Plane (8500 - 8999 posts)
 
Join Date: Feb 2002
Location: Finland
Posts: 8,670 jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)jabba_29 User rank is General 10th Grade (Above 100000 Reputation Level)  Folding Points: 57777 Folding Title: Beginner FolderFolding Points: 57777 Folding Title: Beginner FolderFolding Points: 57777 Folding Title: Beginner Folder
Time spent in forums: 3 Months 3 Weeks 4 Days 6 h 10 m 50 sec
Reputation Power: 1618
Send a message via ICQ to jabba_29 Send a message via AIM to jabba_29 Send a message via MSN to jabba_29 Send a message via Yahoo to jabba_29 Send a message via Google Talk to jabba_29 Send a message via Skype to jabba_29
Facebook
Thanks for the response. Perhaps even the ini_settings may help someone elseusing those forums.

Good luck.

Thread closed...

Jamie

Reply With Quote
Closed Thread

Viewing: Dev Shed ForumsProgramming Languages - MoreWAP Programming > form processing stops when run as wml(Was: HELP!! with this code please?)


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


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





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