What I am upto: I am tryin' to develop a Blog CMS. There is a Database named blog in which there's a table named posts. The posts table has these fields: post_id, post_title, post_url, post_time, post_category, post_desc, post_username. Here, post_username is the username of the user who posted this post. Now, What I want to do is: I want to Generate a list of posts submitted by a user on his profile page using PHP and MySQL. And the Question: How Should I do it?
There must be 10 posts on a page with post_title, post_category and post_desc.
AbhishekBiswal
0
Newbie Poster
Recommended Answers
Jump to PostWell, I don't know about your table data, but if you want to show 10 links for a user, your logic is wrong.
mysql_fetch_array
only returns a single record, not all of them, so$post_url[$times]
is empty.
Jump to PostHere i have added 2 lines is begining to check error
I have commented if check=0 to see whether result comes or not
try following code<?php error_reporting(E_ALL); ini_set("display_errors", 1); // Before this, I have connected to the database (succesful) and has selected the database too. $checkrow_query …
All 5 Replies
pritaeas
2,194
¯\_(ツ)_/¯
Moderator
Featured Poster
AbhishekBiswal
0
Newbie Poster
pritaeas
2,194
¯\_(ツ)_/¯
Moderator
Featured Poster
AbhishekBiswal
0
Newbie Poster
urtrivedi
276
Nearly a Posting Virtuoso
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.