Jump to content

Help with my admin script please


Spock

Recommended Posts

Hey, in a nutshell the only thing in admin.php is the ability to moderate unapproved images, however, once approved, the "Approve    Delete" links are still on screen.

How it works is a user uploads an image, the filename is added to mysql and the image is added to uploads/  once I Approve an image, the image is then moved to img/ to display on the index.php (to prevent porn and anything that doesn't belong to the general public).

 

I know what's happening, because I've got while loops to display the image while looping through the mysql database, so once the image is moved, the links are still on screen, displaying an "Approve  Delete" for every image in the database.  Also another thing that happens is the images on index.php are blank until approved.  How can I work around this?

 

Here is the index.php when an image hasn't been approved:

http://www.xodiac.net/1.png

 

And here is the admin.php displaying Approve and Delete once an image has been approved:

http://www.xodiac.net/2.png

Link to comment
https://forums.phpfreaks.com/topic/230623-help-with-my-admin-script-please/
Share on other sites

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.