PDA

View Full Version : vbadvanced news module and gars review problem


DJD
10-28-2008, 08:17 AM
Hello there.

I am experiencing an issue with the news module in the forum that gars is installed. I have two news forums both working with gars template. In the one that we do multipage reviews with the [break] tag in the frontpage we get a random page from the review and not the first one. Morgan from Gars was kind enough to explain this to me:

Untested, but the following should remove the break tags, though you'll need to look at the vBa code for where to place the line as I'm not familiar with vBa code:

$post_text = preg_replace('#\[\/?break.*\]#iU', '', $post_text);

you will probably need to change $post_text to whatever variable name is used by vBa.

but i have no idea how to use this information. Can you help please?

Thanks in advance :)

Brian
10-28-2008, 01:13 PM
Try looking for this line in your modules/news.php file:
$newscount++;


And add this right below:
$news['pagetext'] = preg_replace('#\[\/?break.*\]#iU', '', $news['pagetext']);

You will probably have to disable the 'Use Post Cache' setting for the news module as well.

Our Sponsors
 

DJD
10-29-2008, 03:58 AM
Thank you! That solved the problem. What is the downside of not using post cache?

Brian
10-29-2008, 10:07 AM
It can cause a little more strain on the server since it's always having to parse the BB code. Shouldn't be a big deal in most cases though.

Our Sponsors
 

DJD
10-29-2008, 02:01 PM
Thanks again :)