PDA

View Full Version : Two outputs on one page?


AshG
10-23-2004, 06:27 PM
I'm trying to get something worked out as an interim solution while we work on porting to vBA. I haven't had any luck either making or finding a modification that will allow us to pull two separate sets of news in a separated format. I do have somewhat of a different solution that I'm trying but I'm running into a problem.

Since no one has been able to help with a hack or mod to pull news separately with one page, we've set up two different pages. This page (http://www.envynews.com/cmps_index.php?page=tworeviews) displays the two newest reviews or site news blurbs. The main page (http://www.envynews.com/cmps_index.php) displays affiliate and web news.

We tried successfully to include both outputs on one page. Unfortunately, a PHP problem resulted in deleting/reinstalling vBulletin and vBA and the output has not worked since.

The page we've experimented with (http://www.envynews.com/dev/cmpstest.php) doesn't seem to like what we're trying to do, eventhough it once worked. Here's the code we've tried:


<div align="center">
<? view ('zone:'.Ads_TopMiddle3, 0, '_blank', '', '0', $phpAds_context); ?>
<? view ('zone:'.Ads_TopMiddle4, 0, '_blank', '', '0', $phpAds_context); ?>
<? include("./cmps_index.php?page=tworeviews"); ?>
<? view ('zone:'.Ads_MiddleNews, 0, '_blank', '', '0', $phpAds_context); ?>
<? include("./cmps_index.php"); ?>
</div>


I know what the problem is (calling a page that starts with ?), but the fact that it worked once means it has to be able to work somehow. Is there any possible way to achieve what we're trying to do? Well, I know there is, but how to do it?

edit: I can't get the opening <div> to space like it should, but it is properly aligned in the code.

Brian
10-23-2004, 11:12 PM
I think I'm missing the point of what you're trying to do here... Are you just trying to have the news posts look different on the two pages, or something else?

And one obvious thing I see wrong with the code you posted...

<? include("./cmps_index.php?page=tworeviews"); ?>

You're not going to be able to include a page like that.

Our Sponsors
 

AshG
10-23-2004, 11:58 PM
Yeah, I figured the include wouldn't work.

What we're trying to do is have two separate news outputs on one page, with the center column ultimately looking like this:

Ad
Site News
Ad
Affiliate/Web News
Ad

with Site News pulling from one forum, and Affiliate/Web news pulling from another. Unfortunately, it's not coming as easily as we'd like.

edit: This (http://www.envynews.com/c.php) is close to what we're going for. Accidently deleted the right navbar while working with the code, but it offers some look at what we're trying to do. We're also going to strip the Yesterday's / Today's news dealio at the top and replace it with some kind of a news menu. But that comes after we get the above stuff figured out.

Brian
10-24-2004, 02:29 AM
Try this in your adv_portal_newsbits template:

<if condition="$pages == 'pagename'">
Special Template

<else />

Normal Template code here

</if>

Our Sponsors
 

Matthyahuw
10-24-2004, 08:20 PM
Hey Brian, thanks for the help working with us in this 'unconventional' manner.

what we're basically trying to do is 'sticky' our news at the top, and since I haven't found out how to do that, this is what we came up with...

I'm not entirely sure how you meant for us to use the code you provided. did you want us to put our two nes pages in the template for it to be exported? We're not hacking the newsbits template (at least not yet), so I'm a bit confused as to what you meant...

Thanks again for your time...

Matthyahuw
10-26-2004, 07:22 AM
Hey Brian, don't worry about it, we're scrappin this idea as it's gettin nowhere, we're just gonna go the whole vBa/CMPS deal...thx again for your time...