Jump to content

need to show a slide show onli in da home page


jaz529

Recommended Posts

specific  means... this is a php website it has  main index page nd rest of the commands are in a .module files...and slide show is a .module file called in through index.php and i want it 2 be shwon onli in da home page...

 

thanks......

 

Link to comment
Share on other sites

i have a php website and  i  put a slide show in da website .as it is  a php website the slideshow is show in  all the pages.

is there any code to make it show onli in  home page onli... :)

 

How old are you? Please use correct grammar/spelling. We aren't "gangstas" or "thugs" here on the internet.

 

Remove the slideshow from the module you are using or remove the module from the other pages. Problem solved :P

Link to comment
Share on other sites

Ok what I meant was that there is a large technique for developing "dynamic" php websites.

You have you main structure files that get reused over and over.

If you are set up in something like that so when you click a link you are not actually going to another webpage, but are changing part of the php on shown (which it sounds like since it is being displayed on all pages I think?!?!). then you need to change the file that the link is point to for the home page only and not be part of the background code.

 

But if you do not have it set up that way or can follow that then it means I have to explain it differently.

So need to know some of that info... like whats the code you are working with to point u in the right direction.

Link to comment
Share on other sites

Ok what I meant was that there is a large technique for developing "dynamic" php websites.

You have you main structure files that get reused over and over.

If you are set up in something like that so when you click a link you are not actually going to another webpage, but are changing part of the php on shown (which it sounds like since it is being displayed on all pages I think?!?!). then you need to change the file that the link is point to for the home page only and not be part of the background code.

 

But if you do not have it set up that way or can follow that then it means I have to explain it differently.

So need to know some of that info... like whats the code you are working with to point u in the right direction.

 

Long winded version of what I said  :D

Link to comment
Share on other sites

heres how i call the slide show

 

<div id="slideshow">

 

<?php include_once("templates/".$site_template."/modules/slideshow.module") ?>

 

</div>

 

and  theres this slideshow.module with the code of the slideshow

 

um... if the slideshow is the only thing in the module... then why not just remove that whole include from your main page? ........

Link to comment
Share on other sites

Ok what I meant was that there is a large technique for developing "dynamic" php websites.

You have you main structure files that get reused over and over.

If you are set up in something like that so when you click a link you are not actually going to another webpage, but are changing part of the php on shown (which it sounds like since it is being displayed on all pages I think?!?!). then you need to change the file that the link is point to for the home page only and not be part of the background code.

 

But if you do not have it set up that way or can follow that then it means I have to explain it differently.

So need to know some of that info... like whats the code you are working with to point u in the right direction.

 

Long winded version of what I said  :D

 

Lol yeah I know... but I realized that afterwards didn't see that you actually said that

Remove the slideshow from the module you are using or remove the module from the other pages. Problem solved :P

Link to comment
Share on other sites

What i think is trying to be done is have that include inside the module for the home page.... so module inside a module for the home page only.

 

Instead of that module for the slideshow being included inside the mainpage(is it?) include it instead if it is inside of the module for the home page only. Causing it to display only as part of the home page module.

 

Again sorry aeroswat you did just say that, but maybe it may be clearer from a different perspective.

Link to comment
Share on other sites

What i think is trying to be done is have that include inside the module for the home page.... so module inside a module for the home page only.

 

Instead of that module for the slideshow being included inside the mainpage(is it?) include it instead if it is inside of the module for the home page only. Causing it to display only as part of the home page module.

 

Again sorry aeroswat you did just say that, but maybe it may be clearer from a different perspective.

 

I understand completely :)

 

is it possible to call any other module in different pages

 

for eg: slideshow.module in home page and rest of the pages eg.module

 

You can remove it from just the main page and then keep it in the other pages... Unless you have some unique situation that prevents you from doing this.

Link to comment
Share on other sites

as there is only one home page and rest of the modules are called in the same page

 

which means when we click on content link content is shown on the same page and when clicked on about page it is also showed in this homepage..so this slide show is shown in about page and other pages...

Link to comment
Share on other sites

as there is only one home page and rest of the modules are called in the same page

 

which means when we click on content link content is shown on the same page and when clicked on about page it is also showed in this homepage..so this slide show is shown in about page and other pages...

 

Ok. I think i understand now. You use one page that is dynamically changed depending on where you are in the site. I'm not sure if you can do what you want to do. You can do an if that wraps around that include and check to see if they are accessing the main page. If they are then don't do the include and if they aren't then do the include.

Link to comment
Share on other sites

Yeah... so we have a page that creates the site.

We have a page (modules) that change part of the page only when clicking on link.

-creating the about page... other pages.

as there is only one home page and rest of the modules are called in the same page

 

which means when we click on content link content is shown on the same page and when clicked on about page it is also showed in this homepage..so this slide show is shown in about page and other pages...

 

correct?

 

This is what you want to do... instead of it displaying a default code when its at the home part....

create a home module. Just like the about one. etc....

Then when page starts it automatically calls that module. Sounds like you don't have a seperate module for home. Need to develope that and then your problem will be fixed. Because you slide show will be in that module and not the default section that is used to display all the other pages too.

Link to comment
Share on other sites

this is the content.module which calls all the pages so what should i change and a make slideshow.module whi calls slide show.

 

 

<?php

global $rootpath,$sitepath;

$site_template = getSetting("sitetemplate",$db);

$filepath = $rootpath.'templates/'.$site_template.'/'.$c_file;

if (file_exists($filepath) || isset($c_content)) {

if(isset($c_content)){

$c_content='?'.'>'.trim($c_content).'<'.'?';

eval($c_content);

}else{

include($filepath);

 

}

 

}

?>

[/color]

 

 

THIS IS  WHAT IS THERE IN CONTENT.INC WHICH IS CALLED BY CONTENT.MODULE.

 

$accountManagementPage=false;

if (($_GET['id']=='56')&&(getSetting("accountpageon",$db)==0))

{

$_GET['id']='1';

}

if($_GET['id'] >= 200){

$db->query("SELECT * FROM content WHERE linkid = ".quote_smart($_GET['id']));

$res = $db->fetch();

$c_content = $res['page'];

$c_header = $res['title'];

$c_file = "";

}else{

switch($_GET['id']) {

//Accessible to all

case '1': $c_file = 'modules/latest.module'; $c_header = 'Home'; break;

case '2': $c_file = 'modules/toprated.module'; $c_header = 'Top Rated <strong>Media</strong>'; break;

case '3': $c_file = 'modules/mostviewed.module'; $c_header = 'Most Viewed <strong>Media</strong>'; break;

case '4': $c_file = 'modules/forgot.module'; $c_header = 'Forgotten Login'; break;

case '5': $c_file = 'modules/upload.module'; $c_header = 'Upload Media'; break;

case '6': $c_file = 'modules/register.module'; $c_header = 'Register'; break;

case '8': $c_file = 'modules/play.module'; $c_header = dec_VID; break;

case '10': $c_file = 'modules/activate.module'; $c_header = 'Activate Your Account'; break;

case '11': $c_file = 'modules/tellafriend.module'; $c_header = 'Tell a Friend'; break;

case '88': $c_file = 'modules/members.module'; $c_header = 'Members'; break;

case '16': $c_file = 'modules/terms.module'; $c_header = 'Terms of Service'; break;

case '18': $c_file = 'modules/profile.module'; $c_header = 'Profile'; break;

case '19': $c_file = 'modules/groups.module'; $c_header = 'Groups'; break;

case '20': $c_file = 'modules/showgroup.module'; $c_header = 'View Group'; break;

case '21': $c_file = 'modules/category.module'; $c_header = 'Category'; break;

case '22': $c_file = 'modules/mediasearch.module'; $c_header = 'Search'; break;

case '23': $c_file = 'modules/showimage.module'; $c_header = 'Display Image'; break;

case '24': $c_file = 'modules/alltags.module'; $c_header = 'Tags'; break;

case '25': $c_file = 'modules/add.module'; $c_header = 'Add'; break;

case '26': $c_file = 'modules/out.module'; $c_header = 'Out'; break;

case '27': $c_file = 'modules/showallfriends.module'; $c_header = 'All My Friends'; break;

case '28': $c_file = 'modules/domedia.module'; $c_header = 'Change Media Ad'; break;

case '29': $c_file = 'modules/rss.module'; $c_header = 'Rss Feeds'; break;

case '30': $c_file = 'modules/news.module'; $c_header = 'Sites News'; break;

case '31': $c_file = 'modules/edit.module'; $c_header = 'Edit My Media'; break;

//User only pages

case '55': $c_file = 'modules/usercp.module'; $c_header = 'Control Panel'; break;

case '56': $c_file = 'modules/account.module'; $c_header = 'Account Management'; $accountManagementPage=true; break;

//Admin only pages

case '100': $c_file = 'modules/admin/index.module'; $c_header = 'Administration'; break;

case '101': $c_file = 'modules/admin/add_cat.module'; $c_header = 'Add Category'; break;

case '102': $c_file = 'modules/admin/show_cats.module'; $c_header = 'Category Overview'; break;

case '103': $c_file = 'modules/admin/show_media.module'; $c_header = 'Media Overview'; break;

case '104': $c_file = 'modules/admin/new_uploads.module'; $c_header = 'New Uploads'; break;

case '105': $c_file = 'modules/admin/users.module'; $c_header = 'Registered Users'; break;

case '106': $c_file = 'modules/admin/settings.module'; $c_header = 'Settings'; break;

case '107': $c_file = 'modules/admin/play.module'; $c_header = 'Preview Media'; break;

case '108': $c_file = 'modules/admin/contentmanager.module'; $c_header = 'Content Management'; break;

case '109': $c_file = 'modules/admin/menumanager.module'; $c_header = 'Menu Management'; break;

case '111': $c_file = 'modules/admin/emailmanager.module'; $c_header = 'Email Management'; break;

case '112': $c_file = 'modules/admin/import.module'; $c_header = 'Import Media'; break;

case '113': $c_file = 'modules/admin/badwords.module'; $c_header = 'Bad Words'; break;

case '114': $c_file = 'modules/admin/massemail.module'; $c_header = 'Mass Email'; break;

case '115': $c_file = 'modules/preview.module'; $c_header = 'Preview Page'; break;

case '116': $c_file = 'modules/admin/mediasetting.module'; $c_header = 'Media Settings'; break;

case '117': $c_file = 'modules/admin/videoads.module'; $c_header = 'Manage Video Ads'; break;

case '118': $c_file = 'modules/admin/adblocks.module'; $c_header = 'Manage Site Ads'; break;

case '150': $c_file = 'modules/admin/extras.module'; $c_header = 'Manage Extras and Mods'; break;

case '119': $c_file = 'modules/admin/traffic.module'; $c_header = 'Manage Traffic Exchange'; break;

case '121': $c_file = 'modules/admin/rewards.module'; $c_header = 'Manage Reward System'; break;

case '122': $c_file = 'modules/admin/ignore.module'; $c_header = 'Ajax Functions for Rewards'; break;

case '123': $c_file = 'modules/admin/stats.module'; $c_header = 'Admin Stats'; break;

default: $c_file = 'modules/error.php'; $c_header = 'Error 404'; break;

}

}

?>

 

SO COULD YOU PLEASE TELL ME WHAT SHOULD I CHANGE IN THE PROGRAMMING CODE FOR MAKING A SLIDESHOW.MODULE AND SLIDESHOW.IC WHICH CALLS THE SLIDESHOW

Link to comment
Share on other sites

case '1': $c_file = 'modules/latest.module'; $c_header = 'Home'; break;

 

if that is a module for a home page... maybe. It kinda looks like it may. I'd put the code for the slideshow within that module. That way only displayed on the home page.  I'm of course assuming that is a module for part of the home page.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.