Go Back   Pligg Forum > Pligg Development > Pligg Mods
Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 06-20-2006, 08:28 AM
londoncowgirl londoncowgirl is offline
New Pligger
 
Join Date: Jun 2006
Posts: 5
Downloads: 0
Uploads: 0
Thanks: 0
Thanked 0 Times in 0 Posts
open link in framed page

I'm a newbie to php, tpl and the such...so forgive me if this is a silly question.

I'd like to have the story link open in a framed page, similiar to this site:

http://www.shoutwire.com/

When users click on the story link, it displays in a page with two frames. The story displays below and my site details above.

Has anyone done this? Or can anyone give me some guidance on how to go about this?

Cheers!
cx
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 06-21-2006, 04:11 AM
savant's Avatar
savant savant is offline
Pligg Koder
 
Join Date: Apr 2006
Location: UK
Posts: 1,234
Downloads: 7
Uploads: 0
Thanks: 66
Thanked 210 Times in 151 Posts
first design the framed page in html

since the page you want, it will be similar to the story.php

so make a copy of story.php to framestory.php
then find the story.tpl and copy into framestory.tpl

as the data is already included, just add the data where you want it in the frame.
and it should work

so first work on the layout of the frame.
Reply With Quote
  #3 (permalink)  
Old 06-21-2006, 06:28 AM
londoncowgirl londoncowgirl is offline
New Pligger
 
Join Date: Jun 2006
Posts: 5
Downloads: 0
Uploads: 0
Thanks: 0
Thanked 0 Times in 0 Posts
Thank you Savant. I'll give it a go and post my results for others who are looking to do the same thing.
Reply With Quote
  #4 (permalink)  
Old 06-21-2006, 07:47 AM
londoncowgirl londoncowgirl is offline
New Pligger
 
Join Date: Jun 2006
Posts: 5
Downloads: 0
Uploads: 0
Thanks: 0
Thanked 0 Times in 0 Posts
I'm unclear how I can link my new frame page to my site. (sorry - newbie!)

I created my framed page (copied the story.php and story.tpl filed and renamed to framestory). This is the page that will be displayed at the top of my frame.

I can send the link url to the main section of the frame.

Now I just don't know how to tie it to my site. How can I add my new frame page to my pligg so that the system recognises it?

cheers!
Reply With Quote
  #5 (permalink)  
Old 06-21-2006, 08:04 AM
savant's Avatar
savant savant is offline
Pligg Koder
 
Join Date: Apr 2006
Location: UK
Posts: 1,234
Downloads: 7
Uploads: 0
Thanks: 66
Thanked 210 Times in 151 Posts
if you look at

/lib/html1.php

and check out getmyurl()

all the ones with story goes to story.php
now if you want the user to go to your frame when clicking on the main page.

just change the story.php to framestory.php
Reply With Quote
  #6 (permalink)  
Old 06-21-2006, 09:12 AM
londoncowgirl londoncowgirl is offline
New Pligger
 
Join Date: Jun 2006
Posts: 5
Downloads: 0
Uploads: 0
Thanks: 0
Thanked 0 Times in 0 Posts
Thanks for your quick reply. I feel like a fool keep asking how to do this... sorry!

I can't get my frame page sorted out. I know I was my 'framestory.tpl' to appear in the top and the $url in the main frame. But somehow it just won't go.

This is my frame.php file:

Code:
<HTML>
<HEAD>MySite.com // <?php echo $title; ?></HEAD>
<FRAMESET FRAMEBORDER="0" ROWS="<?php echo $SETUP[height]; ?>,*">
<FRAME SRC="framestory.tpl" SCROLLING="NO">
<FRAME SRC="<?php echo $url; ?>">
<NOFRAMES>
<BODY>
Viewing this page requires a browser capable of displaying frames.
</BODY>
</NOFRAMES>
</FRAMESET>
</HTML>
Where am I going wrong? I just can't get my head around this frame business.

cheers!!
Reply With Quote
  #7 (permalink)  
Old 06-21-2006, 10:48 AM
savant's Avatar
savant savant is offline
Pligg Koder
 
Join Date: Apr 2006
Location: UK
Posts: 1,234
Downloads: 7
Uploads: 0
Thanks: 66
Thanked 210 Times in 151 Posts
i should have looked at the example you gave me (the source code)

looks like you'll need four files.

framemain.php : this will simplay display framemain.tpl and tell the frame the story ID.
What you've done is make the framemain.tpl

the first frame will point to frameheader.php?story_id=3263

frameheader.php : this is similar to story.php. It will show the vote box, and the story title.

I'll try this out tomorrow when i have some free time
Reply With Quote
  #8 (permalink)  
Old 06-22-2006, 04:41 AM
londoncowgirl londoncowgirl is offline
New Pligger
 
Join Date: Jun 2006
Posts: 5
Downloads: 0
Uploads: 0
Thanks: 0
Thanked 0 Times in 0 Posts
This is soundling a lot more complicated than I first thought. Or maybe I'm just confused?

The 4 files would be:
1. framemain.php --> this would define the framesets and which files are in the frame sets.
2. framemain.tpl --> this is the template file for framemain.php
3. frameheader.php --> this is the copy of story.php
4. frameheader.tpl --> this is the copy of story.tpl

Am I on the right track? Any suppporting files you could send would be very helpful.

thanks so much Savant!!
Reply With Quote
  #9 (permalink)  
Old 07-18-2006, 10:36 AM
buga buga is offline
New Pligger
 
Join Date: Jul 2006
Posts: 3
Downloads: 0
Uploads: 0
Thanks: 0
Thanked 0 Times in 0 Posts
Has anyone got this to work? I'm interested in the same thing which also allows removal of the top frame if you're a reg'd member
Reply With Quote
Reply



Thread Tools
Display Modes
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Similar Threads
Thread Thread Starter Forum Replies Last Post
Content on seperate page cryptkeeper General Help 12 02-25-2007 01:42 PM
Story links open in framed page with top stories like Netscape FatPitchFinancials Core Development 2 07-01-2006 02:38 PM
tags take me to error page? lithman General Help 2 05-14-2006 08:05 AM
"Submit story" link on queued stories page aetjansen Pligg Mods 0 02-07-2006 03:29 PM
user page login link is wrong Xanatos Bug Report 1 01-08-2006 11:36 AM


LinkBacks Enabled by vBSEO 3.0.0