Jump to content

Add ip log + send to a new page

Recommended Posts

What do you mean check and store the email that was removed from posting?  All you're doing is trying to list the records that are in a table.  Do you mean you want to skip records that have an email address that you blocked or something, so that existing posts in your database that were made with that email no longer appear?

Link to post
Share on other sites

And you want to validate the email, when, when you display existing posts?  Wouldn't it make more sense to do that when someone creates a post so that you don't allow them to create it in the first place?  I'm trying to figure out why you're doing anything at all on a page which displays data from the database instead of the pages that add the data to the database.

This is still aside from the fact that thee code you showed is not even getting the forum posts at all, it's only getting the email list and that's all.

Link to post
Share on other sites

Do it one step at a time in separate php page.

1)inserting email if it does not exist

Select query where email = email supplied, use count of rows, if greater than zero it exists, no need to add to email table.

Else INSERT query to add into email table.

2) validate block status use SELECT query to get blocked status of current email provided if true stop/end/terminate, else store, show whatever.

Edited by dsonesuk
Link to post
Share on other sites

I don't know what to do get the result. I thought that by having the code Select from email, using the the other option, what ever it is called now, I don't remember, on the previous page, https://www.w3schools.com/sql/func_mysql_isnull.asp

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...