content file
-
- Posts: 28
- Joined: Sat Jul 07, 2012 6:16 pm
- Location: Budapest, Hungary
content file
hi,
would it be possible that content file (content.htm) should be instead one file, two files (content1.htm and content2.htm)?
(content.htm = content1.htm + content2.htm)
$pth['file']['content'] = $pth['folder']['content'] . 'content.htm';
thank you for your help in advance.
Alex
would it be possible that content file (content.htm) should be instead one file, two files (content1.htm and content2.htm)?
(content.htm = content1.htm + content2.htm)
$pth['file']['content'] = $pth['folder']['content'] . 'content.htm';
thank you for your help in advance.
Alex
Re: content file
What do you want to accomplish? Why would you want to split content.htm?stargazer96 wrote:would it be possible that content file (content.htm) should be instead one file, two files (content1.htm and content2.htm)?
(content.htm = content1.htm + content2.htm)
Christoph M. Becker – Plugins for CMSimple_XH
-
- Posts: 28
- Joined: Sat Jul 07, 2012 6:16 pm
- Location: Budapest, Hungary
Re: content file
I would like to have instead one content.htm file, two files,
content1.htm and content2.html, because, -several times I need to use embedded files from my domain to other and at least for me!- content.htm would be mostly hided page urls, if changed url and toc is not founded in content1.htm
to be able to find it in content2.htm
( I hope that I could explaine it, to be undestandible, if not pls excuse me for this, anway my main task is to have
instead content.htm, content1.htm and content2.htm
(content.htm = content1.htm + content2.html).
thank you.
content1.htm and content2.html, because, -several times I need to use embedded files from my domain to other and at least for me!- content.htm would be mostly hided page urls, if changed url and toc is not founded in content1.htm
to be able to find it in content2.htm
( I hope that I could explaine it, to be undestandible, if not pls excuse me for this, anway my main task is to have
instead content.htm, content1.htm and content2.htm
(content.htm = content1.htm + content2.html).
thank you.
Re: content file
I'm not sure if I understand you correctly, but it seems to me you want to try content1.htm, and if this file is not good, then you want to use content2.htm. This would be possible with CMSimple, but depending on the version the solution is different. I'll explain for CMSimple_XH 1.6.4.stargazer96 wrote:I would like to have instead one content.htm file, two files,
content1.htm and content2.html, because, -several times I need to use embedded files from my domain to other and at least for me!- content.htm would be mostly hided page urls, if changed url and toc is not founded in content1.htm
to be able to find it in content2.htm
In cmsimple/functions.php you'll find function rfc() (line 789ff) and at its beginning the following line:
Code: Select all
$contents = XH_readContents();
Code: Select all
$oldContentFile = $pth['file']['content'];
$pth['file']['content'] = $pth['folder']['content'] . 'content1.htm';
$contents = XH_readContents();
$pth['file']['content'] = $oldContentFile;
Code: Select all
list($u, $tooLong, $h, $l, $c, $pd_router) = array_values($contents);
Full code:
Code: Select all
function rfc()
{
global $c, $cl, $h, $u, $l, $su, $s, $tx, $e, $pth, $pd_router;
$oldContentFile = $pth['file']['content'];
$pth['file']['content'] = $pth['folder']['content'] . 'content1.htm';
$contents = XH_readContents();
$pth['file']['content'] = $oldContentFile;
if ($contents === false) {
e('missing', 'content', $pth['file']['content']);
$contents = array(
array(), array(), array(), array(), array(),
new XH_PageDataRouter(array(), array(), array(), array())
);
}
list($u, $tooLong, $h, $l, $c, $pd_router) = array_values($contents);
if (!is_good($contents)) {
$oldContentFile = $pth['file']['content'];
$pth['file']['content'] = $pth['folder']['content'] . 'content2.htm';
$contents = XH_readContents();
$pth['file']['content'] = $oldContentFile;
if ($contents === false) {
e('missing', 'content', $pth['file']['content']);
$contents = array(
array(), array(), array(), array(), array(),
new XH_PageDataRouter(array(), array(), array(), array())
);
}
list($u, $tooLong, $h, $l, $c, $pd_router) = array_values($contents);
}
$duplicate = 0; // this line is already there
// ...
}
Christoph M. Becker – Plugins for CMSimple_XH
-
- Posts: 28
- Joined: Sat Jul 07, 2012 6:16 pm
- Location: Budapest, Hungary
Re: content file
thank you very much for your answer and for your help,
I did not thought that it was so complicated (at least for me, of course )
I will read carefully information you sent and I will study it trying to implement it.
If I will have question (and I am sure I will have ) I will feed back to you, and I will inform you about the result also.
thank you so much again for your help!
I did not thought that it was so complicated (at least for me, of course )
I will read carefully information you sent and I will study it trying to implement it.
If I will have question (and I am sure I will have ) I will feed back to you, and I will inform you about the result also.
thank you so much again for your help!
Re: content file
You're welcome. And of course, if you have further questions, feel free to ask.stargazer96 wrote:thank you very much for your answer and for your help
BTW: I will delete the duplicate thread in "Open Development".
Christoph M. Becker – Plugins for CMSimple_XH
-
- Posts: 28
- Joined: Sat Jul 07, 2012 6:16 pm
- Location: Budapest, Hungary
Re: content file
hi Christoph,
thank you again for your help.
I try to implement it, but unfortunatelly, did not succed it.
I use an older 3.3 cmsimple version, littlebit modified/simplyfied, and why I wanted a second content file is because if page / title (h1,h2,h3) is not found on content1.html to search and -if found- display it from the content2.html file.
would it be possible to do it, in very simple way, not so complicated as you previously resolved?
Thank you in advance for your answer.
thank you again for your help.
I try to implement it, but unfortunatelly, did not succed it.
I use an older 3.3 cmsimple version, littlebit modified/simplyfied, and why I wanted a second content file is because if page / title (h1,h2,h3) is not found on content1.html to search and -if found- display it from the content2.html file.
would it be possible to do it, in very simple way, not so complicated as you previously resolved?
Thank you in advance for your answer.
-
- Posts: 28
- Joined: Sat Jul 07, 2012 6:16 pm
- Location: Budapest, Hungary
Re: content file
ISSUE RESOLVED !!
Thank you very much Christoph for the solution and for your kind help!
Thank you very much Christoph for the solution and for your kind help!
Re: content file
Your welcome.stargazer96 wrote:Thank you very much Christoph for the solution and for your kind help!
Christoph M. Becker – Plugins for CMSimple_XH