Search found 8 matches

by momoweeb
Sat Oct 20, 2012 11:32 am
Forum: Tutorials
Topic: PHP Tutorial: Blog (Including Commenting) [part 04]
Replies: 6
Views: 1362

Re: PHP Tutorial: Blog (Including Commenting) [part 04]

I get a blank page when I run the blog_list.php now. Should I be moving forward and write the rest of the codes? I reckon the syntax error still exists but I just beat the hell out of it with the die function :) right? Blank page does mean syntax error so carrying on will probably get you nowhere. ...
by momoweeb
Fri Oct 19, 2012 3:06 am
Forum: Tutorials
Topic: Problem re the blog tutorial - PHP warning
Replies: 5
Views: 1933

Re: Problem re the blog tutorial - PHP warning

ExtremeGaming wrote:Make sure there are no spaces before the <?php tag and after the ?> tag
Thanks. No there is no space before and after the tags.
by momoweeb
Thu Oct 18, 2012 1:30 pm
Forum: Tutorials
Topic: Problem re the blog tutorial - PHP warning
Replies: 5
Views: 1933

Re: Problem re the blog tutorial - PHP warning

Make sure that header() is above any output. Eg, don't have HTML content (or text) before header(). EDIT: I have suspicions with the MySQL query on line 69 of posts.inc.php. Change that line to: $sql_query_addpost = mysql_query("INSERT INTO `posts` (`post_user`, `post_title`, `post_body`, `pos...
by momoweeb
Thu Oct 18, 2012 5:18 am
Forum: Tutorials
Topic: Problem re the blog tutorial - PHP warning
Replies: 5
Views: 1933

Problem re the blog tutorial - PHP warning

Hi guys, I just finished the blog tutorials. Apparently everything is working, but when I submit a post on the blog_post.php page, I get this error (even tho the post will be appeared on the blog_list page ). Warning: Cannot modify header information - headers already sent by ( output started at /ho...
by momoweeb
Mon Oct 15, 2012 4:00 pm
Forum: Tutorials
Topic: PHP Tutorial: Blog (Including Commenting) [part 04]
Replies: 6
Views: 1362

Re: PHP Tutorial: Blog (Including Commenting) [part 04]

I get a blank page when I run the blog_list.php now. Should I be moving forward and write the rest of the codes? I reckon the syntax error still exists but I just beat the hell out of it with the die function :) right?
by momoweeb
Mon Oct 15, 2012 6:53 am
Forum: Tutorials
Topic: PHP Tutorial: Blog (Including Commenting) [part 04]
Replies: 6
Views: 1362

Re: PHP Tutorial: Blog (Including Commenting) [part 04]

Thanks mate but still get the same error. Do I need to change all use the backticks to the single-quotes? //Check if the given post ID is in the table function valid_pid($pid){ $pid = (int)$pid; $total = mysql_query ("SELECT COUNT(`post_id`) FROM `posts` WHERE `post_id`= {$pid}"); $total =...
by momoweeb
Mon Oct 15, 2012 6:03 am
Forum: Tutorials
Topic: PHP Tutorial: Blog (Including Commenting) [part 04]
Replies: 6
Views: 1362

PHP Tutorial: Blog (Including Commenting) [part 04]

Hi there, I am half way thro the blog video tutorials (part 04) and I get an error when I run the blog_list.php page. Here is the Error message I get on the blog_list.php page: Warning: mysql_fetch_assoc() expects parameter 1 to be resource, boolean given in /home/weebcoma/public_html/blog/func/inc/...
by momoweeb
Mon Oct 15, 2012 5:25 am
Forum: Tutorials
Topic: PHP Tutorial: Blog(Including commenting)
Replies: 2
Views: 793

PHP Tutorial: Blog(Including commenting)

Hi, I am facing with the same problem. I ran the code in the myPHPadmin and got this message: ERROR SQL query: FUNCTION valid_pid($pid) { $pid = ( INT ) $pid; MySQL said: #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax...