Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> BB2Nuke
Author Message
thundarfoot
Regular
Regular


Joined: Jan 16, 2008
Posts: 75

PostPosted: Mon Feb 25, 2008 8:40 pm Reply with quote

I am use ing ravens 7.9
I want to create about 500 forum topics is there an easy way to just change a mysql table or something? I can click through the forum and manualy create but....would liek a time saver

thank you
 
View user's profile Send private message
kguske
Site Admin


Joined: Jun 04, 2004
Posts: 6383

PostPosted: Mon Feb 25, 2008 9:04 pm Reply with quote

Strange - RavenNuke is based on PHP-Nuke 7.6, and it's version hasn't passed 2.20.1 - did I miss something? Smile

Are you trying to convert these from another forum, or simply inserting 500 new forum topics? If you are converting, there may be scripts to help with that (see phpbb.com). If not converting, you might wish to look at the convert code to see how to generate the SQL to create the topic, first post, and associated tables. Unfortunately, it isn't just one table.

_________________
I google, therefore I exist...
Only registered users can see links on this board! Get registered or login!
 
View user's profile Send private message
thundarfoot
PostPosted: Mon Feb 25, 2008 9:29 pm Reply with quote

Lol
Just inserting new topics...
 
kguske
PostPosted: Mon Feb 25, 2008 10:26 pm Reply with quote

Look at includes/functions_post.php, specifically at function submit_post (after it calls prepare_post).

It inserts records into these tables:
nuke_bbtopics
nuke_bbposts
nuke_bbposts_text

It's called from modules/Forums/posting.php, so you can see which parameters are used and how. Also, after submit_post, it executes additional functions:
update_post_stats
user_notification

As you can see, it isn't trivial. If you want to use the function to generate the records from a script, remember that determining the correct files to include can be quite a challenge. It might be easier to figure out what the SQL is doing and go from there.
 
Gremmie
Former Moderator in Good Standing


Joined: Apr 06, 2006
Posts: 2415
Location: Iowa, USA

PostPosted: Tue Feb 26, 2008 8:52 am Reply with quote

Here is an easy way to create 500+ forum topics. Change the permissions on your forums so that anyone can post. Come back in about a week.

_________________
Only registered users can see links on this board! Get registered or login! - An Event Calendar for PHP-Nuke
Only registered users can see links on this board! Get registered or login! - A Google Maps Nuke Module 
View user's profile Send private message
Gremmie
PostPosted: Tue Feb 26, 2008 8:54 am Reply with quote

But seriously, if you are using RavenNuke, turn on that awesome new logging feature. Then create a post manually. Then go check the log and you'll see all the SQL that happened. Put that in a script and loop over it 500 times. Smile
 
kguske
PostPosted: Tue Feb 26, 2008 11:30 am Reply with quote

Nice...
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> BB2Nuke

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©