Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Server Development
Habbo Retros
Habbo Q&A
Wont insert correctly..
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="Grant" data-source="post: 32647" data-attributes="member: 391"><p>Ug, I've been messing around with a Housekeeping <em>(habbo retro)</em> that was released a while back; so yeah, I've just realised that Posting news doesn't work correctly. Just wondering if any of you may help me fix it.</p><p></p><p>Heres the code;</p><p>[PHP]<?php </p><p>if($assoc['rank'] <5)</p><p>{</p><p>exit;</p><p>}</p><p>$title = $_POST['title'];</p><p>$shortstory = $_POST['shortstory'];</p><p>$banner = $_POST['banner'];</p><p>$content = $_POST['content'];</p><p>$sent = $_POST['sent'];</p><p>if($sent != 'yes') {</p><p>;echo '</p><p><form name=\'postnews\' action=\'?page=news\' method=\'post\'></p><p></p><p> <alert></p><p> <develop>Creating news is currently broken!</develop></p><p> </p><p> <br></p><p> </p><p> Like some other features in this development build of Cores new housekeeping, Creating news is currently broken. If you would like an article</p><p> posted, then please contant an Administrator with Database access.</p><p> </p><p> <br><br></p><p> </p><p> Sorry for any inconvenience.</p><p> </alert></p><p> </p><p> <br></p><p> </p><p> <center></p><p> </p><p> <b>Title:</b><br></p><p> <input type=\'text\' name=\'title\' maxlength=\'20\'></p><p> <br></p><p> <b>Short Story:</b><br></p><p> <input type=\'text\' name=\'shortstory\' maxlength=\'50\'></p><p> <br></p><p> <b>Banner URL (click <a href="../Public/Images/news/" target="_BLANK">here</a>):</b><br></p><p> <input type=\'text\' name=\'banner\' maxlength=\'500\'></p><p> <br></p><p> <b>Full Story:</b><br></p><p> <textarea class="ckeditor" cols=30 rows=7 name=\'content\'></textarea></p><p> <br></p><p> <input type=\'submit\' value=\'Post\'></p><p></p><p><input type=\'hidden\' name=\'sent\' value=\'yes\'></p><p></form></p></p><p> </p><p> </p><p> </p><p> </p><p>';</p><p>}</p><p>else</p><p>{</p><p>$query = mysql_query("INSERT INTO cms_news (title, shortstory, longstory, author, published, image, campaign, campaignimg) VALUES ('".$title ."', '".$shortstory ."', '".$content ."', '1', '".time() ."', '".$banner ."', '0', '')");</p><p>echo "<center><h1>Article posted!</h1></center>";</p><p>;echo '</p><p></p><p>';</p><p>}</p><p>?>[/PHP]</p><p></p><p>So, when I attempt to post it, I get the "Article Posted", however it hasn't actually posted it. Why does it not work?</p><p></p><p><span style="font-size: 9px">Try to ignore my messy coding..</span></p></blockquote><p></p>
[QUOTE="Grant, post: 32647, member: 391"] Ug, I've been messing around with a Housekeeping [I](habbo retro)[/I] that was released a while back; so yeah, I've just realised that Posting news doesn't work correctly. Just wondering if any of you may help me fix it. Heres the code; [PHP]<?php if($assoc['rank'] <5) { exit; } $title = $_POST['title']; $shortstory = $_POST['shortstory']; $banner = $_POST['banner']; $content = $_POST['content']; $sent = $_POST['sent']; if($sent != 'yes') { ;echo ' <form name=\'postnews\' action=\'?page=news\' method=\'post\'> <alert> <develop>Creating news is currently broken!</develop> <br> Like some other features in this development build of Cores new housekeeping, Creating news is currently broken. If you would like an article posted, then please contant an Administrator with Database access. <br><br> Sorry for any inconvenience. </alert> <br> <center> <b>Title:</b><br> <input type=\'text\' name=\'title\' maxlength=\'20\'> <br> <b>Short Story:</b><br> <input type=\'text\' name=\'shortstory\' maxlength=\'50\'> <br> <b>Banner URL (click <a href="../Public/Images/news/" target="_BLANK">here</a>):</b><br> <input type=\'text\' name=\'banner\' maxlength=\'500\'> <br> <b>Full Story:</b><br> <textarea class="ckeditor" cols=30 rows=7 name=\'content\'></textarea> <br> <input type=\'submit\' value=\'Post\'> <input type=\'hidden\' name=\'sent\' value=\'yes\'> </form></p> '; } else { $query = mysql_query("INSERT INTO cms_news (title, shortstory, longstory, author, published, image, campaign, campaignimg) VALUES ('".$title ."', '".$shortstory ."', '".$content ."', '1', '".time() ."', '".$banner ."', '0', '')"); echo "<center><h1>Article posted!</h1></center>"; ;echo ' '; } ?>[/PHP] So, when I attempt to post it, I get the "Article Posted", however it hasn't actually posted it. Why does it not work? [SIZE="1"]Try to ignore my messy coding..[/SIZE] [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
Wont insert correctly..
Top