Where Do Page Files Go Where Do Page Files Go
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Where Do Page Files Go

Started by thenota2, December 23, 2017, 05:29:24 AM

Previous topic - Next topic

0 Members and 4 Guests are viewing this topic.

thenota2

where does a page file go, like bio, media go

i had it in the main theme folder, i made a folder with the path and with the file in it

thenota2


ron4mac

Quote from: thenota2 on December 27, 2017, 09:39:41 PM
nobody saw this?
At the time of this post, it had been viewed 49 times.

You can place those files wherever you want to. My recommendation ... create a folder named pages in the CPG root and put them there.

thenota2

ive made a folder in the coppermine root with a file bio.html in it

if i go to

http://olsen-twins.net/bio

theres nothing there, all ive done was take the content out and left the menus in the file


thenota2

i took the folder out, what if i dont want the html in the url

http://olsen-twins.net/bio.html

ron4mac

Quote from: thenota2 on December 28, 2017, 01:27:23 AM
what if i dont want the html in the url
create a folder bio and place the file in the bio folder. Then rename the file to index.html. Now the URL is http://olsen-twins.net/bio

thenota2


thenota2

what dont i understand here, i thought i could just take the gallery out and use my own html in there but thats not gonna work. the template file wont work if i copy it and use it for a page

http://olsen-twins.net/bio

thenota2

im sorry but i dont understand

what dont i understand here, i thought i could just take the gallery out and use my own html in there but thats not gonna work. the template file wont work if i copy it and use it for a page

http://olsen-twins.net/bio

thenota2

please why cant i just take the gallery out and use the same template

Αndré

If I understood correctly you want to create a custom page which uses your Coppermine theme? If so, create a file bio.php in your gallery root and add code like this:

Quote from: Αndré on July 16, 2016, 12:31:56 PM
<?php define('IN_COPPERMINE'true); include('include/init.inc.php'); pageheader('Welcome'); ?>

Welcome to my gallery.

<?php pagefooter(); ?>


thenota2

i made the file you showed me with BBedit bio.php, and put it in the coppermine root

The requested URL /bio was not found on this server

phill104

It doesn't appear to be in the root. Instead it seems to be http://olsen-twins.net/bio/bio.php

I really think you need someone who is good at these things to sit down with you and go through it. There is not much more help we can give you on this.
It is a mistake to think you can solve any major problems just with potatoes.

thenota2

i know where the root is, i had it there, i took it out, then put the folder in. i understand english and files and code just fine. now if someone could just help me with the page and a template, it worked fine 8 posts ago when ron4mac showed me. but why cant i take this out and use the same template as the main page

the link works fine, why does the template.html template change when i use it for a page like i have exactly at this address rite now

http://olsen-twins.net/bio

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="{LANG_DIR}">
<head>
<meta http-equiv="Content-Type" content="text/html; charset={CHARSET}" />
<meta http-equiv="Pragma" content="no-cache" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{TITLE}</title>
{META}
<link rel="stylesheet" href="css/coppermine.css" type="text/css" />
<link rel="stylesheet" href="themes/munna/css/normalize.css" type="text/css" />
<link rel="stylesheet" href="themes/munna/style.css" type="text/css" />
<link rel="stylesheet" href="themes/munna/css/font-awesome.css" type="text/css" />
<link href='https://fonts.googleapis.com/css?family=Lato:400,400italic,700,700italic|Playfair+Display:400,400italic,700,700italic' rel='stylesheet' type='text/css'>
<link rel="shortcut icon" href="favicon.ico" />
{JAVASCRIPT}
<!--
  SVN version info:
  Coppermine version: 1.5.9
  $HeadURL: https://svn.code.sf.net/p/coppermine/code/trunk/cpg1.5.x/themes/water_drop/template.html $
  $Revision: 7809 $
-->
</head>
<body>

<div id="page" class="site">
<div class="site-container">
<h1 class="site-title">Olsen Twins</h1>
<div class="site-tagline">Mary Kate And Ashley Olsen Pictures</div>
</div>

<div id="site-navigation" class="site-navigation">
<div class="site-container">
<div id="main-navigation" class="main-navigation">
<label for="show-menu" class="show-menu">Menu</label>
<input type="checkbox" id="show-menu">
<ul class="rpv-menu">
<li><a href="http://olsen-twins.net">Home</a></li>
<li><a href="/bio">Mini Bio</a></li>
<li><a href="#">Career</a></li>
<li><a href="#">Photos</a></li>
<li><a href="#">Media</a></li>
<li><a href="#">Website</a></li>
</ul>
</div><!-- .main-navigation -->

<div id="social-navigation" class="social-navigation">



</div><!-- .social-navigation -->
</div>
</div><!-- .site-navigation -->

<div id="masthead" class="site-header"></div><!-- .site-header -->

<div id="content" class="site-content">

<table>
<tr>
<td style="padding-left: 10px; padding-top: 6px;">

<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- All Ads 3 -->
<ins class="adsbygoogle"
     style="display:inline-block;width:300px;height:60px"
     data-ad-client="ca-pub-2495074407921808"
     data-ad-slot="8350786373"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>

</td>
<td style="padding-left: 10px;">

<iframe src="//rcm-na.amazon-adsystem.com/e/cm?o=1&p=288&l=ur1&category=mostwishforitem&banner=00TMGBBBQ7NZSRVZZX02&f=ifr&linkID=f504d61972fcdbeea904ad84a1f56853&t=ampreviewer-20&tracking_id=ampreviewer-20" width="320" height="50" scrolling="no" border="0" marginwidth="0" style="border:none;" frameborder="0"></iframe>

</td>
<td style="padding-left: 8px;">

<iframe src="//rcm-na.amazon-adsystem.com/e/cm?o=1&p=288&l=ur1&category=hotnewreleases&banner=1HNM1EVYY12R5JNA9YR2&f=ifr&linkID=f37ca1bbaf905256a972322dff7c0a93&t=ampreviewer-20&tracking_id=ampreviewer-20" width="320" height="50" scrolling="no" border="0" marginwidth="0" style="border:none;" frameborder="0"></iframe>

</td>
<td style="padding-left: 6px; padding-top: 6px;">

<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- All Ads 3 -->
<ins class="adsbygoogle"
     style="display:inline-block;width:300px;height:60px"
     data-ad-client="ca-pub-2495074407921808"
     data-ad-slot="8350786373"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>

</td>
</tr>
</table>

<div class="cpg-navigation">
{SYS_MENU} {SUB_MENU}
<div class="munnslinks">
<a style="color: #00138E !important; font-weight: bold;"href="http://olsenfashionnook.com" target="_blank" rel="noopener">Buy E&J And The Row</a>&nbsp;&nbsp;&nbsp;
<a style="color: #00138E !important; font-weight: bold;"href="http://bit.ly/2AtkBa0" target="_blank" rel="noopener">Check Out The New Watches</a>&nbsp;&nbsp;&nbsp;
<a style="color: #00138E !important; font-weight: bold;"href="http://olsenfashionnook.com/elizabeth-james-nirvana" target="_blank" rel="noopener">Check Out The New Nirvana French Grey And Amethyst Fragrances</a>
</div>
</div><!-- .cpg-navigation -->

<div id="primary" class="content-area">
<div id="main" class="site-main">
{ADMIN_MENU}
{MESSAGE_BLOCK}
{GALLERY}
</div><!-- .site-main -->
</div><!-- .content-area -->
</div><!-- .site-content -->

<div id="colophon" class="site-footer">
<div class="site-container">
<div class="site-info" style="font-size: 12px !important; font-weight: bold;">
&copy; 2018 <strong>Olsen Twins</strong> Powered by <a href="http://coppermine-gallery.net/">Coppermine</a>
</div><!-- .site-info -->

<div class="site-disclaimer">



</div>
</div>
</div><!-- .site-footer -->
</div><!-- .site -->

<!-- Start of StatCounter Code for Default Guide -->
<script type="text/javascript">
var sc_project=11576129;
var sc_invisible=1;
var sc_security="18556ddb";
var scJsHost = (("https:" == document.location.protocol) ?
"https://secure." : "http://www.");
document.write("<sc"+"ript type='text/javascript' src='" +
scJsHost+
"statcounter.com/counter/counter.js'></"+"script>");
</script>
<noscript><div class="statcounter"><a title="Web Analytics
Made Easy - StatCounter" href="http://statcounter.com/"
target="_blank"><img class="statcounter"
src="//c.statcounter.com/11576129/0/18556ddb/1/" alt="Web
Analytics Made Easy - StatCounter"></a></div></noscript>
<!-- End of StatCounter Code for Default Guide -->

<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-111341450-1"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());

  gtag('config', 'UA-111341450-1');
</script>

</body>
</html>

Αndré

You have 2 options:
1. Create a file (.php or .html) with your hardcoded theme and put it in the folder /bio/
2. Create the .php file as suggested in your gallery root and create a rewrite rule so you can access it via /bio/ instead of /bio.php

thenota2

i have had an html file named index.html in a folder named bio which the url opened but without the themes main core, but like the image below

i have had a bio.php in my root which didnt open anything but this message

The requested URL /bio was not found on this server

this is the second time ive explained my situation for both ways, without result. not due to my incompetence. but yet both ways explained to me dont result in a simple simple page everyone that has a coppermine gallery has on their own sites

do i need the bio folder with the html and the php file in the root at the same time

do i have to change anything in this file?

<?php define('IN_COPPERMINE'true); include('bio.php'); pageheader('Welcome'); ?>

Welcome to my gallery

<?php pagefooter(); ?>

ron4mac

Create a file in the root of your CPG named minibio.php with the contents as André said above.
<?php define('IN_COPPERMINE'true); include 'include/init.inc.php'pageheader('Mini Bio'); ?>

<h2>Welcome to Mini Bio at my gallery.</h2>
etc.
etc.
etc.

<?php pagefooter(); ?>


Change the link for the Mini Bio at the top of your main page to:
<a href="minibio.php">Mini Bio</a>

That's how it will work and how others do it.

thenota2

i have what i want thanks. how can i have it load like any url, without the .php at the end

http://olsen-twins.net/bio.php

Αndré

Quote from: Αndré on January 17, 2018, 09:16:07 PM
create a rewrite rule so you can access it via /bio/ instead of /bio.php