Jump to content

Where to look for this error


Brian W

Recommended Posts

I touched on this issue earlier but I was under the wrong impression. I thought it was something to do with my recordset and how I was using $_GET

Below is the structure of the site, you may want to skip to the subheader ISSUE IS

But, with stages of debugging I think I figured out where the problem is occurring. I have a repeat region that shows all of the groups of people (friends, family, acquaintances, ect.) friends=1, click the group friends and go to "group.php?Group=1" - that works

When you click on the link, it takes you to a new page with a repeat region of the names of the people. Each person has there own row. Within the row is a table that only shows if that row's unique key is equal to $_GET['ID'], in the table it shows there more complete details I have on them. Lucy's ID is 4; When you click her name it takes you to "group.php?Group=1&Person=4"- that works

Below, I have uploaded files related to the group. Each file has a row. When you click on the file name it opens the file in a new window (or downloads it, depends on file type.) - that mostly works

ISSUE IS

When I have selected any of those people and go to URL like "group.php?Group=2&Person=5" the repeat region stops showing all but the first file in the database. I would include the page's code, but it is massive. The FILE recordset is filtered by $_GET['Group'] (after it is stripped of any possible injections) and like I said, it works till I have Person= in play.

Where should I look for the problem, should I post any sections of my code??

Link to comment
https://forums.phpfreaks.com/topic/125547-where-to-look-for-this-error/
Share on other sites

Do you have a link so we can see what you mean?

 

I'm having trouble understanding what you mean when you say the repeat region stops showing all but the first file..

I'm guessing it's a loop that displays rows of records..

 

+Does it ever show all files?

 

+Have you checked your mysql query for it on something like PHPmyadmin to see if you get more than one result?

+Have you checked the loop logic for that section to make sure it's supposed to loop through all results?

 

+Have you turned on error_reporting(E_ALL) to see if you're getting any undefined vars that might be messing it up?

 

 

The best thing would be to check your queries against the database itself, not using php (if you can).  Then check your php logic...

 

Myself, I'd kinda have to see the page(s) in order to comprehend better.  The first question I put up there is important as well.

Sorry, I can't in good mind post the page. Sounds odd, but its not a group, people, details... it actually is a front end that is connecting to a few tables with private info on some people here in Arizona related to that god da,mdflj, *correct self* wonderful light rail system going in. lol

But yes, there is a time when all of the files are being displayed... when I don't have someone's details pulled up. The really odd thing is that my admin version of the page (which I'm neutering of all admin controls) works and I can't seem to figure out why one does and the other doesn't.

But any ways, I'm not sure what PHPmyadmin does, I'll look it up at work tomorrow. I just use firebug right now, but its not a specialty bug finder and its abilities with PHP seems limited in some ways. But can't beat free and built in to an excellent browser.

 

I'll also look into this "error_reporting(E_ALL)".

I greatly appreciate every ones input and help on this forum, it has made learning this language considerably easier than I thought it would be. Thank you.

Understandable if the content is privileged...

 

-If the admin version works, and it's not considerably different that the version you're trying to fix, try making a copy of admin and splicing in your version a little at a time to see what breaks it

-error_reporting(E_ALL) will display ALL php errors and notices, but probably won't tell you why it's not showing all rows.

-commonly, if it's feasible, redo the part that isn't working from step one... (save a copy of the 'broken but working' page prior !!)

 

-if problem persists, it may be easier to make a small copy of your tables with dummy data for us to see, and see code.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.