Mysidia Adoptables Support Forum

Mysidia Adoptables Support Forum (http://www.mysidiaadoptables.com/forum/index.php)
-   Addons/Mods Graveyard (http://www.mysidiaadoptables.com/forum/forumdisplay.php?f=41)
-   -   Adopts News (http://www.mysidiaadoptables.com/forum/showthread.php?t=881)

Bloodrun 06-02-2009 12:58 PM

RE: Adopts News
 
Quote:

Originally Posted by Saphira
IDIDITIDIDITIDIDIT!

PHP Code:

// Find highest answer number.
$query "SELECT MAX(nid) AS Max_nid FROM ".$prefix."news";
$result mysql_query($query);

    
$Max_nid=@mysql_result($result,"Max_nid");

// add + 1 to highest answer number and keep it in variable name "$Max_id". if there no answer yet set it = 1
if ($result) {
$Max_idd $Max_nid+1;
}
else {
$Max_idd 1;
}


$topic $_POST['topic'];
$topic secure($topic);
$detail $_POST['detail'];
$deatil secure($detail);
$name $_POST['name'];
$name secure($name);
$datetime date('d/m/y h:i:s');
$datetime secure($datetime); //create date time

$topic addslashes($topic);
$detail addslashes($detail);

    
$query "INSERT INTO ".$prefix."news(topic, detail, name, nid, datetime) VALUES('".$topic."', '".$detail."', '".$name."', '".$Max_idd."', '".$datetime."')";
    
$result mysql_query($query); 

I'm like, so happy right now. :P I was getting sick of writing "I'm testing using apostrophes." lol.

WHO'S THE MAN!

What did you do?

Quote:

Originally Posted by Saphira
I am male. Saphira is the name of my favourite fictional character of all time. She's the beautiful dragon from Eragon/Eldest/Brisingr. =P

o.0 Boy was I wrong.

Saphira 06-02-2009 03:36 PM

RE: Adopts News
 
Quote:

Originally Posted by Bloodrun
What did you do?

PHP Code:

$topic addslashes($topic);
$detail addslashes($detail); 

in add_reply.php

Bloodrun 06-02-2009 05:52 PM

RE: Adopts News
 
Quote:

Originally Posted by Saphira
Quote:

Originally Posted by Bloodrun
What did you do?

PHP Code:

$topic addslashes($topic);
$detail addslashes($detail); 

in add_reply.php

Ahh very well.

Saphira 06-04-2009 04:08 PM

RE: Adopts News
 
Okay, last step that I'm struggling on to get this perfected. I want the users in user group 6 to be able to delete news as well as admins, so if they mess up when they post, they don't have to wait for me to come online to delete it. I've tried 5 or 6 different things to get this to work, and nothing has yet. :S Any help? =^.^=

Bloodrun 06-04-2009 08:35 PM

RE: Adopts News
 
Quote:

Originally Posted by Saphira
Okay, last step that I'm struggling on to get this perfected. I want the users in user group 6 to be able to delete news as well as admins, so if they mess up when they post, they don't have to wait for me to come online to delete it. I've tried 5 or 6 different things to get this to work, and nothing has yet. :S Any help? =^.^=

I have to warn you about this, if you give them the option, that means all the responses will be lost as well.

Doing this will require a new page, and it will also require that you not only delete the news part, but the replies as well.

zhiichiro 06-09-2009 02:36 AM

RE: Adopts News
 
on the site_news.php, i click the add_news.php. i try to post a news, but when i try to add news, it's ERROR..

i also try the add_reply.php but it says error, contact administrator (bloodrun)


i just uploaded the files on the file manager of my site.. where the other php's are..

Bloodrun 06-09-2009 09:21 AM

RE: Adopts News
 
Well what error are you getting?
Did you follow the instructions step by step?
Did you tinker with the files?
Are you sure your MySql tables are in the correct database?

zhiichiro 06-09-2009 10:37 PM

RE: Adopts News
 
i just follow what you said on your first post. and i didnt do anything more.

about the error.. it simply says "ERROR" on mysite/add_news.php

zhiichiro 06-15-2009 12:19 PM

RE: Adopts News
 
i did it!yeay, this is cool!!

btw, is it possible to add new mod that is like this, but nut news, i want to make 1 for "games"

Bloodrun 06-15-2009 04:07 PM

RE: Adopts News
 
Quote:

Originally Posted by zhiichiro
i did it!yeay, this is cool!!

btw, is it possible to add new mod that is like this, but nut news, i want to make 1 for "games"

Um, just make a news report about games..


All times are GMT -5. The time now is 11:25 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.